org.allenai.nlpstack.parse.poly.core

PositionTree

Related Doc: package core

case class PositionTree(nodes: Seq[(Position, PositionTreeNode)]) extends Product with Serializable

A PositionTree is a rooted, directed tree, implemented as a map from positions to nodes.

nodes

a sequence of (position, node) pairs

Linear Supertypes
Serializable, Serializable, Product, Equals, AnyRef, Any
Known Subclasses
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. PositionTree
  2. Serializable
  3. Serializable
  4. Product
  5. Equals
  6. AnyRef
  7. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Instance Constructors

  1. new PositionTree(nodes: Seq[(Position, PositionTreeNode)])

    nodes

    a sequence of (position, node) pairs

Value Members

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

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

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

    Definition Classes
    AnyRef → Any
  4. final def asInstanceOf[T0]: T0

    Definition Classes
    Any
  5. def clone(): AnyRef

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( ... )
  6. final def eq(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  7. def finalize(): Unit

    Attributes
    protected[java.lang]
    Definition Classes
    AnyRef
    Annotations
    @throws( classOf[java.lang.Throwable] )
  8. def getChildren(position: Position): Seq[Position]

    Gets the child positions that appear in this tree.

    Gets the child positions that appear in this tree.

    position

    the position of interest

    returns

    the child positions that appear in this tree

  9. final def getClass(): Class[_]

    Definition Classes
    AnyRef → Any
  10. def getLabel(position: Position, labelName: Symbol): Option[String]

    Gets the value of the specified label for the node at the specified position.

    Gets the value of the specified label for the node at the specified position.

    position

    the position of interest

    labelName

    the label of interest

    returns

    the value of the specified label

  11. final def isInstanceOf[T0]: Boolean

    Definition Classes
    Any
  12. lazy val leaves: Seq[Position]

    The leaf positions of the tree, sorted in depth-first left-to-right order.

  13. final def ne(arg0: AnyRef): Boolean

    Definition Classes
    AnyRef
  14. val nodes: Seq[(Position, PositionTreeNode)]

    a sequence of (position, node) pairs

  15. final def notify(): Unit

    Definition Classes
    AnyRef
  16. final def notifyAll(): Unit

    Definition Classes
    AnyRef
  17. lazy val positionMap: Map[Position, PositionTreeNode]

    A map from positions to nodes.

  18. lazy val positions: Seq[Position]

    The positions in the tree.

  19. def substitute(position: Position, positionTree: PositionTree): PositionTree

    Substitutes the subtree at the specified position with a new subtree.

    Substitutes the subtree at the specified position with a new subtree.

    position

    the desired substitution point

    positionTree

    the new subtree

    returns

    a new PositionTree, in which the subtree at the specified position has been replaced

  20. def swapPositions(position1: Position, position2: Position): PositionTree

    Swaps the subtrees at two different positions.

    Swaps the subtrees at two different positions.

    This requires that the specified positions are both valid, and are not descendants of one another.

    position1

    the first position

    position2

    the second position

    returns

    a new PositionTree, in which the two specified subtrees have been swapped

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

    Definition Classes
    AnyRef
  22. final def wait(): Unit

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

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

    Definition Classes
    AnyRef
    Annotations
    @throws( ... )

Inherited from Serializable

Inherited from Serializable

Inherited from Product

Inherited from Equals

Inherited from AnyRef

Inherited from Any

Ungrouped