|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Tree
Interface for a phylogenetic or genealogical tree.
Nested Class Summary | |
---|---|
static class |
Tree.TreeBase
|
Nested classes/interfaces inherited from interface pal.misc.IdGroup |
---|
IdGroup.Utils |
Field Summary |
---|
Fields inherited from interface pal.misc.Units |
---|
DAYS, EXPECTED_SUBSTITUTIONS, GENERATIONS, MONTHS, SAMPLE, SHORT_UNIT_NAMES, UNIT_NAMES, UNKNOWN, YEARS |
Method Summary | |
---|---|
void |
createNodeList()
This method is called to ensure that the calls to other methods in this interface are valid. |
java.lang.Object |
getAttribute(Node node,
java.lang.String name)
|
Tree |
getCopy()
|
Node |
getExternalNode(int i)
|
int |
getExternalNodeCount()
|
Node |
getInternalNode(int i)
|
int |
getInternalNodeCount()
|
Node |
getRoot()
|
int |
getUnits()
Gets the units that this tree's branch lengths and node heights are expressed in. |
void |
setAttribute(Node node,
java.lang.String name,
java.lang.Object value)
Sets an named attribute for a given node. |
void |
setRoot(Node root)
This method constructs a tree from the given root node. |
Methods inherited from interface pal.misc.IdGroup |
---|
getIdCount, getIdentifier, setIdentifier, whichIdNumber |
Method Detail |
---|
Node getRoot()
void setRoot(Node root)
root
- the root node of the tree to construct.int getExternalNodeCount()
int getInternalNodeCount()
Node getExternalNode(int i)
Node getInternalNode(int i)
void createNodeList()
int getUnits()
getUnits
in interface UnitsProvider
void setAttribute(Node node, java.lang.String name, java.lang.Object value)
node
- the node whose attribute is being set.name
- the name of the attribute.value
- the new value of the attribute.java.lang.Object getAttribute(Node node, java.lang.String name)
node
- the node being interrogated.name
- the name of the attribute of interest.
Tree getCopy()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |