public interface ElementTreeNode extends ElementGroup
This interface supports "out the box" the typical DOM tree node structure with handle, icon and label elements:
<parent> <content><handle/><icon/><label>markup of label</label></content> <children> ...child tree nodes go here </children> </parent>
The label element is normally used to render below the value associated to node.
The method setValue(Object)
is used to render this value, the structure and renderer
objects are used to customize how and where this value is saved in the tree node
beyond the default cases.
A pattern based DOM tree node ever works in "master" mode, see ElementListFree.isMaster()
.
ElementGroupManager.createElementTreeNode(org.w3c.dom.Element,boolean)
Modifier and Type | Method and Description |
---|---|
org.w3c.dom.Element |
getChildListElement()
Returns the parent element of the child tree nodes.
|
ElementTreeNodeList |
getChildTreeNodeList()
Returns the child tree node list of this tree node.
|
org.w3c.dom.Element |
getContentElement()
Returns the content element.
|
int |
getDeepLevel()
Returns the number of levels (parents) above.
|
ElementTreeNode |
getElementTreeNodeFromNode(org.w3c.dom.Node node)
Returns this tree node or the tree node containing the specified node.
|
ElementTreeNode |
getElementTreeNodeParent()
Returns the parent tree node if exists.
|
ElementTreeNodeRenderer |
getElementTreeNodeRenderer()
Returns the current renderer used by this tree node.
|
ElementTreeNodeStructure |
getElementTreeNodeStructure()
Returns the current structure used by this tree node.
|
org.w3c.dom.Element |
getHandleElement()
Returns the handle element.
|
org.w3c.dom.Element |
getIconElement()
Returns the icon element.
|
int |
getIndex()
Returns the index of this node as a child of its node parent.
|
org.w3c.dom.DocumentFragment |
getLabelContentPatternFragment()
Returns the pattern used to render values if
isUsePatternMarkupToRender()
is true. |
org.w3c.dom.Element |
getLabelElement()
Returns the label element.
|
ElementTreeNode |
getNextSiblingTreeNode()
Returns the tree node immediately following this tree node (same level).
|
ElementTreeNode |
getNextTreeNode()
Returns the next tree node in the logical order of the tree
(seen as a list).
|
ElementTreeNode |
getPreviousSiblingTreeNode()
Returns the tree node immediately preceding this tree node (same level).
|
ElementTreeNode |
getPreviousTreeNode()
Returns the previous tree node in the logical order of the tree
(seen as a list).
|
int |
getRow()
Returns the row index of this node seeing the tree as a list.
|
int |
getRowCount()
Returns the number of rows below this tree node including itself.
|
boolean |
isLeaf()
Informs whether this node is a leaf, it does not contain child nodes.
|
boolean |
isTreeTable()
Informs whether this node is part of a tree table.
|
boolean |
isUsePatternMarkupToRender()
Informs whether the original (saved as pattern) markup is used to render.
|
void |
setElementTreeNodeRenderer(ElementTreeNodeRenderer renderer)
Sets the renderer used by this tree node.
|
void |
setUsePatternMarkupToRender(boolean value)
Sets whether the original (saved as pattern) markup is used to render.
|
void |
setValue(java.lang.Object value)
Renders the submitted value into the tree node markup using the current
renderer.
|
getItsNatDocument, getParentElement
containsUserValueName, getUserValue, getUserValueNames, removeUserValue, setUserValue
ElementTreeNodeStructure getElementTreeNodeStructure()
ElementTreeNodeRenderer getElementTreeNodeRenderer()
void setElementTreeNodeRenderer(ElementTreeNodeRenderer renderer)
renderer
- the new renderer.int getRowCount()
ElementTreeNode getElementTreeNodeParent()
org.w3c.dom.Element getContentElement()
getElementTreeNodeStructure()
,
ElementTreeNodeStructure.getContentElement(ElementTreeNode,Element)
org.w3c.dom.Element getHandleElement()
getElementTreeNodeStructure()
,
ElementTreeNodeStructure.getHandleElement(ElementTreeNode,Element)
org.w3c.dom.Element getIconElement()
getElementTreeNodeStructure()
,
ElementTreeNodeStructure.getIconElement(ElementTreeNode,Element)
org.w3c.dom.Element getLabelElement()
getElementTreeNodeStructure()
,
ElementTreeNodeStructure.getLabelElement(ElementTreeNode,Element)
org.w3c.dom.Element getChildListElement()
getElementTreeNodeStructure()
,
ElementTreeNodeStructure.getChildListElement(ElementTreeNode,Element)
void setValue(java.lang.Object value)
value
- the value to render.getElementTreeNodeRenderer()
,
ElementTreeNodeRenderer.renderTreeNode(ElementTreeNode,Object,Element,boolean)
int getIndex()
getElementTreeNodeParent()
int getRow()
int getDeepLevel()
boolean isLeaf()
ElementTreeNode getElementTreeNodeFromNode(org.w3c.dom.Node node)
node
- the node to search for.ElementTreeNodeList getChildTreeNodeList()
ElementTreeNode getPreviousTreeNode()
ElementTreeNode getNextTreeNode()
ElementTreeNode getPreviousSiblingTreeNode()
ElementTreeNode getNextSiblingTreeNode()
boolean isTreeTable()
boolean isUsePatternMarkupToRender()
The default value is defined by the parent tree node list if exists or
by ItsNatDocument.isUsePatternMarkupToRender()
setUsePatternMarkupToRender(boolean)
void setUsePatternMarkupToRender(boolean value)
value
- true to enable the use of original markup to render.isUsePatternMarkupToRender()
org.w3c.dom.DocumentFragment getLabelContentPatternFragment()
isUsePatternMarkupToRender()
is true.Copyright © 2007 Innowhere Software Services S.L. All Rights Reserved.