StrictTree

case
class StrictTree[A](rootLabel: A, subForest: Vector[StrictTree[A]])
Value Params
rootLabel

The label at the root of this tree.

subForest

The child nodes of this tree.

Companion
object
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any

Value members

Concrete methods

def cobind[B](f: StrictTree[A] => B): StrictTree[B]

Binds the given function across all the subtrees of this tree.

Binds the given function across all the subtrees of this tree.

def drawTree(implicit sh: Show[A]): String

A 2D String representation of this StrictTree.

A 2D String representation of this StrictTree.

override
def equals(obj: Any): Boolean
Definition Classes
Equals -> Any
def flatMap[B](f: A => StrictTree[B]): StrictTree[B]
def flatten: Vector[A]

Pre-order traversal.

Pre-order traversal.

def foldMap[B : Monoid](f: A => B): B

Maps the elements of the StrictTree into a Monoid and folds the resulting StrictTree.

Maps the elements of the StrictTree into a Monoid and folds the resulting StrictTree.

def foldNode[Z](f: A => Vector[StrictTree[A]] => Z): Z
def foldRight[B](z: B)(f: (A, => B) => B): B
override
def hashCode(): Int

This implementation is 24x faster than the trampolined implementation for StrictTreeTestJVM's hashCode test.

This implementation is 24x faster than the trampolined implementation for StrictTreeTestJVM's hashCode test.

Definition Classes
Any
def levels: Vector[Vector[A]]

Breadth-first traversal.

Breadth-first traversal.

def map[B](f: A => B): StrictTree[B]
def scanr[B](g: (A, Vector[StrictTree[B]]) => B): StrictTree[B]

A histomorphic transform. Each element in the resulting tree is a function of the corresponding element in this tree and the histomorphic transform of its children.

A histomorphic transform. Each element in the resulting tree is a function of the corresponding element in this tree and the histomorphic transform of its children.

def size: Int
def toTree: Tree[A]
def traverse1[G[_] : Apply, B](f: A => G[B]): G[StrictTree[B]]
def unzip: (StrictTree[A1], StrictTree[A2])
Implicitly added by ToStrictTreeUnzip

Turns a tree of pairs into a pair of trees.

Turns a tree of pairs into a pair of trees.

def zip[B](b: StrictTree[B]): StrictTree[(A, B)]

Inherited methods

def productElementNames: Iterator[String]
Inherited from
Product
def productIterator: Iterator[Any]
Inherited from
Product