Class sap.m.FacetFilterListModule: sap/m/FacetFilterList

extends List

FacetFilterList represents a list of values for the FacetFilter control.

Constructor Summary
new sap.m.FacetFilterList(sId?, mSettings?)Constructor for a new FacetFilterList.
Event Summary
listClose(oControlEvent)Triggered after the list of items is closed.
listOpen(oControlEvent)Fired before the filter list is opened.
Events borrowed from class sap.ui.core.Control
Method Summary
sap.m.FacetFilterList.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.m.FacetFilterList with name sClassName and enriches it with the information contained in oClassInfo.
sap.m.FacetFilterList.getMetadata()Returns a metadata object for class sap.m.FacetFilterList.
attachListClose(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the listClose event of this sap.m.FacetFilterList.
attachListOpen(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the listOpen event of this sap.m.FacetFilterList.
detachListClose(fnFunction, oListener)Detaches event handler fnFunction from the listClose event of this sap.m.FacetFilterList.
detachListOpen(fnFunction, oListener)Detaches event handler fnFunction from the listOpen event of this sap.m.FacetFilterList.
fireListClose(mArguments?)Fires event listClose to attached listeners.
fireListOpen(mArguments?)Fires event listOpen to attached listeners.
getActive()Gets current value of property active.
getAllCount()Gets current value of property allCount.
getDataType()Gets current value of property dataType.
getEnableCaseInsensitiveSearch()Gets current value of property enableCaseInsensitiveSearch.
getKey()Gets current value of property key.
getRetainListSequence()Gets current value of property retainListSequence.
getSelectedKeys()Returns the keys of the selected elements as an associative array.
getSequence()Gets current value of property sequence.
getShowRemoveFacetIcon()Gets current value of property showRemoveFacetIcon.
getTitle()Gets current value of property title.
getWordWrap()Gets current value of property wordWrap.
removeSelectedKey(sKey, sText)Removes the specified key from the selected keys cache and deselects the item.
removeSelectedKeys()Removes all selected keys from the selected keys cache and deselects all items.
setActive(bActive)Sets a new value for property active.
setAllCount(iAllCount)Sets a new value for property allCount.
setDataType(sDataType)Sets a new value for property dataType.
setEnableCaseInsensitiveSearch(bEnableCaseInsensitiveSearch)Sets a new value for property enableCaseInsensitiveSearch.
setKey(sKey)Sets a new value for property key.
setMode(mode)Overrides to allow only MultiSelect and SingleSelectMaster list modes.
setRetainListSequence(bRetainListSequence)Sets a new value for property retainListSequence.
setSelectedKeys(oAKeys)Used to pre-select FacetFilterItems, such as when restoring FacetFilterList selections from a variant.
setSequence(iSequence)Sets a new value for property sequence.
setShowRemoveFacetIcon(bShowRemoveFacetIcon)Sets a new value for property showRemoveFacetIcon.
setWordWrap(bWordWrap)Sets a new value for property wordWrap.
getMultiSelect()Gets current value of property multiSelect.
Methods borrowed from class sap.m.ListBase
addAriaLabelledBy, addItem, attachDelete, attachGrowingFinished, attachGrowingStarted, attachItemPress, attachSelect, attachSelectionChange, attachSwipe, attachUpdateFinished, attachUpdateStarted, bindItems, destroyHeaderToolbar, destroyInfoToolbar, destroyItems, destroySwipeContent, detachDelete, detachGrowingFinished, detachGrowingStarted, detachItemPress, detachSelect, detachSelectionChange, detachSwipe, detachUpdateFinished, detachUpdateStarted, fireDelete, fireGrowingFinished, fireGrowingStarted, fireItemPress, fireSelect, fireSelectionChange, fireSwipe, fireUpdateFinished, fireUpdateStarted, getAriaLabelledBy, getEnableBusyIndicator, getFooterText, getGrowing, getGrowingInfo, getGrowingScrollToLoad, getGrowingThreshold, getGrowingTriggerText, getHeaderDesign, getHeaderText, getHeaderToolbar, getIncludeItemInSelection, getInfoToolbar, getInset, getItemNavigation, getItems, getKeyboardMode, getLastMode, getMode, getModeAnimationOn, getNoDataText, getRememberSelections, getSelectedContexts, getShowNoData, getShowSeparators, getShowUnread, getSwipeContent, getSwipeDirection, getSwipedItem, getWidth, indexOfItem, insertItem, removeAllAriaLabelledBy, removeAllItems, removeAriaLabelledBy, removeItem, selectAll, setEnableBusyIndicator, setFooterText, setGrowing, setGrowingScrollToLoad, setGrowingThreshold, setGrowingTriggerText, setHeaderDesign, setHeaderText, setHeaderToolbar, setIncludeItemInSelection, setInfoToolbar, setInset, setKeyboardMode, setModeAnimationOn, setNoDataText, setRememberSelections, setSelectedItem, setSelectedItemById, setShowNoData, setShowSeparators, setShowUnread, setSwipeContent, setSwipeDirection, setWidth, swipeOut, unbindItems
Constructor Detail
new sap.m.FacetFilterList(sId?, mSettings?)
Constructor for a new FacetFilterList.

Accepts an object literal mSettings that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject for a general description of the syntax of the settings object.

The supported settings are:

In addition, all settings applicable to the base type sap.m.List can be used as well.

Parameters:
{string}sId? ID for the new control, generated automatically if no id is given
{object}mSettings? Initial settings for the new control
Event Detail
listClose(oControlEvent)
Triggered after the list of items is closed.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
{sap.m.FacetFilterItem[]}oControlEvent.getParameters.selectedItems Array of selected items. Items returned are only copies and therefore can only be used to read properties, not set them.
{boolean}oControlEvent.getParameters.allSelectedTrue if the select All checkbox is selected. This will be false if all items are actually selected (every FacetFilterItem.selected == true). In that case selectedItems will contain all selected items.
{object}oControlEvent.getParameters.selectedKeys Associative array containing the keys of selected FacetFilterItems. Unlike the selectedItems parameter, this contains only the keys for all selected items, not the items themselves. Being an associative array, each object property is the FacetFilterItem key value and the value of the property is the FacetFilterItem text.
listOpen(oControlEvent)
Fired before the filter list is opened.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
Method Detail
sap.m.FacetFilterList.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.m.FacetFilterList with name sClassName and enriches it with the information contained in oClassInfo.

oClassInfo might contain the same kind of information as described in sap.m.List.extend.

Parameters:
{string}sClassName Name of the class being created
{object}oClassInfo? Object literal with information about the class
{function}FNMetaImpl? Constructor function for the metadata object; if not given, it defaults to sap.ui.core.ElementMetadata
Returns:
{function} Created class / constructor function
sap.m.FacetFilterList.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.m.FacetFilterList.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
attachListClose(oData?, fnFunction, oListener?): sap.m.FacetFilterList
Attaches event handler fnFunction to the listClose event of this sap.m.FacetFilterList.

When called, the context of the event handler (its this) will be bound to oListener if specified, otherwise it will be bound to this sap.m.FacetFilterList itself.

Triggered after the list of items is closed.

Parameters:
{object}oData? An application-specific payload object that will be passed to the event handler along with the event object when firing the event
{function}fnFunction The function to be called when the event occurs
{object}oListener? Context object to call the event handler with. Defaults to this sap.m.FacetFilterList itself
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
attachListOpen(oData?, fnFunction, oListener?): sap.m.FacetFilterList
Attaches event handler fnFunction to the listOpen event of this sap.m.FacetFilterList.

When called, the context of the event handler (its this) will be bound to oListener if specified, otherwise it will be bound to this sap.m.FacetFilterList itself.

Fired before the filter list is opened.

Parameters:
{object}oData? An application-specific payload object that will be passed to the event handler along with the event object when firing the event
{function}fnFunction The function to be called when the event occurs
{object}oListener? Context object to call the event handler with. Defaults to this sap.m.FacetFilterList itself
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
detachListClose(fnFunction, oListener): sap.m.FacetFilterList
Detaches event handler fnFunction from the listClose event of this sap.m.FacetFilterList.

The passed function and listener object must match the ones used for event registration.

Parameters:
{function}fnFunction The function to be called, when the event occurs
{object}oListener Context object on which the given function had to be called
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
detachListOpen(fnFunction, oListener): sap.m.FacetFilterList
Detaches event handler fnFunction from the listOpen event of this sap.m.FacetFilterList.

The passed function and listener object must match the ones used for event registration.

Parameters:
{function}fnFunction The function to be called, when the event occurs
{object}oListener Context object on which the given function had to be called
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
fireListClose(mArguments?): sap.m.FacetFilterList
Fires event listClose to attached listeners.

Expects the following event parameters:

  • selectedItems of type sap.m.FacetFilterItem[]Array of selected items. Items returned are only copies and therefore can only be used to read properties, not set them.
  • allSelected of type booleanTrue if the select All checkbox is selected. This will be false if all items are actually selected (every FacetFilterItem.selected == true). In that case selectedItems will contain all selected items.
  • selectedKeys of type objectAssociative array containing the keys of selected FacetFilterItems. Unlike the selectedItems parameter, this contains only the keys for all selected items, not the items themselves. Being an associative array, each object property is the FacetFilterItem key value and the value of the property is the FacetFilterItem text.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
fireListOpen(mArguments?): sap.m.FacetFilterList
Fires event listOpen to attached listeners.
Parameters:
{Map}mArguments? The arguments to pass along with the event
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
getActive(): boolean
Gets current value of property active.

Indicates that the list is displayed as a button when the FacetFilter type is set to Simple.

Default value is true.

Returns:
{boolean} Value of property active
getAllCount(): int
Gets current value of property allCount.

Determines the number of objects that match this item in the target data set when all filter items are selected.

Returns:
{int} Value of property allCount
Gets current value of property dataType.

FacetFilterList data type. Only String data type will provide search function.

Default value is String.

Returns:
{sap.m.FacetFilterListDataType} Value of property dataType
getEnableCaseInsensitiveSearch(): boolean
Gets current value of property enableCaseInsensitiveSearch.

If set to true, enables case-insensitive search for OData.

Default value is false.

Returns:
{boolean} Value of property enableCaseInsensitiveSearch
getKey(): string
Gets current value of property key.

Unique identifier for this filter list.

Returns:
{string} Value of property key
getRetainListSequence(): boolean
Gets current value of property retainListSequence.

Retains the list sequence if it is inactive and made active again.

Default value is false.

Since:
1.22.1
Returns:
{boolean} Value of property retainListSequence
getSelectedKeys(): object
Returns the keys of the selected elements as an associative array. An empty object is returned if no items are selected.
Since:
1.20.3
Returns:
{object} Object with the selected keys
getSequence(): int
Gets current value of property sequence.

Sequence that determines the order in which FacetFilterList is shown on the FacetFilter. Lists are rendered by ascending order of sequence.

Default value is -1.

Returns:
{int} Value of property sequence
getShowRemoveFacetIcon(): boolean
Gets current value of property showRemoveFacetIcon.

Specifies whether remove icon for facet is visible or hidden.

Default value is true.

Since:
1.20.4
Returns:
{boolean} Value of property showRemoveFacetIcon
getTitle(): string
Gets current value of property title.

Defines the title of the facet. The facet title is displayed on the facet button when the FacetFilter type is set to Simple. It is also displayed as a list item in the facet page of the dialog.

Returns:
{string} Value of property title
getWordWrap(): boolean
Gets current value of property wordWrap.

If set to true, the item text wraps when it is too long.

Default value is false.

Returns:
{boolean} Value of property wordWrap
removeSelectedKey(sKey, sText): void
Removes the specified key from the selected keys cache and deselects the item.
Parameters:
{string}sKey The key of the selected item to be removed from the cache. If null then the text parameter will be used as the key.
{string}sText The text of the selected item to be removed from the cache. If the key parameter is null then text will be used as the key.
Since:
1.20.4
removeSelectedKeys(): void
Removes all selected keys from the selected keys cache and deselects all items.
Since:
1.20.4
setActive(bActive): sap.m.FacetFilterList
Sets a new value for property active.

Indicates that the list is displayed as a button when the FacetFilter type is set to Simple.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
{boolean}bActive New value for property active
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setAllCount(iAllCount): sap.m.FacetFilterList
Sets a new value for property allCount.

Determines the number of objects that match this item in the target data set when all filter items are selected.

When called with a value of null or undefined, the default value of the property will be restored.

Parameters:
{int}iAllCount New value for property allCount
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setDataType(sDataType): sap.m.FacetFilterList
Sets a new value for property dataType.

FacetFilterList data type. Only String data type will provide search function.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is String.

Parameters:
{sap.m.FacetFilterListDataType}sDataType New value for property dataType
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setEnableCaseInsensitiveSearch(bEnableCaseInsensitiveSearch): sap.m.FacetFilterList
Sets a new value for property enableCaseInsensitiveSearch.

If set to true, enables case-insensitive search for OData.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is false.

Parameters:
{boolean}bEnableCaseInsensitiveSearch New value for property enableCaseInsensitiveSearch
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setKey(sKey): sap.m.FacetFilterList
Sets a new value for property key.

Unique identifier for this filter list.

When called with a value of null or undefined, the default value of the property will be restored.

Parameters:
{string}sKey New value for property key
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setMode(mode)
Overrides to allow only MultiSelect and SingleSelectMaster list modes. If an invalid mode is given then the mode will not be changed.
Parameters:
{sap.m.ListMode}mode The list mode
setRetainListSequence(bRetainListSequence): sap.m.FacetFilterList
Sets a new value for property retainListSequence.

Retains the list sequence if it is inactive and made active again.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is false.

Parameters:
{boolean}bRetainListSequence New value for property retainListSequence
Since:
1.22.1
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setSelectedKeys(oAKeys): void
Used to pre-select FacetFilterItems, such as when restoring FacetFilterList selections from a variant. Keys are cached separately from the actual FacetFilterItems so that they remain even when the physical items are removed by filtering or sorting. If aKeys is undefined, null, or {} (empty object) then all keys are deleted. After this method completes, only those items with matching keys will be selected. All other items in the list will be deselected.
Parameters:
{object}oAKeys Associative array indicating which FacetFilterItems should be selected in the list. Each property must be set to the value of a FacetFilterItem.key property. Each property value should be set to the FacetFilterItem.text property value. The text value is used to display the FacetFilterItem text when the FacetFilterList button or FacetFilter summary bar is displayed. If no property value is set then the property key is used for the text.
Since:
1.20.3
setSequence(iSequence): sap.m.FacetFilterList
Sets a new value for property sequence.

Sequence that determines the order in which FacetFilterList is shown on the FacetFilter. Lists are rendered by ascending order of sequence.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is -1.

Parameters:
{int}iSequence New value for property sequence
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setShowRemoveFacetIcon(bShowRemoveFacetIcon): sap.m.FacetFilterList
Sets a new value for property showRemoveFacetIcon.

Specifies whether remove icon for facet is visible or hidden.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
{boolean}bShowRemoveFacetIcon New value for property showRemoveFacetIcon
Since:
1.20.4
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
setWordWrap(bWordWrap): sap.m.FacetFilterList
Sets a new value for property wordWrap.

If set to true, the item text wraps when it is too long.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is false.

Parameters:
{boolean}bWordWrap New value for property wordWrap
Returns:
{sap.m.FacetFilterList} Reference to this in order to allow method chaining
getMultiSelect(): boolean
Gets current value of property multiSelect.

Specifies whether multiple or single selection is used.

Default value is true.

Deprecated:
Since version 1.20.0. This property is no longer supported. Use the setMode method instead. FacetFilterList overrides the setMode method to restrict the possible modes to MultiSelect and SingleSelectMaster. All other modes are ignored and will not be set.
Returns:
{boolean} Value of property multiSelect