Package org.eclipse.net4j.util.collection

# Class Tree.Builder

java.lang.Object
org.eclipse.net4j.util.collection.Tree.Builder

All Implemented Interfaces:
  `Comparable<Tree.Builder>`

Enclosing class:
  Tree

public static final class Tree.Builder extends Object implements Comparable<Tree.Builder>

Author:
  Eike Stepper

## Method Summary

Modifier and Type
Method
Description
`Tree.Builder`
`addAttributes(Map<String,String> attributes)`
`Tree.Builder`
`addChild(Consumer<Tree.Builder> childInitializer)`
`Tree.Builder`
`addChild(Tree child)`
`Tree.Builder`
`addChild(Tree.Builder child)`
`Tree.Builder`
`addChildren(Tree.Builder... children)`
`List<Tree.Builder>`
`allChildren()`
`List<Tree.Builder>`
`allChildren(String name)`
`void`
`allChildren(String name, Consumer<Tree.Builder> consumer)`
`void`
`allChildren(Consumer<Tree.Builder> consumer)`
`String`
`attribute(String name)`
`Map<String,String>`
`attributes()`
`Tree`
`build()`
`Tree.Builder`
`child(int index)`
`Tree.Builder`
`child(String name)`
`List<Tree.Builder>`
`children()`
`List<Tree.Builder>`
`children(String name)`
`void`
`children(String name, Consumer<Tree.Builder> consumer)`
`void`
`children(Consumer<Tree.Builder> consumer)`
`int`
`compareTo(Tree.Builder o)`
`int`
`indexInParent()`
`int`
`indexOfChild(Tree.Builder child)`
`String`
`name()`
`Tree.Builder`
`parent()`
`Map<String,String>`
`properties()`
`Map<String,String>`
`properties(String childName)`
`Map<String,String>`
`properties(String childName, String nameAttribute, String valueAttribute)`
`Tree.Builder`
`removeChild(Tree.Builder child)`
`Tree.Builder`
`removeChildren(Tree.Builder... children)`
`Tree.Builder`
`setAttribute(String name, String value)`
`Tree.Builder`
`setAttributes(Map<String,String> attributes)`
`Tree.Builder`
`setName(String name)`
`Tree.Builder`
`setParent(Tree.Builder parent)`
`String`
`toString()`
`Tree.Builder`
`unsetAttribute(String name)`
`Tree.Builder`
`unsetAttributes()`
`Tree.Builder`
`unsetAttributes(Set<String> names)`
`<DATA> DATA`
`visit(BiFunction<Tree.Builder,DATA,DATA> visitor, DATA data)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

## Method Details

### name

public String name()

### setName

public Tree.Builder setName(String name)

### attributes

public Map<String,String> attributes()

### attribute

public String attribute(String name)

### setAttribute

public Tree.Builder setAttribute(String name, String value)

### setAttributes

public Tree.Builder setAttributes(Map<String,String> attributes)

### addAttributes

public Tree.Builder addAttributes(Map<String,String> attributes)

### unsetAttribute

public Tree.Builder unsetAttribute(String name)

### unsetAttributes

public Tree.Builder unsetAttributes(Set<String> names)

### unsetAttributes

public Tree.Builder unsetAttributes()

### parent

public Tree.Builder parent()

### setParent

public Tree.Builder setParent(Tree.Builder parent)

### children

public List<Tree.Builder> children()

### children

public void children(Consumer<Tree.Builder> consumer)

### children

public List<Tree.Builder> children(String name)

### children

public void children(String name, Consumer<Tree.Builder> consumer)

### allChildren

public List<Tree.Builder> allChildren()

### allChildren

public void allChildren(Consumer<Tree.Builder> consumer)

### allChildren

public List<Tree.Builder> allChildren(String name)

### allChildren

public void allChildren(String name, Consumer<Tree.Builder> consumer)

### child

public Tree.Builder child(String name)

### child

public Tree.Builder child(int index)

### addChild

public Tree.Builder addChild(Consumer<Tree.Builder> childInitializer)

### addChild

public Tree.Builder addChild(Tree child)

### addChild

public Tree.Builder addChild(Tree.Builder child)

### addChildren

public Tree.Builder addChildren(Tree.Builder... children)

### removeChild

public Tree.Builder removeChild(Tree.Builder child)

### removeChildren

public Tree.Builder removeChildren(Tree.Builder... children)

### indexInParent

public int indexInParent()

### indexOfChild

public int indexOfChild(Tree.Builder child)

### properties

public Map<String,String> properties()

### properties

public Map<String,String> properties(String childName)

### properties

public Map<String,String> properties(String childName, String nameAttribute, String valueAttribute)

### visit

public <DATA> DATA visit(BiFunction<Tree.Builder,DATA,DATA> visitor, DATA data)

### compareTo

public int compareTo(Tree.Builder o)

Specified by:
  `compareTo` in interface `Comparable<Tree.Builder>`

### toString

public String toString()

Overrides:
  `toString` in class `Object`

### build

public Tree build()