|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectwicket.Component
wicket.MarkupContainer
wicket.markup.html.WebMarkupContainer
wicket.markup.html.WebMarkupContainerWithAssociatedMarkup
wicket.markup.html.panel.Panel
wicket.extensions.markup.html.tree.AbstractTree
wicket.extensions.markup.html.tree.DefaultAbstractTree
Tree class that contains convenient functions related to presentation of the tree, which includes junction link, tree item selection link, spacers (with lines) and default tree item and folder icons.
The class itself adds no component to tree items. If you use this class
directly, you have to implement populateTreeItem() on your own. If you want
to use an existing (complete) tree class, use Tree
This class allows you to choose between 3 types of links.
setLinkType(wicket.extensions.markup.html.tree.DefaultAbstractTree.LinkType)
| Nested Class Summary | |
protected static interface |
DefaultAbstractTree.ILinkCallback
Helper class for calling an action from a link. |
static class |
DefaultAbstractTree.LinkType
The type of junction links and node selection links. |
| Nested classes inherited from class wicket.markup.html.WebMarkupContainerWithAssociatedMarkup |
wicket.markup.html.WebMarkupContainerWithAssociatedMarkup.HeaderPartContainer |
| Nested classes inherited from class wicket.Component |
wicket.Component.ComponentModelChange, wicket.Component.EnabledChange, wicket.Component.IVisitor, wicket.Component.VisibilityChange |
| Field Summary |
| Fields inherited from class wicket.Component |
ENABLE, FLAG_RESERVED1, FLAG_RESERVED2, FLAG_RESERVED3, FLAG_RESERVED4, FLAG_RESERVED5, FLAG_RESERVED6, FLAG_RESERVED7, FLAG_RESERVED8, PATH_SEPARATOR, RENDER |
| Constructor Summary | |
DefaultAbstractTree(java.lang.String id)
Tree contructor. |
|
DefaultAbstractTree(java.lang.String id,
wicket.model.IModel model)
Tree constructor. |
|
DefaultAbstractTree(java.lang.String id,
javax.swing.tree.TreeModel model)
Tree constructor. |
|
| Method Summary | |
protected wicket.markup.html.PackageResourceReference |
getCSS()
Returns the resource reference of default stylesheet. |
protected wicket.ResourceReference |
getFolderClosed()
Returns the resource reference of default closed tree folder. |
protected wicket.ResourceReference |
getFolderOpen()
Returns the resource reference of default open tree folder. |
protected wicket.ResourceReference |
getItem()
Returns the resource reference of default tree item (not folder). |
DefaultAbstractTree.LinkType |
getLinkType()
Returns the current type of links on tree items. |
protected wicket.ResourceReference |
getNodeIcon(javax.swing.tree.TreeNode node)
Returns the resource reference for icon of specified tree node. |
protected wicket.Component |
newIndentation(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node,
int level)
Creates the indentation element. |
protected wicket.MarkupContainer |
newJunctionImage(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
Creates an image placed on junction link. |
protected wicket.Component |
newJunctionLink(wicket.MarkupContainer parent,
java.lang.String id,
java.lang.String imageId,
javax.swing.tree.TreeNode node)
Creates the junction link for given node. |
protected wicket.MarkupContainer |
newLink(wicket.MarkupContainer parent,
java.lang.String id,
DefaultAbstractTree.ILinkCallback callback)
Creates a link of type specified by current linkType. |
protected wicket.Component |
newNodeIcon(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
Creates the icon for current node. |
protected wicket.MarkupContainer |
newNodeLink(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
Creates a link that can be used to select / unselect the specified node. |
protected void |
onJunctionLinkClicked(wicket.ajax.AjaxRequestTarget target,
javax.swing.tree.TreeNode node)
Callback function called after user clicked on an junction link. |
protected void |
onNodeLinkClicked(wicket.ajax.AjaxRequestTarget target,
javax.swing.tree.TreeNode node)
This callback method is called after user has selected / deselected the given node. |
void |
setLinkType(DefaultAbstractTree.LinkType linkType)
Sets the type of links on tree items. |
| Methods inherited from class wicket.extensions.markup.html.tree.AbstractTree |
allNodesCollapsed, allNodesExpanded, getNodeComponent, getTreeState, internalAttach, internalDetach, invalidateAll, isNodeExpanded, isRootLess, newTreeState, nodeCollapsed, nodeExpanded, nodeSelected, nodeUnselected, onAfterRender, onBeforeAttach, populateTreeItem, setRootLess, treeNodesChanged, treeNodesInserted, treeNodesRemoved, treeStructureChanged, updateTree |
| Methods inherited from class wicket.markup.html.panel.Panel |
onComponentTag, onComponentTagBody, renderHead |
| Methods inherited from class wicket.markup.html.WebMarkupContainerWithAssociatedMarkup |
newHeaderPartContainer, renderHeadFromAssociatedMarkupFile |
| Methods inherited from class wicket.markup.html.WebMarkupContainer |
getMarkupType, getWebPage |
| Methods inherited from class wicket.MarkupContainer |
add, autoAdd, contains, findMarkupStream, get, getAssociatedMarkupStream, getMarkupStream, internalAdd, isTransparentResolver, iterator, iterator, newMarkupResourceStream, onRender, remove, remove, removeAll, renderAll, renderAssociatedMarkup, renderComponentTagBody, replace, setMarkupStream, setModel, size, toString, toString, visitChildren, visitChildren |
| Methods inherited from class wicket.Component |
add, addStateChange, checkComponentTag, checkComponentTagAttribute, continueToOriginalDestination, debug, detachBehaviors, detachModel, detachModels, error, exceptionMessage, fatal, findPage, findParent, findParentWithAssociatedMarkup, getApplication, getApplicationPages, getApplicationSettings, getBehaviors, getBehaviors, getClassRelativePath, getConverter, getEscapeModelStrings, getFeedbackMessage, getFlag, getFlag, getId, getLocale, getLocalizer, getMarkupAttributes, getMarkupId, getMetaData, getModel, getModelComparator, getModelObject, getModelObjectAsString, getOutputMarkupId, getPage, getPageFactory, getPageRelativePath, getParent, getPath, getRenderBodyOnly, getRequest, getRequestCycle, getResponse, getSession, getSizeInBytes, getString, getString, getString, getStyle, getVariation, hasErrorMessage, hasFeedbackMessage, info, initModel, internalOnAttach, internalOnDetach, internalOnModelChanged, isActionAuthorized, isAncestorOf, isBehaviorAccepted, isEnableAllowed, isEnabled, isHeadRendered, isIgnoreAttributeModifier, isRenderAllowed, isVersioned, isVisible, isVisibleInHierarchy, modelChanged, modelChanging, newPage, newPage, onAttach, onBeforeRender, onBeginRequest, onDetach, onEndRequest, onModelChanged, onModelChanging, onRender, redirectToInterceptPage, remove, render, render, renderComponent, renderComponent, renderComponentTag, rendered, renderedBehaviors, replaceComponentTagBody, replaceWith, resetHeadRendered, sameRootModel, sameRootModel, setAuto, setEnabled, setEscapeModelStrings, setFlag, setFlag, setIgnoreAttributeModifier, setMetaData, setModelObject, setOutputMarkupId, setRedirect, setRenderBodyOnly, setResponsePage, setResponsePage, setResponsePage, setVersioned, setVisible, urlFor, urlFor, urlFor, urlFor, urlFor, visitParents, warn |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
public DefaultAbstractTree(java.lang.String id)
id - The component id
public DefaultAbstractTree(java.lang.String id,
wicket.model.IModel model)
id - The component idmodel - The tree model
public DefaultAbstractTree(java.lang.String id,
javax.swing.tree.TreeModel model)
id - The component idmodel - The tree model| Method Detail |
public DefaultAbstractTree.LinkType getLinkType()
public void setLinkType(DefaultAbstractTree.LinkType linkType)
linkType - type of linksprotected wicket.markup.html.PackageResourceReference getCSS()
protected wicket.ResourceReference getFolderClosed()
protected wicket.ResourceReference getFolderOpen()
protected wicket.ResourceReference getItem()
protected wicket.ResourceReference getNodeIcon(javax.swing.tree.TreeNode node)
node - The node
protected wicket.Component newIndentation(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node,
int level)
parent - The component parentid - The component idnode - The tree node for which to create the identation elementlevel - The current level
protected wicket.MarkupContainer newJunctionImage(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
parent - The component parentid - The component idnode - The tree node
protected wicket.Component newJunctionLink(wicket.MarkupContainer parent,
java.lang.String id,
java.lang.String imageId,
javax.swing.tree.TreeNode node)
parent - parent component of the linkid - wicket:id of the componentimageId - wicket:id of the image. this can be null, in that case image
is not created. image is supposed to be placed on the link
(link is parent of image)node - tree node for which the link should be created.
protected wicket.MarkupContainer newLink(wicket.MarkupContainer parent,
java.lang.String id,
DefaultAbstractTree.ILinkCallback callback)
parent - The parent componentid - The component idcallback - The link call back
protected wicket.Component newNodeIcon(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
getNodeIcon(TreeNode).
parent - The parent componentid - The component idnode - The tree node
protected wicket.MarkupContainer newNodeLink(wicket.MarkupContainer parent,
java.lang.String id,
javax.swing.tree.TreeNode node)
parent - The parent componentid - The component idnode - The parent node
protected void onJunctionLinkClicked(wicket.ajax.AjaxRequestTarget target,
javax.swing.tree.TreeNode node)
target - Request target - may be null on non-ajax callnode - Node for which this callback is relevant
protected void onNodeLinkClicked(wicket.ajax.AjaxRequestTarget target,
javax.swing.tree.TreeNode node)
target - Request target - may be null on non-ajax callnode - Node for which this this callback is fired.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||