# Interface: com.pnfsoftware.jeb.core.output.tree.ITreeDocument

A tree document is used to represent hierarchical structures. Nodes of trees implement the [INode](INode) interface. Tree document can be used to model simple trees as well as more complex table trees \(see [#getColumnLabels()](#getColumnLabels())\).

## Method: addressToCoordinates
- parameter: `address`, type: `java.lang.String`
- return type: `com.pnfsoftware.jeb.core.output.tree.INodeCoordinates`

Description: Convert a node address to node coordinates. 

 Note: The addressing scheme is unit specific, and defined by the plugin developer. Addresses should not start with the reserved '@' prefix.
parameter: address: the input address
return: the coordinates, null on error

## Method: coordinatesToAddress
- parameter: `coordinates`, type: `com.pnfsoftware.jeb.core.output.tree.INodeCoordinates`
- return type: `java.lang.String`

Description: Convert node coordinates to an address understandable by the tree document and potentially the unit representing the document. 

 Note: The addressing scheme is unit specific, and defined by the plugin developer. Addresses should not start with the reserved '@' prefix.
parameter: coordinates: the node coordinates
return: the address, null on error

## Method: getColumnLabels
- return type: `java.util.List<java.lang.String>`

Description: Provide column labels for table trees. A regular tree should return null.
return: the column labels, in practice at least two elements

## Method: getInitialExpansionLevel
- return type: `int`

Description: Get the ideal expansion level of the tree. Graphical clients should use this method when doing the initial rendering of a tree document.
return: the initial expansion level. Special values are: 0 to signify "expand nothing"; \-1 to         signify "expand all".

## Method: getReferencedAddress
- parameter: `node`, type: `com.pnfsoftware.jeb.core.output.tree.INode`
- return type: `java.lang.String`

Description: Retrieve the address referenced by the [INode](INode). In trees, some leafs may reference another [INode](INode).
parameter: node: [INode](INode) to test
return: the reference address \(meaning the virtual content of the node\) or null if not         applicable.

## Method: getRoots
- return type: `java.util.List<? extends com.pnfsoftware.jeb.core.output.tree.INode>`

Description: Get the list of tree roots.
return: the list of roots, cannot be null. Typically contain a single item, empty list at         best

