Class JmixGroupTable

java.lang.Object
com.vaadin.server.AbstractClientConnector
com.vaadin.ui.AbstractComponent
com.vaadin.v7.ui.AbstractLegacyComponent
com.vaadin.v7.ui.AbstractField<Object>
com.vaadin.v7.ui.AbstractSelect
com.vaadin.v7.ui.Table
io.jmix.ui.widget.JmixTable
io.jmix.ui.widget.JmixGroupTable
All Implemented Interfaces:
com.vaadin.event.Action.Container, com.vaadin.event.Action.ShortcutNotifier, com.vaadin.event.ConnectorEventListener, com.vaadin.event.ContextClickEvent.ContextClickNotifier, com.vaadin.event.dd.DragSource, com.vaadin.event.dd.DropTarget, com.vaadin.event.MethodEventSource, com.vaadin.event.SerializableEventListener, com.vaadin.server.ClientConnector, com.vaadin.server.Sizeable, com.vaadin.server.VariableOwner, com.vaadin.shared.Connector, com.vaadin.ui.Component, com.vaadin.ui.Component.Focusable, com.vaadin.ui.Component.HasContextHelp, com.vaadin.ui.HasChildMeasurementHint, com.vaadin.ui.HasComponents, com.vaadin.ui.LegacyComponent, com.vaadin.v7.data.Buffered, com.vaadin.v7.data.BufferedValidatable, com.vaadin.v7.data.Container, com.vaadin.v7.data.Container.ItemSetChangeListener, com.vaadin.v7.data.Container.ItemSetChangeNotifier, com.vaadin.v7.data.Container.Ordered, com.vaadin.v7.data.Container.PropertySetChangeListener, com.vaadin.v7.data.Container.PropertySetChangeNotifier, com.vaadin.v7.data.Container.Sortable, com.vaadin.v7.data.Container.Viewer, com.vaadin.v7.data.Property<Object>, com.vaadin.v7.data.Property.Editor, com.vaadin.v7.data.Property.ReadOnlyStatusChangeListener, com.vaadin.v7.data.Property.ReadOnlyStatusChangeNotifier, com.vaadin.v7.data.Property.ValueChangeListener, com.vaadin.v7.data.Property.ValueChangeNotifier, com.vaadin.v7.data.Property.Viewer, com.vaadin.v7.data.Validatable, com.vaadin.v7.event.ItemClickEvent.ItemClickNotifier, com.vaadin.v7.ui.Field<Object>, AggregationContainer, GroupTableContainer, TableSortableContainer, JmixEnhancedTable, Serializable, Iterable<com.vaadin.ui.Component>, EventListener
Direct Known Subclasses:
GroupTableImpl.JmixGroupTableExt

public class JmixGroupTable extends JmixTable implements GroupTableContainer
See Also:
  • Field Details

    • groupIdMap

      protected com.vaadin.server.KeyMapper groupIdMap
    • cachedAggregatedValues

      protected Map<Object,List<String>> cachedAggregatedValues
    • groupDisallowedProperties

      protected List<Object> groupDisallowedProperties
    • groupPropertyValueFormatter

      protected JmixGroupTable.GroupPropertyValueFormatter groupPropertyValueFormatter
    • fixedGrouping

      protected boolean fixedGrouping
    • requestColumnReorderingAllowed

      protected boolean requestColumnReorderingAllowed
    • shouldPaintWithAggregations

      protected boolean shouldPaintWithAggregations
    • focusGroupAggregationInputColumnKey

      protected String focusGroupAggregationInputColumnKey
  • Constructor Details

    • JmixGroupTable

      public JmixGroupTable()
  • Method Details

    • setColumnOrder

      public void setColumnOrder(@Nullable Object[] columnOrder)
      Attention: this method is copied from the parent class: Table.setColumnOrder(Object[])
    • setContainerDataSource

      public void setContainerDataSource(com.vaadin.v7.data.Container newDataSource)
      Specified by:
      setContainerDataSource in interface com.vaadin.v7.data.Container.Viewer
      Overrides:
      setContainerDataSource in class com.vaadin.v7.ui.Table
    • paintContent

      public void paintContent(com.vaadin.server.PaintTarget target) throws com.vaadin.server.PaintException
      Specified by:
      paintContent in interface com.vaadin.ui.LegacyComponent
      Overrides:
      paintContent in class JmixTable
      Throws:
      com.vaadin.server.PaintException
    • paintAdditionalData

      protected void paintAdditionalData(com.vaadin.server.PaintTarget target) throws com.vaadin.server.PaintException
      Overrides:
      paintAdditionalData in class JmixTable
      Throws:
      com.vaadin.server.PaintException
    • paintVisibleColumns

      protected void paintVisibleColumns(com.vaadin.server.PaintTarget target) throws com.vaadin.server.PaintException
      Overrides:
      paintVisibleColumns in class com.vaadin.v7.ui.Table
      Throws:
      com.vaadin.server.PaintException
    • paintActions

      protected void paintActions(com.vaadin.server.PaintTarget target, Set<com.vaadin.event.Action> actionSet) throws com.vaadin.server.PaintException
      Overrides:
      paintActions in class JmixTable
      Throws:
      com.vaadin.server.PaintException
    • paintUpdatesForGroupRowWithAggregation

      protected void paintUpdatesForGroupRowWithAggregation(com.vaadin.server.PaintTarget target, Object groupId) throws com.vaadin.server.PaintException
      Throws:
      com.vaadin.server.PaintException
    • isAggregatedValuesChanged

      protected boolean isAggregatedValuesChanged(@Nullable Object itemId)
    • getAggregatedValuesForGroup

      protected List<String> getAggregatedValuesForGroup(Object itemId)
    • isColumnReorderingAllowed

      public boolean isColumnReorderingAllowed()
      Overrides:
      isColumnReorderingAllowed in class com.vaadin.v7.ui.Table
    • changeVariables

      public void changeVariables(Object source, Map<String,Object> variables)
      Specified by:
      changeVariables in interface com.vaadin.server.VariableOwner
      Overrides:
      changeVariables in class JmixTable
    • hasGroupDisallowedProperties

      protected boolean hasGroupDisallowedProperties(@Nullable Object[] newGroupProperties)
    • isGroupsChanged

      protected boolean isGroupsChanged(@Nullable Object[] newGroupProperties)
    • changeVariables

      protected boolean changeVariables(Map<String,Object> variables)
      Overrides:
      changeVariables in class JmixTable
    • isCellPaintingNeeded

      protected boolean isCellPaintingNeeded(Object itemId, Object columnId)
      Overrides:
      isCellPaintingNeeded in class com.vaadin.v7.ui.Table
    • paintRowAttributes

      protected void paintRowAttributes(com.vaadin.server.PaintTarget target, Object itemId) throws com.vaadin.server.PaintException
      Overrides:
      paintRowAttributes in class com.vaadin.v7.ui.Table
      Throws:
      com.vaadin.server.PaintException
    • getAggregationItemIds

      protected Collection<?> getAggregationItemIds()
      Overrides:
      getAggregationItemIds in class JmixTable
    • paintGroupAggregation

      protected void paintGroupAggregation(com.vaadin.server.PaintTarget target, Object groupId, Map<Object,Object> aggregations) throws com.vaadin.server.PaintException
      Throws:
      com.vaadin.server.PaintException
    • getItemIdsInRange

      protected LinkedHashSet<Object> getItemIdsInRange(Object startItemId, int length)
      Overrides:
      getItemIdsInRange in class com.vaadin.v7.ui.Table
    • isColumnNeedsToRefreshRendered

      protected boolean isColumnNeedsToRefreshRendered(Object colId)
      Overrides:
      isColumnNeedsToRefreshRendered in class com.vaadin.v7.ui.Table
    • isItemNeedsToRefreshRendered

      protected boolean isItemNeedsToRefreshRendered(Object itemId)
      Overrides:
      isItemNeedsToRefreshRendered in class com.vaadin.v7.ui.Table
    • formatGroupPropertyValue

      protected String formatGroupPropertyValue(Object groupId, @Nullable Object groupValue)
    • expandAllInGroup

      protected void expandAllInGroup(Object id, boolean rerender)
    • expandAllInGroup

      protected void expandAllInGroup(Object id)
    • selectAllInGroup

      protected void selectAllInGroup(Object id)
    • expand

      protected void expand(Object id, boolean rerender)
    • collapse

      protected void collapse(Object id, boolean rerender)
    • groupBy

      protected void groupBy(Object[] properties, boolean rerender)
    • isNonGeneratedProperty

      protected boolean isNonGeneratedProperty(Object id)
    • getGroupProperties

      public Collection<?> getGroupProperties()
      Specified by:
      getGroupProperties in interface GroupTableContainer
    • expandAll

      public void expandAll()
      Specified by:
      expandAll in interface GroupTableContainer
    • expand

      public void expand(Object id)
      Specified by:
      expand in interface GroupTableContainer
    • collapseAll

      public void collapseAll()
      Specified by:
      collapseAll in interface GroupTableContainer
    • collapse

      public void collapse(Object id)
      Specified by:
      collapse in interface GroupTableContainer
    • hasGroups

      public boolean hasGroups()
      Specified by:
      hasGroups in interface GroupTableContainer
    • groupBy

      public void groupBy(Object[] properties)
      Specified by:
      groupBy in interface GroupTableContainer
    • getColumnGroupAllowed

      public boolean getColumnGroupAllowed(Object id)
    • setColumnGroupAllowed

      public void setColumnGroupAllowed(Object id, boolean allowed)
    • isGroup

      public boolean isGroup(Object itemId)
      Specified by:
      isGroup in interface GroupTableContainer
    • rootGroups

      public Collection<?> rootGroups()
      Specified by:
      rootGroups in interface GroupTableContainer
    • hasChildren

      public boolean hasChildren(Object id)
      Specified by:
      hasChildren in interface GroupTableContainer
    • getChildren

      public Collection<?> getChildren(Object id)
      Specified by:
      getChildren in interface GroupTableContainer
    • getGroupProperty

      @Nullable public Object getGroupProperty(Object itemId)
      Specified by:
      getGroupProperty in interface GroupTableContainer
    • getGroupPropertyValue

      @Nullable public Object getGroupPropertyValue(Object itemId)
      Specified by:
      getGroupPropertyValue in interface GroupTableContainer
    • getGroupItemIds

      public Collection<?> getGroupItemIds(Object itemId)
      Specified by:
      getGroupItemIds in interface GroupTableContainer
    • getGroupItemsCount

      public int getGroupItemsCount(Object itemId)
      Specified by:
      getGroupItemsCount in interface GroupTableContainer
    • isExpanded

      public boolean isExpanded(Object id)
      Specified by:
      isExpanded in interface GroupTableContainer
    • isFixedGrouping

      public boolean isFixedGrouping()
    • setFixedGrouping

      public void setFixedGrouping(boolean fixedGrouping)
    • handleAggregationGroupInputChange

      protected void handleAggregationGroupInputChange(String columnKey, String groupKey, String value, boolean isFocused)
      Overrides:
      handleAggregationGroupInputChange in class JmixTable
    • setSortOptions

      public void setSortOptions(Object propertyId, boolean sortAscending)
      Description copied from interface: JmixEnhancedTable
      Sets column id to sort and sorting direction. It doesn't invoke sorting after setting parameters.
      Specified by:
      setSortOptions in interface JmixEnhancedTable
      Overrides:
      setSortOptions in class JmixTable
      Parameters:
      propertyId - column id
      sortAscending - sort ascending option
    • refreshRenderedCells

      protected void refreshRenderedCells()
      Overrides:
      refreshRenderedCells in class com.vaadin.v7.ui.Table
    • getGroupPropertyValueFormatter

      public JmixGroupTable.GroupPropertyValueFormatter getGroupPropertyValueFormatter()
    • setGroupPropertyValueFormatter

      public void setGroupPropertyValueFormatter(JmixGroupTable.GroupPropertyValueFormatter groupPropertyValueFormatter)