Method Summary |
|
public void | addItemToSelection(Treeitem item) Selects the given item, without deselecting any other items
that are already selected.. |
public void | clear() Clears all child tree items (
Treeitem . |
public void | clearSelection() Clears the selection. |
public Object | clone() |
protected Object | getAssociatedNode(Treeitem ti, Tree t) |
protected Component | getChildByNode(Object node) Return the Tree or Treeitem component by a given associated node in model.
This implmentation calls
TreeModel.getPath method to locate assoicated
Treeitem (or Tree) via path. |
public Collection | getHeads() Returns a collection of heads, including
Tree.getTreecols and auxiliary heads (
Auxhead ) (never null). |
public String | getIconSclass() Returns the style class prefix used to generate the icons of this tree. |
public String | getInnerWidth() Returns the inner width of this component. |
public int | getItemCount() Returns the number of child
Treeitem . |
public Collection | getItems() Returns a readonly list of all descending
Treeitem (children's children and so on). |
public TreeModel | getModel() Returns the list model associated with this tree, or null
if this tree is not associated with any tree data model. |
public String | getName() Returns the name of this component.
Default: null.
The name is used only to work with "legacy" Web application that
handles user's request by servlets.
It works only with HTTP/HTML-based browsers. |
public String | getOuterAttrs() |
public int | getPageSize() Returns the page size that is used by all
Treechildren to display a portion of their child
Treeitem ,
or -1 if no limitation. |
public int | getRows() Returns the rows. |
public int | getSelectedCount() Returns the number of items being selected. |
public Treeitem | getSelectedItem() Returns the selected item. |
public Set | getSelectedItems() Returns all selected items. |
public String | getSeltype() Returns the seltype. |
public Treechildren | getTreechildren() Returns the treechildren that this tree owns (might null). |
public Treecols | getTreecols() Returns the treecols that this tree owns (might null). |
public Treefoot | getTreefoot() Returns the treefoot that this tree owns (might null). |
public TreeitemRenderer | getTreeitemRenderer() Returns the renderer to render each item, or null if the default
renderer is used. |
public boolean | insertBefore(Component newChild, Component refChild) |
final public boolean | isCheckmark() Returns whether the check mark shall be displayed in front
of each item. |
public boolean | isMultiple() Returns whether multiple selections are allowed. |
final public boolean | isVflex() Returns whether to grow and shrink vertical to fit their given space,
so called vertial flexibility. |
protected Object | newExtraCtrl() |
public void | onChildAdded(Component child) |
public void | onChildRemoved(Component child) |
void | onTreechildrenAdded(Treechildren tchs) Called by
Treechildren when is added to a tree. |
void | onTreechildrenRemoved(Treechildren tchs) Called by
Treechildren when is removed from a tree. |
void | onTreeitemAdded(Treeitem item) Called by
Treeitem when is added to a tree. |
void | onTreeitemRemoved(Treeitem item) Called by
Treeitem when is removed from a tree. |
public void | removeItemFromSelection(Treeitem item) Deselects the given item without deselecting other items. |
public void | renderItem(Treeitem item) Renders the specified
Treeitem if not loaded yet,
with
Tree.getTreeitemRenderer . |
public void | renderItem(Treeitem item, Object data) Renders the specified
Treeitem with data if not loaded yet,
with
Tree.getTreeitemRenderer .
It does nothing if
Tree.getModel returns null.
Note: Since the corresponding data is given,
This method has better performance than
renderItem(Treeitem item) due to not searching for its
corresponding data. |
public Treeitem | renderItemByPath(int[] path) |
public void | renderItems(Set items) Renders the specified
Treeitem s with data if not loaded yet,
with
Tree.getTreeitemRenderer . |
public void | selectAll() Selects all items. |
public void | selectItem(Treeitem item) Deselects all of the currently selected items and selects
the given item.
It is the same as
Tree.setSelectedItem .
Parameters: item - the item to select. |
public void | setCheckmark(boolean checkmark) Sets whether the check mark shall be displayed in front
of each item.
The check mark is a checkbox if
Tree.isMultiple returns
true. |
public void | setIconSclass(String scls) Sets the style class prefix used to generate the icons of this tree. |
public void | setInnerWidth(String innerWidth) Sets the inner width of this component.
The inner width is the width of the inner table.
By default, it is 100%. |
public void | setModel(TreeModel model) Sets the tree model associated with this tree. |
public void | setMultiple(boolean multiple) Sets whether multiple selections are allowed. |
public void | setName(String name) Sets the name of this component.
The name is used only to work with "legacy" Web application that
handles user's request by servlets.
It works only with HTTP/HTML-based browsers. |
public void | setPageSize(int size) Sets the page size that is used by all
Treechildren to display a portion of their child
Treeitem .
Parameters: size - the page size. |
public void | setRows(int rows) Sets the rows. |
public void | setSelectedItem(Treeitem item) Deselects all of the currently selected items and selects
the given item. |
public void | setSeltype(String seltype) Sets the seltype. |
public void | setTreeitemRenderer(TreeitemRenderer renderer) Sets the renderer which is used to render each item
if
Tree.getModel is not null. |
public void | setVflex(boolean vflex) Sets whether to grow and shrink vertical to fit their given space,
so called vertial flexibility. |
public void | smartUpdate(String attr, String value) |
public void | toggleItemSelection(Treeitem item) If the specified item is selected, it is deselected.
If it is not selected, it is selected. |