Class sap.suite.ui.commons.TargetFilterModule: sap/suite/ui/commons/TargetFilter

extends Control

The analytical filter control. The control works only with the OData model connected to the analytical OData service (for example, HANA XS Analytical view exposed as an OData service).

Deprecated API:Since version 1.34. Deprecated.

Constructor Summary
new sap.suite.ui.commons.TargetFilter(sId?, mSettings?)Constructor for a new TargetFilter.
Event Summary
cancel(oControlEvent)This event is fired if the user changes a selected filter set to the filter set used for the last search.
filterChange(oControlEvent)This event is fired if the user changes a selected filter set.
search(oControlEvent)This event is fired if the user chooses the Show Selected link.
Events borrowed from class sap.ui.core.Control
Method Summary
sap.suite.ui.commons.TargetFilter.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.suite.ui.commons.TargetFilter with name sClassName and enriches it with the information contained in oClassInfo.
sap.suite.ui.commons.TargetFilter.getMetadata()Returns a metadata object for class sap.suite.ui.commons.TargetFilter.
addColumn(oColumn)Adds some column oColumn to the aggregation named columns.
addSelectedColumn(vSelectedColumn)
attachCancel(oData?, fnFunction, oListener?)Attach event handler fnFunction to the 'cancel' event of this sap.suite.ui.commons.TargetFilter.
attachFilterChange(oData?, fnFunction, oListener?)Attach event handler fnFunction to the 'filterChange' event of this sap.suite.ui.commons.TargetFilter.
attachSearch(oData?, fnFunction, oListener?)Attach event handler fnFunction to the 'search' event of this sap.suite.ui.commons.TargetFilter.
destroyColumns()Destroys all the columns in the aggregation named columns.
destroyMeasureColumn()Destroys the measureColumn in the aggregation named measureColumn.
detachCancel(fnFunction, oListener)Detach event handler fnFunction from the 'cancel' event of this sap.suite.ui.commons.TargetFilter.
detachFilterChange(fnFunction, oListener)Detach event handler fnFunction from the 'filterChange' event of this sap.suite.ui.commons.TargetFilter.
detachSearch(fnFunction, oListener)Detach event handler fnFunction from the 'search' event of this sap.suite.ui.commons.TargetFilter.
fireCancel(mArguments?)Fire event cancel to attached listeners.
fireFilterChange(mArguments?)Fire event filterChange to attached listeners.
fireSearch(mArguments?)Fire event search to attached listeners.
getColumns()Getter for aggregation columns.
getEntitySet()Getter for property entitySet.
getFilters()Returns a selected filter set.
getMeasureColumn()Getter for aggregation measureColumn.
getParameters()Returns the binding parameters for the controls that use this control.
getSelectedColumns()The list of selected columns.
indexOfColumn(oColumn)Checks for the provided sap.suite.ui.commons.TargetFilterColumn in the aggregation named columns and returns its index if found or -1 otherwise.
insertColumn(oColumn, iIndex)Inserts a column into the aggregation named columns.
removeAllColumns()Removes all the controls in the aggregation named columns.
removeColumn(vColumn)Removes an column from the aggregation named columns.
removeSelectedColumn(vSelectedColumn)
search()Triggers filtering in the controls that use this control.
setEntitySet(sEntitySet)Setter for property entitySet.
setMeasureColumn(oMeasureColumn)Setter for the aggregated measureColumn.
Constructor Detail
new sap.suite.ui.commons.TargetFilter(sId?, mSettings?)
Constructor for a new TargetFilter.

Accepts an object literal mSettings that defines initial property values, aggregated and associated objects as well as event handlers.

If the name of a setting is ambiguous (e.g. a property has the same name as an event), then the framework assumes property, aggregation, association, event in that order. To override this automatic resolution, one of the prefixes "aggregation:", "association:" or "event:" can be added to the name of the setting (such a prefixed name must be enclosed in single or double quotes).

The supported settings are:

  • Properties
  • Aggregations
    • columns : sap.suite.ui.commons.TargetFilterColumn[]
    • measureColumn : sap.suite.ui.commons.TargetFilterMeasureColumn
  • Associations
  • Events
    • search : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • filterChange : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • cancel : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
Parameters:
{string}sId? id for the new control, generated automatically if no id is given
{object}mSettings? initial settings for the new control
Deprecated:
Since version 1.34. Deprecated.
Event Detail
cancel(oControlEvent)
This event is fired if the user changes a selected filter set to the filter set used for the last search.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
filterChange(oControlEvent)
This event is fired if the user changes a selected filter set.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
search(oControlEvent)
This event is fired if the user chooses the Show Selected link.
Parameters:
{sap.ui.base.Event}oControlEvent
{sap.ui.base.EventProvider}oControlEvent.getSource
{object}oControlEvent.getParameters
Method Detail
sap.suite.ui.commons.TargetFilter.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.suite.ui.commons.TargetFilter with name sClassName and enriches it with the information contained in oClassInfo.

oClassInfo might contain the same kind of informations as described in Element.extend.

Parameters:
{string}sClassName name of the class to be created
{object}oClassInfo? object literal with informations about the class
{function}FNMetaImpl? constructor function for the metadata object. If not given, it defaults to sap.ui.core.ElementMetadata.
Returns:
{function} the created class / constructor function
sap.suite.ui.commons.TargetFilter.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.suite.ui.commons.TargetFilter.
Returns:
{sap.ui.base.Metadata} Metadata object describing this class
Adds some column oColumn to the aggregation named columns.
Parameters:
{sap.suite.ui.commons.TargetFilterColumn}oColumn the column to add; if empty, nothing is inserted
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
addSelectedColumn(vSelectedColumn): sap.suite.ui.commons.TargetFilter
Parameters:
{string|sap.suite.ui.commons.TargetFilterColumn}vSelectedColumn Id of a selectedColumn which becomes an additional target of this selectedColumns association. Alternatively, a selectedColumn instance may be given.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
attachCancel(oData?, fnFunction, oListener?): sap.suite.ui.commons.TargetFilter
Attach event handler fnFunction to the 'cancel' event of this sap.suite.ui.commons.TargetFilter.
. When called, the context of the event handler (its this) will be bound to oListener if specified otherwise to this sap.suite.ui.commons.TargetFilter.
itself.

This event is fired if the user changes a selected filter set to the filter set used for the last search.

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 call, when the event occurs.
{object}oListener? Context object to call the event handler with. Defaults to this sap.suite.ui.commons.TargetFilter.
itself.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
attachFilterChange(oData?, fnFunction, oListener?): sap.suite.ui.commons.TargetFilter
Attach event handler fnFunction to the 'filterChange' event of this sap.suite.ui.commons.TargetFilter.
. When called, the context of the event handler (its this) will be bound to oListener if specified otherwise to this sap.suite.ui.commons.TargetFilter.
itself.

This event is fired if the user changes a selected filter set.

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 call, when the event occurs.
{object}oListener? Context object to call the event handler with. Defaults to this sap.suite.ui.commons.TargetFilter.
itself.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
attachSearch(oData?, fnFunction, oListener?): sap.suite.ui.commons.TargetFilter
Attach event handler fnFunction to the 'search' event of this sap.suite.ui.commons.TargetFilter.
. When called, the context of the event handler (its this) will be bound to oListener if specified otherwise to this sap.suite.ui.commons.TargetFilter.
itself.

This event is fired if the user chooses the Show Selected link.

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 call, when the event occurs.
{object}oListener? Context object to call the event handler with. Defaults to this sap.suite.ui.commons.TargetFilter.
itself.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
Destroys all the columns in the aggregation named columns.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
destroyMeasureColumn(): sap.suite.ui.commons.TargetFilter
Destroys the measureColumn in the aggregation named measureColumn.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
detachCancel(fnFunction, oListener): sap.suite.ui.commons.TargetFilter
Detach event handler fnFunction from the 'cancel' event of this sap.suite.ui.commons.TargetFilter.

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

Parameters:
{function}fnFunction The function to call, when the event occurs.
{object}oListener Context object on which the given function had to be called.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
detachFilterChange(fnFunction, oListener): sap.suite.ui.commons.TargetFilter
Detach event handler fnFunction from the 'filterChange' event of this sap.suite.ui.commons.TargetFilter.

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

Parameters:
{function}fnFunction The function to call, when the event occurs.
{object}oListener Context object on which the given function had to be called.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
detachSearch(fnFunction, oListener): sap.suite.ui.commons.TargetFilter
Detach event handler fnFunction from the 'search' event of this sap.suite.ui.commons.TargetFilter.

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

Parameters:
{function}fnFunction The function to call, when the event occurs.
{object}oListener Context object on which the given function had to be called.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
fireCancel(mArguments?): sap.suite.ui.commons.TargetFilter
Fire event cancel to attached listeners.
Parameters:
{Map}mArguments? the arguments to pass along with the event.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
fireFilterChange(mArguments?): sap.suite.ui.commons.TargetFilter
Fire event filterChange to attached listeners.
Parameters:
{Map}mArguments? the arguments to pass along with the event.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
fireSearch(mArguments?): sap.suite.ui.commons.TargetFilter
Fire event search to attached listeners.
Parameters:
{Map}mArguments? the arguments to pass along with the event.
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
Getter for aggregation columns.
The list of the columns.
Returns:
{sap.suite.ui.commons.TargetFilterColumn[]}
getEntitySet(): string
Getter for property entitySet. The name of the entity set from OData service metadata. The filtering applies to this entity set.

Default value is empty/undefined

Returns:
{string} the value of property entitySet
getFilters(): any
Returns a selected filter set.
Returns:
{any}
Getter for aggregation measureColumn.
The measure column.
Returns:
{sap.suite.ui.commons.TargetFilterMeasureColumn}
getParameters(): any
Returns the binding parameters for the controls that use this control.
Returns:
{any}
getSelectedColumns(): string[]
The list of selected columns. The index of the columns in this list corresponds to the quadrant.
Returns:
{string[]}
indexOfColumn(oColumn): int
Checks for the provided sap.suite.ui.commons.TargetFilterColumn in the aggregation named columns and returns its index if found or -1 otherwise.
Parameters:
{sap.suite.ui.commons.TargetFilterColumn}oColumn the column whose index is looked for.
Returns:
{int} the index of the provided control in the aggregation if found, or -1 otherwise
insertColumn(oColumn, iIndex): sap.suite.ui.commons.TargetFilter
Inserts a column into the aggregation named columns.
Parameters:
{sap.suite.ui.commons.TargetFilterColumn}oColumn the column to insert; if empty, nothing is inserted
{int}iIndex the 0-based index the column should be inserted at; for a negative value of iIndex, the column is inserted at position 0; for a value greater than the current size of the aggregation, the column is inserted at the last position
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
Removes all the controls in the aggregation named columns.
Additionally unregisters them from the hosting UIArea.
Returns:
{sap.suite.ui.commons.TargetFilterColumn[]} an array of the removed elements (might be empty)
removeAllSelectedColumns(): string[]
Returns:
{string[]} an array with the ids of the removed elements (might be empty)
Removes an column from the aggregation named columns.
Parameters:
{int|string|sap.suite.ui.commons.TargetFilterColumn}vColumn the column to remove or its index or id
Returns:
{sap.suite.ui.commons.TargetFilterColumn} the removed column or null
removeSelectedColumn(vSelectedColumn): string
Parameters:
{int|string|sap.suite.ui.commons.TargetFilterColumn}vSelectedColumn the selectedColumn to remove or its index or id
Returns:
{string} the id of the removed selectedColumn or null
Triggers filtering in the controls that use this control. Returns this control for the method chaining.

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.

Returns:
{sap.suite.ui.commons.TargetFilter}
setEntitySet(sEntitySet): sap.suite.ui.commons.TargetFilter
Setter for property entitySet.

Default value is empty/undefined

Parameters:
{string}sEntitySet new value for property entitySet
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining
setMeasureColumn(oMeasureColumn): sap.suite.ui.commons.TargetFilter
Setter for the aggregated measureColumn.
Parameters:
{sap.suite.ui.commons.TargetFilterMeasureColumn}oMeasureColumn
Returns:
{sap.suite.ui.commons.TargetFilter}this to allow method chaining