namespace sap.ui.fl.ControlPersonalizationAPI

Visiblity: restricted
Available since: N/A
Module: sap/ui/fl/ControlPersonalizationAPI
Application Component: CA-UI5-FL

Provides an API to handle specific functionality for personalized changes.


Nodes Overview

Node Description
sap.ui.fl.ControlPersonalizationAPI.PersonalizationChange

Object containing attributes of a change, along with the control to which this change should be applied.


Methods Overview

Method Description
sap.ui.fl.ControlPersonalizationAPI.activateVariant

Activates the passed variant applicable to the passed control/component.

sap.ui.fl.ControlPersonalizationAPI.addPersonalizationChanges

Creates personalization changes, adds them to the flex persistence (not yet saved) and applies them to the control.

sap.ui.fl.ControlPersonalizationAPI.clearVariantParameterInURL

Clears URL technical parameter 'sap-ui-fl-control-variant-id' for control variants. If a variant management control is given as parameter, only parameters specific to that control are cleared.

sap.ui.fl.ControlPersonalizationAPI.hasVariantManagement

Determines the availability of an encompassing variant management control.

sap.ui.fl.ControlPersonalizationAPI.isPersonalized

Checks if personalization changes exists for control.

sap.ui.fl.ControlPersonalizationAPI.resetChanges

Deletes changes recorded for control. Changes to be deleted can be filtered by specification of change type(s).

sap.ui.fl.ControlPersonalizationAPI.saveChanges

Saves unsaved changes added to sap.ui.fl.ChangePersistence.

sap.ui.fl.ControlPersonalizationAPI.activateVariant

Activates the passed variant applicable to the passed control/component.

Param Type DefaultValue Description
vElement sap.ui.base.ManagedObject string

The component or control (instance or ID) on which the variantModel is set

sVariantReference string

The variant reference which needs to be activated

sap.ui.fl.ControlPersonalizationAPI.addPersonalizationChanges

Creates personalization changes, adds them to the flex persistence (not yet saved) and applies them to the control.

Param Type DefaultValue Description
mPropertyBag object

Changes along with other settings that need to be added

controlChanges array

Array of control changes of type sap.ui.fl.ControlPersonalizationAPI.PersonalizationChange

ignoreVariantManagement boolean false

If flag is set to true then variant management will be ignored

useStaticArea boolean false

If flag is set to true then the static area is used to determine the variant management control

sap.ui.fl.ControlPersonalizationAPI.clearVariantParameterInURL

Clears URL technical parameter 'sap-ui-fl-control-variant-id' for control variants. If a variant management control is given as parameter, only parameters specific to that control are cleared.

Param Type DefaultValue Description
oVariantManagementControl sap.ui.base.ManagedObject

The variant management control for which the URL technical parameter has to be cleared

sap.ui.fl.ControlPersonalizationAPI.hasVariantManagement

Determines the availability of an encompassing variant management control.

Param Type DefaultValue Description
oControl sap.ui.core.Element

The control which should be tested for an encompassing variant management control

sap.ui.fl.ControlPersonalizationAPI.isPersonalized

Checks if personalization changes exists for control.

Param Type DefaultValue Description
aControls sap.ui.core.Element[] Array<Object<string,any>>

an array of instances of controls, a map with control IDs including a app component or a mixture for which personalization exists

appComponent sap.ui.core.Component

Application component of the controls at runtime in case a map has been used

id string

ID of the control in case a map has been used to specify the control

aChangeTypes array

Types of changes that have existing personalization.

sap.ui.fl.ControlPersonalizationAPI.resetChanges

Deletes changes recorded for control. Changes to be deleted can be filtered by specification of change type(s).

Param Type DefaultValue Description
aControls sap.ui.core.Element[] Array<Object<string,any>>

an array of instances of controls, a map with control IDs including a app component or a mixture for which the reset shall take place

appComponent sap.ui.core.Component

Application component of the controls at runtime in case a map has been used

id string

ID of the control in case a map has been used to specify the control

aChangeTypes String[]

Types of changes that shall be deleted

sap.ui.fl.ControlPersonalizationAPI.saveChanges

Saves unsaved changes added to sap.ui.fl.ChangePersistence.

Param Type DefaultValue Description
aChanges array

Array of changes to be saved

oManagedObject sap.ui.base.ManagedObject

A managed object instance which has an application component responsible, on which changes need to be saved