public abstract class TreeNode
extends java.util.HashMap<java.lang.String,java.lang.Object>
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
CHILD_PROPERTY |
static java.lang.String |
VALUE_PROPERTY |
Constructor and Description |
---|
TreeNode() |
Modifier and Type | Method and Description |
---|---|
static org.apache.myfaces.trinidad.model.TreeModel |
createTreeModel(java.util.Collection collection, java.lang.String[] columns, java.lang.String[] dataColumns, java.lang.String[] extraCols, oracle.adf.model.dvt.util.transform.total.AggType aggType)
Create a TreeModel from a list of property->value maps, an ordered list of columns representing the properties in the maps, a list of which columns in the maps represent data, a list of which columns are to be aggregated down in the data itself rather than as nodes in the tree, and the type of aggregation to use (SUM, etc.)
|
static org.apache.myfaces.trinidad.model.TreeModel |
createTreeModel(DataModel binding)
Create a TreeModel from a cubic binding
|
abstract boolean |
equals(java.lang.Object obj) |
abstract TreeNode |
findNode(java.lang.Object value) |
java.lang.Object |
get(java.lang.Object key) |
static boolean |
pivot(org.apache.myfaces.trinidad.model.TreeModel tree, java.lang.String sourceColumn, java.lang.String destinationColumn, int pivotType)
Move the given source column from one place in the tree to another.
|
clear, clone, containsKey, containsValue, entrySet, isEmpty, keySet, put, putAll, remove, size, values
public static final java.lang.String CHILD_PROPERTY
public static final java.lang.String VALUE_PROPERTY
public static org.apache.myfaces.trinidad.model.TreeModel createTreeModel(DataModel binding)
binding
- cubic binding to use as basis for the TreeModel. The format is expected to have all of the columns arranged on the column edge, with the data layer as the fastest varying on that edge. Proper insert before totals must also be defined as part of the binding.public static org.apache.myfaces.trinidad.model.TreeModel createTreeModel(java.util.Collection collection, java.lang.String[] columns, java.lang.String[] dataColumns, java.lang.String[] extraCols, oracle.adf.model.dvt.util.transform.total.AggType aggType)
collection
- a Collection of property/value pair Maps. Each element is a row and each property is a column and its value in that rowcolumns
- a list of columns represented in the maps that defines the parent->child ordering of the non data columns in the TreeModeldataColumns
- a list of columns from the maps that should be used as data values in non aggregate TreeModel nodes.extraCols
- a list of columns from the maps that should be aggregated as data and not represented in the TreeModel as nodes.aggType
- the type of aggregation to use (see AggType)public static boolean pivot(org.apache.myfaces.trinidad.model.TreeModel tree, java.lang.String sourceColumn, java.lang.String destinationColumn, int pivotType)
tree
- TreeModel on which to operatesourceColumn
- Column to movedestinationColumn
- Location at which to move sourceColumnpivotType
- Type of move to make (before, after, swap, see DataDirector pivot types)public java.lang.Object get(java.lang.Object key)
get
in interface java.util.Map<java.lang.String,java.lang.Object>
get
in class java.util.HashMap<java.lang.String,java.lang.Object>
public abstract boolean equals(java.lang.Object obj)
equals
in interface java.util.Map<java.lang.String,java.lang.Object>
equals
in class java.util.AbstractMap<java.lang.String,java.lang.Object>
public abstract TreeNode findNode(java.lang.Object value)