final case class TreeLoc[A](tree: Tree[A], lefts: TreeForest[A], rights: TreeForest[A], parents: Parents[A]) extends Product with Serializable
A rose-tree zipper. Represents a scalaz.Tree together with a position in that tree. Provides navigation, persistent update, insertion, and deletes.
- tree
The currently selected node.
- lefts
The left siblings of the current node.
- rights
The right siblings of the current node.
- parents
The parent contexts of the current node.
- Source
- TreeLoc.scala
- Alphabetic
- By Inheritance
- TreeLoc
- Serializable
- Product
- Equals
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new TreeLoc(tree: Tree[A], lefts: TreeForest[A], rights: TreeForest[A], parents: Parents[A])
- tree
The currently selected node.
- lefts
The left siblings of the current node.
- rights
The right siblings of the current node.
- parents
The parent contexts of the current node.
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##: Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def cojoin: TreeLoc[TreeLoc[A]]
- def delete: Option[TreeLoc[A]]
Delete the current node and all its children.
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- def find(p: (TreeLoc[A]) => Boolean): Option[TreeLoc[A]]
Select the first descendant node of the current node that satisfies the given predicate.
- def findChild(p: (Tree[A]) => Boolean): Option[TreeLoc[A]]
Select the first immediate child of the current node that satisfies the given predicate.
- def firstChild: Option[TreeLoc[A]]
Select the leftmost child of the current node.
- def getChild(n: Int): Option[TreeLoc[A]]
Select the nth child of the current node.
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def getLabel: A
Get the label of the current node.
- def hasChildren: Boolean
True if the current node has children.
- def insertDownAt(n: Int, t: Tree[A]): Option[TreeLoc[A]]
Insert the given node as the nth child of the current node and give it focus.
- def insertDownFirst(t: Tree[A]): TreeLoc[A]
Insert the given node as the first child of the current node and give it focus.
- def insertDownLast(t: Tree[A]): TreeLoc[A]
Insert the given node as the last child of the current node and give it focus.
- def insertLeft(t: Tree[A]): TreeLoc[A]
Insert the given node to the left of the current node and give it focus.
- def insertRight(t: Tree[A]): TreeLoc[A]
Insert the given node to the right of the current node and give it focus.
- def isChild: Boolean
True if the current node is not the root node.
- def isFirst: Boolean
True if the current node has no left siblings.
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def isLast: Boolean
True if the current node has no right siblings.
- def isLeaf: Boolean
True if the current node has no children.
- def isRoot: Boolean
True if the current node is the root node.
- def lastChild: Option[TreeLoc[A]]
Select the rightmost child of the current node.
- def left: Option[TreeLoc[A]]
Select the left sibling of the current node.
- val lefts: TreeForest[A]
- def map[B](f: (A) => B): TreeLoc[B]
Maps the given function over the elements.
- def modifyLabel(f: (A) => A): TreeLoc[A]
Modify the label at the current node with the given function.
- def modifyTree(f: (Tree[A]) => Tree[A]): TreeLoc[A]
Modify the current node with the given function.
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def parent: Option[TreeLoc[A]]
Select the parent of the current node.
- val parents: Parents[A]
- def path: EStream[A]
The path from the focus to the root.
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- def right: Option[TreeLoc[A]]
Select the right sibling of the current node.
- val rights: TreeForest[A]
- def root: TreeLoc[A]
Select the root node of the tree.
Select the root node of the tree.
- Annotations
- @tailrec()
- def setLabel(a: A): TreeLoc[A]
Set the label of the current node.
- def setTree(t: Tree[A]): TreeLoc[A]
Replace the current node with the given one.
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toForest: TreeForest[A]
Get the entire forest represented by this zipper.
- def toTree: Tree[A]
Get the entire tree represented by this zipper.
- val tree: Tree[A]
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()