Interface SelectorSection
- All Superinterfaces:
Section
- All Known Subinterfaces:
DrillableSelectorSection,SectionSelectorSection
- All Known Implementing Classes:
AbstractDrillableSelectorSection,AbstractSelectorSection,CatalogVersionSectionSelectorSection,CategoryDrillableSelectorSection,CategorySectionSelectorSection,CmsCatalogSelectorSection,CmsSiteSelectorSection,DefaultSectionSelectorSection,LiveCatalogVersionSectionSelectorSection,LiveSiteSectionSelectorSection,SiteSectionSelectorSection,WebsiteCatalogVersionSelectorSection,WebsitesSelectorSection
Section which allows the user to select items and handle events.
-
Method Summary
Modifier and TypeMethodDescriptiongetItems()Returns this selector's (root) items.Returns the selected item.Returns the selector's currently selected items.booleanReturns whether initial selection is enabled or not.booleanisItemActive(TypedObject item) Returns whether the itemitemis active or not.booleanReturns whether this selector supports multiple selection or not.voidCalled whenever this selector's selection has changed.voidsetInitiallySelected(boolean initSelection) Sets whether the first item should be initially selected or not.voidsetItems(List<TypedObject> items) Sets the (root) items which this selector should render.voidsetMultiple(boolean multi) Sets whether this selector supports multiple selection or not.voidsetSelectedItem(TypedObject selectedItem) Sets the selector's selected item toselectedItemvoidsetSelectedItems(List<TypedObject> selectedItems) Sets the selector's selected items toselectedItems.voidsetSelectedItemsDirectly(List<TypedObject> selectedItems) Does the same thing assetSelectedItems(List)with the exception that no event is fired.Methods inherited from interface de.hybris.platform.cockpit.components.sectionpanel.Section
getLabel, getLocalizedLabel, isInitialOpen, isOpen, isTabbed, isVisible, setOpen
-
Method Details
-
setItems
Sets the (root) items which this selector should render.- Parameters:
items- this selector's new items
-
getItems
List<TypedObject> getItems()Returns this selector's (root) items.- Returns:
- the root items of this selector
-
setMultiple
void setMultiple(boolean multi) Sets whether this selector supports multiple selection or not.- Parameters:
multi- whether multiple selection should be allowed or not
-
isMultiple
boolean isMultiple()Returns whether this selector supports multiple selection or not.- Returns:
trueif multiple selection is allowed,falseotherwise
-
setSelectedItems
Sets the selector's selected items toselectedItems.- Parameters:
selectedItems- the new selection of the selector- See Also:
-
setSelectedItem
Sets the selector's selected item toselectedItem- Parameters:
selectedItem- the selected item
-
setSelectedItemsDirectly
Does the same thing assetSelectedItems(List)with the exception that no event is fired.- Parameters:
selectedItems- the selected items- See Also:
-
getSelectedItems
List<TypedObject> getSelectedItems()Returns the selector's currently selected items.- Returns:
- the selector's selected items
-
getSelectedItem
TypedObject getSelectedItem()Returns the selected item. Note: In multiple selection mode, it is up to the implementing classes to define what is considered to be the selected item.- Returns:
- the selected item
- See Also:
-
selectionChanged
void selectionChanged()Called whenever this selector's selection has changed. -
isItemActive
Returns whether the itemitemis active or not. Exactly what active means depends on the implementation. Typically active selector items are rendered differently than normal items.- Parameters:
item- the item- Returns:
trueifitemis active,falseotherwise
-
setInitiallySelected
void setInitiallySelected(boolean initSelection) Sets whether the first item should be initially selected or not.- Parameters:
initSelection-trueif inital selection should be enabled,falseotherwise
-
isInitiallySelected
boolean isInitiallySelected()Returns whether initial selection is enabled or not.- Returns:
trueif initial selection is enabled,falseotherwise
-