Class

laika.ast

DocumentTree

Related Doc: package ast

Permalink

case class DocumentTree(path: Path, content: Seq[TreeContent], templates: Seq[TemplateDocument] = Nil, styles: Map[String, StyleDeclarationSet] = ..., additionalContent: Seq[AdditionalContent] = Nil, config: Config = ConfigFactory.empty, position: TreePosition = TreePosition.root, sourcePaths: Seq[String] = Nil) extends TreeStructure with TreeContent with Product with Serializable

Represents a tree with all its documents and subtrees.

path

the full, absolute path of this (virtual) document tree

content

the markup documents and subtrees

templates

all templates on this level of the tree hierarchy that might get applied to a document when it gets rendered

styles

the styles to apply when rendering this tree

additionalContent

all dynamic or static documents that are not part of the main navigatable content of the tree

config

the configuration associated with this tree

position

the position of this tree inside a document ast hierarchy, expressed as a list of Ints

sourcePaths

the paths this document tree has been built from or an empty list if this ast does not originate from the file system

Linear Supertypes
Serializable, Serializable, Product, Equals, TreeContent, Navigatable, TreeStructure, AnyRef, Any
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. DocumentTree
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. TreeContent
  7. Navigatable
  8. TreeStructure
  9. AnyRef
  10. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Instance Constructors

  1. new DocumentTree(path: Path, content: Seq[TreeContent], templates: Seq[TemplateDocument] = Nil, styles: Map[String, StyleDeclarationSet] = ..., additionalContent: Seq[AdditionalContent] = Nil, config: Config = ConfigFactory.empty, position: TreePosition = TreePosition.root, sourcePaths: Seq[String] = Nil)

    Permalink

    path

    the full, absolute path of this (virtual) document tree

    content

    the markup documents and subtrees

    templates

    all templates on this level of the tree hierarchy that might get applied to a document when it gets rendered

    styles

    the styles to apply when rendering this tree

    additionalContent

    all dynamic or static documents that are not part of the main navigatable content of the tree

    config

    the configuration associated with this tree

    position

    the position of this tree inside a document ast hierarchy, expressed as a list of Ints

    sourcePaths

    the paths this document tree has been built from or an empty list if this ast does not originate from the file system

Value Members

  1. final def !=(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  2. final def ##(): Int

    Permalink
    Definition Classes
    AnyRef → Any
  3. final def ==(arg0: Any): Boolean

    Permalink
    Definition Classes
    AnyRef → Any
  4. val additionalContent: Seq[AdditionalContent]

    Permalink

    all dynamic or static documents that are not part of the main navigatable content of the tree

  5. final def asInstanceOf[T0]: T0

    Permalink
    Definition Classes
    Any
  6. def clone(): AnyRef

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  7. val config: Config

    Permalink

    the configuration associated with this tree

    the configuration associated with this tree

    Definition Classes
    DocumentTreeTreeContent
  8. val content: Seq[TreeContent]

    Permalink

    the markup documents and subtrees

    the markup documents and subtrees

    Definition Classes
    DocumentTreeTreeStructure
  9. final def eq(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  10. def finalize(): Unit

    Permalink
    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  11. final def getClass(): Class[_]

    Permalink
    Definition Classes
    AnyRef → Any
  12. lazy val globalLinkTargets: Map[Selector, TargetResolver]

    Permalink

    All link targets that can get referenced from anywhere in the document tree.

    All link targets that can get referenced from anywhere in the document tree.

    Definition Classes
    TreeStructure
  13. final def isInstanceOf[T0]: Boolean

    Permalink
    Definition Classes
    Any
  14. lazy val name: String

    Permalink

    The local name of this navigatable.

    The local name of this navigatable.

    Definition Classes
    Navigatable
  15. final def ne(arg0: AnyRef): Boolean

    Permalink
    Definition Classes
    AnyRef
  16. final def notify(): Unit

    Permalink
    Definition Classes
    AnyRef
  17. final def notifyAll(): Unit

    Permalink
    Definition Classes
    AnyRef
  18. val path: Path

    Permalink

    the full, absolute path of this (virtual) document tree

    the full, absolute path of this (virtual) document tree

    Definition Classes
    DocumentTreeNavigatable
  19. val position: TreePosition

    Permalink

    the position of this tree inside a document ast hierarchy, expressed as a list of Ints

    the position of this tree inside a document ast hierarchy, expressed as a list of Ints

    Definition Classes
    DocumentTreeTreeContent
  20. def rewrite(rule: (DocumentCursor) ⇒ RewriteRule): DocumentTree

    Permalink

    Returns a new tree, with all the document models contained in it rewritten based on the specified rewrite rule.

    Returns a new tree, with all the document models contained in it rewritten based on the specified rewrite rule.

    If the specified partial function is not defined for a specific element the old element remains in the tree unchanged. If it returns None then the node gets removed from the ast, if it returns an element it will replace the old one. Of course the function may also return the old element.

    The rewriting is performed in a way that only branches of the tree that contain new or removed elements will be replaced. It is processed bottom-up, therefore any element container passed to the rule only contains children which have already been processed.

    The specified factory function will be invoked for each document contained in this tree and must return a partial function that represents the rewrite rules for that particular document.

  21. def selectDocument(path: Path): Option[Document]

    Permalink

    Selects a document from this tree or one of its subtrees by the specified path.

    Selects a document from this tree or one of its subtrees by the specified path. The path needs to be relative.

    Definition Classes
    TreeStructure
  22. def selectDocument(path: String): Option[Document]

    Permalink

    Selects a document from this tree or one of its subtrees by the specified path.

    Selects a document from this tree or one of its subtrees by the specified path. The path needs to be relative.

    Definition Classes
    TreeStructure
  23. def selectSubtree(path: Path): Option[DocumentTree]

    Permalink

    Selects a subtree of this tree by the specified path.

    Selects a subtree of this tree by the specified path. The path needs to be relative and it may point to a deeply nested subtree, not just immediate children.

    Definition Classes
    TreeStructure
  24. def selectSubtree(path: String): Option[DocumentTree]

    Permalink

    Selects a subtree of this tree by the specified path.

    Selects a subtree of this tree by the specified path. The path needs to be relative and it may point to a deeply nested subtree, not just immediate children.

    Definition Classes
    TreeStructure
  25. def selectTarget(selector: Selector): Option[TargetResolver]

    Permalink

    Selects a link target by the specified selector if it is defined somewhere in a document inside this document tree.

    Selects a link target by the specified selector if it is defined somewhere in a document inside this document tree.

    Definition Classes
    TreeContent
  26. def selectTemplate(path: Path): Option[TemplateDocument]

    Permalink

    Selects a template from this tree or one of its subtrees by the specified path.

    Selects a template from this tree or one of its subtrees by the specified path. The path needs to be relative.

    Definition Classes
    TreeStructure
  27. def selectTemplate(path: String): Option[TemplateDocument]

    Permalink

    Selects a template from this tree or one of its subtrees by the specified path.

    Selects a template from this tree or one of its subtrees by the specified path. The path needs to be relative.

    Definition Classes
    TreeStructure
  28. val sourcePaths: Seq[String]

    Permalink

    the paths this document tree has been built from or an empty list if this ast does not originate from the file system

  29. val styles: Map[String, StyleDeclarationSet]

    Permalink

    the styles to apply when rendering this tree

  30. final def synchronized[T0](arg0: ⇒ T0): T0

    Permalink
    Definition Classes
    AnyRef
  31. val targetTree: DocumentTree

    Permalink

    The actual document tree that this ast structure represents.

    The actual document tree that this ast structure represents.

    Definition Classes
    DocumentTreeTreeStructure
  32. val templates: Seq[TemplateDocument]

    Permalink

    all templates on this level of the tree hierarchy that might get applied to a document when it gets rendered

    all templates on this level of the tree hierarchy that might get applied to a document when it gets rendered

    Definition Classes
    DocumentTreeTreeStructure
  33. lazy val title: Seq[Span]

    Permalink

    The title of this tree, obtained from configuration.

    The title of this tree, obtained from configuration.

    Definition Classes
    TreeStructure
  34. def titleFromConfig: Option[Seq[Span]]

    Permalink
    Attributes
    protected
    Definition Classes
    TreeContent
  35. final def wait(): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  36. final def wait(arg0: Long, arg1: Int): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  37. final def wait(arg0: Long): Unit

    Permalink
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from TreeContent

Inherited from Navigatable

Inherited from TreeStructure

Inherited from AnyRef

Inherited from Any

Ungrouped