public class Orgitem
extends org.zkoss.zul.impl.XulElement
implements org.zkoss.zk.ui.ext.Disable
Event:
| Constructor and Description |
|---|
Orgitem() |
Orgitem(String label) |
Orgitem(String label,
Object value) |
| Modifier and Type | Method and Description |
|---|---|
void |
beforeChildAdded(org.zkoss.zk.ui.Component child,
org.zkoss.zk.ui.Component insertBefore) |
void |
beforeParentChanged(org.zkoss.zk.ui.Component parent) |
Object |
clone() |
String |
getImage()
Returns the image of the
Orgnode it contains. |
int |
getIndex()
Return the index of this item.
|
String |
getLabel()
Returns the label of the
Orgnode it contains, or null
if no such node. |
int |
getLevel()
Returns the level this item is.
|
Organigram |
getOrganigram()
Returns the Organigram owning this item.
|
Orgchildren |
getOrgchildren()
Returns the Orgchildren that this Orgitem owns, or null if doesn't have any child.
|
Orgitem |
getParentItem()
Returns the parent Orgitem,
or null if this item is already the top level of the Organigram.
|
<T> T |
getValue()
Returns the value.
|
int |
getVisibleItemCount()
Returns the number of visible descendant
Orgchildren. |
String |
getZclass() |
boolean |
insertBefore(org.zkoss.zk.ui.Component newChild,
org.zkoss.zk.ui.Component refChild) |
boolean |
isContainer()
Returns whether the element is to act as a container
which can have child elements.
|
boolean |
isDisabled()
Returns whether it is disabled,
Default: false.
|
boolean |
isEmpty()
Returns whether this element contains no child elements.
|
boolean |
isLoaded()
Return true if all children of this Orgitem, if any, is loaded.
|
boolean |
isOpen()
Returns whether this container is open.
|
boolean |
isRendered()
Returns true if this Orgitem is rendered.
|
boolean |
isSelectable()
Returns whether it is selectable.
|
boolean |
isSelected()
Returns whether this item is selected.
|
void |
onChildAdded(org.zkoss.zk.ui.Component child) |
void |
onChildRemoved(org.zkoss.zk.ui.Component child) |
protected void |
renderProperties(org.zkoss.zk.ui.sys.ContentRenderer renderer) |
void |
service(org.zkoss.zk.au.AuRequest request,
boolean everError) |
void |
setDisabled(boolean disabled)
Sets whether it is disabled.
|
void |
setImage(String image)
Sets the image of the
Orgnode it contains. |
void |
setLabel(String label)
Sets the label of the
Orgnode it contains. |
void |
setOpen(boolean open)
Sets whether this container is open.
|
void |
setParent(org.zkoss.zk.ui.Component parent) |
void |
setSelectable(boolean selectable)
Sets whether it is selectable.
|
void |
setSelected(boolean selected)
Sets whether this item is selected.
|
<T> void |
setValue(T value)
Sets the value.
|
boolean |
setVisible(boolean visible) |
getContext, getCtrlKeys, getPopup, getPropertyAccess, getTooltip, setContext, setContext, setContextAttributes, setCtrlKeys, setPopup, setPopup, setPopupAttributes, setTooltip, setTooltip, setTooltipAttributesaddSclass, evalCSSFlex, focus, getAction, getDraggable, getDroppable, getExtraCtrl, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getStyle, getTabindex, getTabindexInteger, getTooltiptext, getTop, getVflex, getWidth, getZindex, getZIndex, removeSclass, removeSclass, setAction, setClass, setDraggable, setDroppable, setFocus, setHeight, setHeight0, setHeightDirectly, setHflex, setHflex0, setHflexDirectly, setLeft, setLeftDirectly, setRenderdefer, setSclass, setStyle, setTabindex, setTabindex, setTooltiptext, setTop, setTopDirectly, setVflex, setVflex0, setVflexDirectly, setWidth, setWidth0, setWidthDirectly, setZclass, setZindex, setZIndex, setZIndexDirectlyaddAnnotation, addAnnotation, addCallback, addClientEvent, addEventHandler, addEventListener, addEventListener, addForward, addForward, addForward, addForward, addMoved, addRedrawCallback, addScopeListener, addShadowRoot, addShadowRootBefore, addSharedEventHandlerMap, appendChild, applyProperties, beforeChildRemoved, detach, didActivate, didActivate, didDeserialize, didDeserialize, disableBindingAnnotation, disableClientUpdate, enableBindingAnnotation, getAnnotatedProperties, getAnnotatedPropertiesBy, getAnnotation, getAnnotation, getAnnotations, getAnnotations, getAnnotations, getAttribute, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getCallback, getChildren, getClientAttribute, getClientDataAttribute, getClientEvents, getDefaultMold, getDefinition, getDesktop, getEventHandler, getEventHandlerNames, getEventListenerMap, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRedrawCallback, getRoot, getShadowFellowIfAny, getShadowRoots, getShadowVariable, getShadowVariable, getShadowVariable0, getSpaceOwner, getSpecialRendererOutput, getStubonly, getSubBindingAnnotationCount, getTemplate, getTemplateNames, getUuid, getWidgetAttribute, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttribute, hasAttributeOrFellow, hasBindingAnnotation, hasFellow, hasFellow, hasSubBindingAnnotation, invalidate, invalidatePartial, isChildable, isInitialized, isInvalidated, isListenerAvailable, isVisible, onPageAttached, onPageDetached, onWrongValue, query, queryAll, redraw, redrawChildren, removeAttribute, removeAttribute, removeAttribute, removeCallback, removeChild, removeEventListener, removeForward, removeForward, removeRedrawCallback, removeScopeListener, removeShadowRoot, render, render, render, replace, response, response, response, service, sessionDidActivate, sessionWillPassivate, setAttribute, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setDefinition, setDefinition, setId, setMold, setPage, setPageBefore, setStubonly, setStubonly, setSubBindingAnnotationCount, setTemplate, setVisibleDirectly, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdateWidgetListener, smartUpdateWidgetOverride, toString, updateByClient, updateSubBindingAnnotationCount, willPassivate, willPassivate, willSerialize, willSerializepublic Orgitem()
public Orgitem(String label)
public boolean isSelectable()
public void setSelectable(boolean selectable)
selectable - whether it is selectable.public boolean isDisabled()
isDisabled in interface org.zkoss.zk.ui.ext.Disablepublic void setDisabled(boolean disabled)
setDisabled in interface org.zkoss.zk.ui.ext.Disabledisabled - whether it is disabled.public boolean isRendered()
isLoaded()
which is used to check whether all children of this Orgitem are loaded.
Default: falsepublic boolean isLoaded()
public int getIndex()
public Orgchildren getOrgchildren()
public boolean isContainer()
public boolean isEmpty()
public int getLevel()
public <T> T getValue()
public <T> void setValue(T value)
value - the value, It could be anything you want.public boolean isOpen()
public void setOpen(boolean open)
open - whether this container is openpublic boolean isSelected()
public void setSelected(boolean selected)
selected - whether this item is selectedpublic String getLabel()
Orgnode it contains, or null
if no such node.Orgnode it containspublic void setLabel(String label)
Orgnode it contains.
If Orgnode is not created, we automatically create it.
Notice that this method will create an Orgnode automatically if it don't exist. Thus, you cannot attach a node to it again if set an image or a label.
label - the label of the Orgnode it containspublic String getImage()
Orgnode it contains.Orgnode it containspublic void setImage(String image)
Orgnode it contains.
If Orgnode is not created, we automatically create it.
Notice that this method will create an Orgnode automatically if it don't exist. Thus, you cannot attach a node to it again if set an image or a label.
image - the image of the Orgnode it containspublic Organigram getOrganigram()
public Orgitem getParentItem()
public boolean setVisible(boolean visible)
setVisible in interface org.zkoss.zk.ui.ComponentsetVisible in class org.zkoss.zk.ui.AbstractComponentpublic int getVisibleItemCount()
Orgchildren.
Descendants include direct children, grand children and so on.Orgchildrenpublic void beforeParentChanged(org.zkoss.zk.ui.Component parent)
beforeParentChanged in interface org.zkoss.zk.ui.sys.ComponentCtrlbeforeParentChanged in class org.zkoss.zk.ui.AbstractComponentpublic void setParent(org.zkoss.zk.ui.Component parent)
setParent in interface org.zkoss.zk.ui.ComponentsetParent in class org.zkoss.zk.ui.AbstractComponentpublic void beforeChildAdded(org.zkoss.zk.ui.Component child,
org.zkoss.zk.ui.Component insertBefore)
beforeChildAdded in interface org.zkoss.zk.ui.sys.ComponentCtrlbeforeChildAdded in class org.zkoss.zk.ui.AbstractComponentpublic boolean insertBefore(org.zkoss.zk.ui.Component newChild,
org.zkoss.zk.ui.Component refChild)
insertBefore in interface org.zkoss.zk.ui.ComponentinsertBefore in class org.zkoss.zk.ui.AbstractComponentpublic void onChildAdded(org.zkoss.zk.ui.Component child)
onChildAdded in interface org.zkoss.zk.ui.sys.ComponentCtrlonChildAdded in class org.zkoss.zk.ui.AbstractComponentpublic void onChildRemoved(org.zkoss.zk.ui.Component child)
onChildRemoved in interface org.zkoss.zk.ui.sys.ComponentCtrlonChildRemoved in class org.zkoss.zk.ui.AbstractComponentpublic Object clone()
clone in interface org.zkoss.zk.ui.Componentclone in class org.zkoss.zul.impl.XulElementprotected void renderProperties(org.zkoss.zk.ui.sys.ContentRenderer renderer)
throws IOException
renderProperties in class org.zkoss.zul.impl.XulElementIOExceptionpublic void service(org.zkoss.zk.au.AuRequest request,
boolean everError)
service in interface org.zkoss.zk.ui.sys.ComponentCtrlservice in class org.zkoss.zk.ui.HtmlBasedComponentpublic String getZclass()
getZclass in class org.zkoss.zk.ui.HtmlBasedComponentCopyright © 2026. All rights reserved.