java.lang.Object
org.zkoss.zk.ui.AbstractComponent
org.zkoss.zk.ui.HtmlBasedComponent
org.zkoss.zul.impl.XulElement
org.zkoss.zul.Div
de.hybris.platform.cockpit.model.general.impl.AbstractItemView
de.hybris.platform.cockpit.model.gridview.impl.GridView
All Implemented Interfaces:
UIItemView, UIViewComponent, UIGridView, Serializable, Cloneable, org.zkoss.zk.ui.api.HtmlBasedComponent, org.zkoss.zk.ui.Component, org.zkoss.zk.ui.ext.Scope, org.zkoss.zk.ui.sys.ComponentCtrl

public class GridView extends AbstractItemView implements UIGridView
See Also:
  • Nested Class Summary

    Nested classes/interfaces inherited from class de.hybris.platform.cockpit.model.general.impl.AbstractItemView

    AbstractItemView.LoadImage

    Nested classes/interfaces inherited from class org.zkoss.zk.ui.HtmlBasedComponent

    org.zkoss.zk.ui.HtmlBasedComponent.ExtraCtrl

    Nested classes/interfaces inherited from class org.zkoss.zk.ui.AbstractComponent

    org.zkoss.zk.ui.AbstractComponent.Children
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
    protected org.zkoss.zul.Checkbox
     
    protected boolean
     
    static final String
     
    protected org.zkoss.zul.Div
     
     

    Fields inherited from class de.hybris.platform.cockpit.model.general.impl.AbstractItemView

    loadingProgressContainer, ON_CONTINUE_LOADING

    Fields inherited from class org.zkoss.zk.ui.HtmlBasedComponent

    _zclass

    Fields inherited from interface org.zkoss.zk.ui.Component

    APPLICATION_SCOPE, COMPONENT_SCOPE, DESKTOP_SCOPE, PAGE_SCOPE, REQUEST_SCOPE, SESSION_SCOPE, SPACE_SCOPE

    Fields inherited from interface org.zkoss.zk.ui.sys.ComponentCtrl

    AFTER_CHILD_ADDED, AFTER_CHILD_REMOVED, AFTER_PAGE_ATTACHED, AFTER_PAGE_DETACHED, CE_BUSY_IGNORE, CE_DUPLICATE_IGNORE, CE_IMPORTANT, CE_NON_DEFERRABLE, CE_REPEAT_IGNORE
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    protected void
    appendScrollIntoViewComponent(org.zkoss.zk.ui.HtmlBasedComponent cell)
     
    protected void
    continueRenderItems(org.zkoss.zk.ui.Component parent, int index)
     
    protected void
    continueRenderItems(org.zkoss.zk.ui.Component parent, int index, int numberOfItemsToRender)
     
    protected org.zkoss.zk.ui.HtmlBasedComponent
     
    protected void
     
    protected void
    fireChangeSelection(int selectedIndex)
     
    protected void
    fireChangeSelection(List<Integer> selectedIndexes)
     
    protected void
     
    protected void
     
     
     
    protected TypedObject
    getItemAt(int index)
     
     
     
     
    boolean
    Initializes this view component.
    protected void
    rangeSelect(int index)
     
    void
     
    protected void
     
    protected void
    renderActivation(boolean selected)
     
    protected void
    renderItemAsActive(org.zkoss.zk.ui.HtmlBasedComponent comp, boolean active)
     
    protected void
    renderItemAsSelected(org.zkoss.zk.ui.HtmlBasedComponent comp, boolean selected)
     
    protected void
    renderItems(org.zkoss.zk.ui.Component parent)
     
    protected void
    renderSelection(boolean selected)
     
    protected void
     
    void
     
    void
     
    void
     
    void
     
    boolean
    Updates this view component completely.
    void
    Called whenever the activation needs to be updated i.e.
    void
    Called whenever the currently active items need to be re-rendered.
    int
    updateItem(TypedObject item, Set<PropertyDescriptor> propertyDescriptors)
    try to update rows containing the specified items
    void
    Called whenever the items have changed in some way e.g.
    void
    Called whenever the selection is changed in some way and the view needs to update itself accordingly.

    Methods inherited from class org.zkoss.zul.Div

    getAlign, renderProperties, setAlign

    Methods inherited from class org.zkoss.zul.impl.XulElement

    clone, getContext, getCtrlKeys, getPopup, getPropertyAccess, getTooltip, setContext, setContext, setContextAttributes, setCtrlKeys, setPopup, setPopup, setPopupAttributes, setTooltip, setTooltip, setTooltipAttributes

    Methods inherited from class org.zkoss.zk.ui.HtmlBasedComponent

    addSclass, focus, getAction, getDraggable, getDroppable, getExtraCtrl, getHeight, getHflex, getLeft, getRenderdefer, getSclass, getStyle, getTabindex, getTabindexInteger, getTooltiptext, getTop, getVflex, getWidth, getZclass, getZindex, getZIndex, removeSclass, removeSclass, service, 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, setZIndexDirectly

    Methods inherited from class org.zkoss.zk.ui.AbstractComponent

    addAnnotation, addAnnotation, addCallback, addClientEvent, addEventHandler, addEventListener, addEventListener, addForward, addForward, addForward, addForward, addMoved, addRedrawCallback, addScopeListener, addShadowRoot, addShadowRootBefore, addSharedEventHandlerMap, appendChild, applyProperties, beforeChildAdded, beforeChildRemoved, beforeParentChanged, 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, insertBefore, invalidate, isChildable, isInvalidated, isListenerAvailable, isVisible, onChildAdded, onChildRemoved, 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, setParent, setStubonly, setStubonly, setSubBindingAnnotationCount, setTemplate, setVisible, setVisibleDirectly, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdate, smartUpdateWidgetListener, smartUpdateWidgetOverride, toString, updateByClient, updateSubBindingAnnotationCount, willPassivate, willPassivate, willSerialize, willSerialize

    Methods inherited from class java.lang.Object

    equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.zkoss.zk.ui.Component

    addEventListener, addEventListener, addForward, addForward, addForward, addForward, appendChild, applyProperties, clone, detach, getAttribute, getAttribute, getAttributeOrFellow, getAttributes, getAttributes, getAuService, getAutag, getChildren, getClientAttribute, getClientDataAttribute, getDefinition, getDesktop, getEventListeners, getFellow, getFellow, getFellowIfAny, getFellowIfAny, getFellows, getFirstChild, getId, getLastChild, getListenerIterator, getMold, getNextSibling, getPage, getParent, getPreviousSibling, getRoot, getShadowVariable, getShadowVariable, getSpaceOwner, getStubonly, getTemplate, getTemplateNames, getUuid, getWidgetAttribute, getWidgetAttributeNames, getWidgetClass, getWidgetListener, getWidgetListenerNames, getWidgetOverride, getWidgetOverrideNames, hasAttribute, hasAttribute, hasAttributeOrFellow, hasFellow, hasFellow, insertBefore, invalidate, isInvalidated, isListenerAvailable, isVisible, query, queryAll, removeAttribute, removeAttribute, removeChild, removeEventListener, removeForward, removeForward, setAttribute, setAttribute, setAuService, setAutag, setClientAttribute, setClientDataAttribute, setId, setMold, setPage, setPageBefore, setParent, setStubonly, setStubonly, setTemplate, setVisible, setWidgetAttribute, setWidgetClass, setWidgetListener, setWidgetOverride

    Methods inherited from interface org.zkoss.zk.ui.api.HtmlBasedComponent

    focus, getHeight, getLeft, getSclass, getStyle, getTooltiptext, getTop, getWidth, getZclass, getZindex, getZIndex, setDraggable, setDroppable, setFocus, setHeight, setLeft, setSclass, setStyle, setTooltiptext, setTop, setWidth, setZclass, setZindex, setZIndex

    Methods inherited from interface org.zkoss.zk.ui.ext.Scope

    addScopeListener, getAttribute, hasAttribute, removeAttribute, removeScopeListener, setAttribute

    Methods inherited from interface de.hybris.platform.cockpit.model.general.UIItemView

    setDDContext
  • Field Details

    • DEFAULT_GRIDVIEW_CONF

      public static final String DEFAULT_GRIDVIEW_CONF
      See Also:
    • ITEM_BOX_SIZE

      public static final String ITEM_BOX_SIZE
      See Also:
    • model

      protected MutableListModel model
    • initialized

      protected boolean initialized
    • mainDiv

      protected org.zkoss.zul.Div mainDiv
    • focusComponent

      protected org.zkoss.zul.Checkbox focusComponent
  • Constructor Details

    • GridView

      public GridView()
  • Method Details

    • getConfigContextCode

      public String getConfigContextCode()
    • setConfigContextCode

      public void setConfigContextCode(String code)
      Specified by:
      setConfigContextCode in interface UIGridView
    • addGridViewListener

      public void addGridViewListener(GridViewListener listener)
      Specified by:
      addGridViewListener in interface UIGridView
    • removeGridViewListener

      public void removeGridViewListener(GridViewListener listener)
      Specified by:
      removeGridViewListener in interface UIGridView
    • setRootType

      public void setRootType(ObjectTemplate template)
      Specified by:
      setRootType in interface UIGridView
    • getModel

      public MutableListModel getModel()
      Specified by:
      getModel in interface UIGridView
    • setModel

      public void setModel(MutableListModel model)
      Specified by:
      setModel in interface UIGridView
    • updateActivation

      public void updateActivation()
      Description copied from interface: UIItemView
      Called whenever the activation needs to be updated i.e. which items are currently rendered as "active".

      Note: Does not re-render the items themselves, only the activation state of them. In order to update the items use UIItemView.updateActiveItems().

      Specified by:
      updateActivation in interface UIItemView
    • updateActiveItems

      public void updateActiveItems()
      Description copied from interface: UIItemView
      Called whenever the currently active items need to be re-rendered.

      Note: Does not update the activation itself. For that purpose use UIItemView.updateActivation().

      Specified by:
      updateActiveItems in interface UIItemView
      See Also:
    • rerenderItem

      protected void rerenderItem(TypedObject item)
    • updateItem

      public int updateItem(TypedObject item, Set<PropertyDescriptor> propertyDescriptors)
      Description copied from interface: UIItemView
      try to update rows containing the specified items
      Specified by:
      updateItem in interface UIItemView
      Parameters:
      item - the item
      propertyDescriptors - modified properties
      Returns:
      the number of updated rows
    • renderItemAsSelected

      protected void renderItemAsSelected(org.zkoss.zk.ui.HtmlBasedComponent comp, boolean selected)
    • renderItemAsActive

      protected void renderItemAsActive(org.zkoss.zk.ui.HtmlBasedComponent comp, boolean active)
    • renderSelection

      protected void renderSelection(boolean selected)
    • renderActivation

      protected void renderActivation(boolean selected)
    • appendScrollIntoViewComponent

      protected void appendScrollIntoViewComponent(org.zkoss.zk.ui.HtmlBasedComponent cell)
    • updateSelection

      public void updateSelection()
      Description copied from interface: UIItemView
      Called whenever the selection is changed in some way and the view needs to update itself accordingly.
      Specified by:
      updateSelection in interface UIItemView
    • initialize

      public boolean initialize()
      Description copied from interface: UIViewComponent
      Initializes this view component.

      Note: Should not be called during object creation i.e. from constructor.

      Specified by:
      initialize in interface UIViewComponent
      Returns:
      true if initialize was successful, false otherwise
    • update

      public boolean update()
      Description copied from interface: UIViewComponent
      Updates this view component completely.
      Specified by:
      update in interface UIViewComponent
      Returns:
      true if update was successful, false otherwise
    • updateItems

      public void updateItems()
      Description copied from interface: UIItemView
      Called whenever the items have changed in some way e.g. an item has been added or removed.
      Specified by:
      updateItems in interface UIItemView
    • focusFocusComponent

      protected void focusFocusComponent()
    • renderItems

      protected void renderItems(org.zkoss.zk.ui.Component parent)
    • continueRenderItems

      protected void continueRenderItems(org.zkoss.zk.ui.Component parent, int index)
    • continueRenderItems

      protected void continueRenderItems(org.zkoss.zk.ui.Component parent, int index, int numberOfItemsToRender)
    • rangeSelect

      protected void rangeSelect(int index)
    • createItemBox

      protected org.zkoss.zk.ui.HtmlBasedComponent createItemBox(TypedObject item, GridViewConfiguration config)
    • getItemAt

      protected TypedObject getItemAt(int index)
    • removeSelectedItems

      protected void removeSelectedItems()
    • fireRemove

      protected void fireRemove(Collection<Integer> indexes)
    • fireChangeSelection

      protected void fireChangeSelection(List<Integer> selectedIndexes)
    • fireChangeSelection

      protected void fireChangeSelection(int selectedIndex)
    • doUserEvent

      protected void doUserEvent(Object[] data)
    • getUIConfigurationService

      protected UIConfigurationService getUIConfigurationService()
    • setGridItemRenderer

      public void setGridItemRenderer(GridItemRenderer gridItemRenderer)
      Specified by:
      setGridItemRenderer in interface UIGridView
    • getGridItemRenderer

      public GridItemRenderer getGridItemRenderer()
    • getTypeService

      public TypeService getTypeService()