namespace sap/ui/performance/Measurement

Visiblity: public
Available since: N/A
Module: sap/ui/performance/Measurement
Application Component:

Performance Measurement API.


Nodes Overview

Node Description
sap/ui/performance/Measurement.Entry

Single Measurement Entry.


Methods Overview

Method Description
module:sap/ui/performance/Measurement.add

Adds a performance measurement with all data.

This is useful to add external measurements (e.g. from a backend) to the common measurement UI

module:sap/ui/performance/Measurement.average

Starts an average performance measure.

The duration of this measure is an avarage of durations measured for each call. Optionally a category or list of categories can be passed to allow filtering of measurements.

module:sap/ui/performance/Measurement.clear

Clears all performance measurements.

module:sap/ui/performance/Measurement.end

Ends a performance measure.

module:sap/ui/performance/Measurement.filterMeasurements

Gets all performance measurements where a provided filter function returns a truthy value.

If neither a filter function nor a category is provided an empty array is returned. To filter for certain properties of measurements a fnFilter can be implemented like this function(oMeasurement) { return oMeasurement.duration > 50; }

module:sap/ui/performance/Measurement.getActive

Gets the current state of the performance measurement functionality.

module:sap/ui/performance/Measurement.getAllMeasurements

Gets all performance measurements.

module:sap/ui/performance/Measurement.getMeasurement

Gets a performance measure.

module:sap/ui/performance/Measurement.pause

Pauses a performance measure.

module:sap/ui/performance/Measurement.registerMethod

Registers an average measurement for a given objects method.

module:sap/ui/performance/Measurement.remove

Removes a performance measure.

module:sap/ui/performance/Measurement.resume

Resumes a performance measure.

module:sap/ui/performance/Measurement.setActive

Activates or deactivates the performance measure functionality.

Optionally a category or list of categories can be passed to restrict measurements to certain categories like "javascript", "require", "xmlhttprequest", "render"

module:sap/ui/performance/Measurement.start

Starts a performance measure.

Optionally a category or list of categories can be passed to allow filtering of measurements.

module:sap/ui/performance/Measurement.unregisterAllMethods

Unregisters all average measurements.

module:sap/ui/performance/Measurement.unregisterMethod

Unregisters an average measurement for a given objects method.

module:sap/ui/performance/Measurement.add

Adds a performance measurement with all data.

This is useful to add external measurements (e.g. from a backend) to the common measurement UI

Param Type DefaultValue Description
sId string

ID of the measurement

sInfo string

Info for the measurement

iStart int

start timestamp

iEnd int

end timestamp

iTime int

time in milliseconds

iDuration int

effective time in milliseconds

aCategories string string[] "javascript"

An optional list of categories for the measure

module:sap/ui/performance/Measurement.average

Starts an average performance measure.

The duration of this measure is an avarage of durations measured for each call. Optionally a category or list of categories can be passed to allow filtering of measurements.

Param Type DefaultValue Description
sId string

ID of the measurement

sInfo string

Info for the measurement

aCategories string string[] "javascript"

An optional list of categories for the measure

module:sap/ui/performance/Measurement.clear

Clears all performance measurements.

Param Type DefaultValue Description

module:sap/ui/performance/Measurement.end

Ends a performance measure.

Param Type DefaultValue Description
sId string

ID of the measurement

module:sap/ui/performance/Measurement.filterMeasurements

Gets all performance measurements where a provided filter function returns a truthy value.

If neither a filter function nor a category is provided an empty array is returned. To filter for certain properties of measurements a fnFilter can be implemented like this function(oMeasurement) { return oMeasurement.duration > 50; }

Param Type DefaultValue Description
fnFilter function

a filter function that returns true if the passed measurement should be added to the result

bCompleted boolean

Optional parameter to determine if either completed or incomplete measurements should be returned (both if not set or undefined)

aCategories string[]

The function returns only measurements which match these specified categories

module:sap/ui/performance/Measurement.getActive

Gets the current state of the performance measurement functionality.

Param Type DefaultValue Description

module:sap/ui/performance/Measurement.getAllMeasurements

Gets all performance measurements.

Param Type DefaultValue Description
bCompleted boolean

Whether only completed measurements should be returned, if explicitly set to false only incomplete measurements are returned

module:sap/ui/performance/Measurement.getMeasurement

Gets a performance measure.

Param Type DefaultValue Description
sId string

ID of the measurement

module:sap/ui/performance/Measurement.pause

Pauses a performance measure.

Param Type DefaultValue Description
sId string

ID of the measurement

module:sap/ui/performance/Measurement.registerMethod

Registers an average measurement for a given objects method.

Param Type DefaultValue Description
sId string

the id of the measurement

oObject object

the object of the method

sMethod string

the name of the method

aCategories string[] ["javascript"]

An optional categories list for the measurement

module:sap/ui/performance/Measurement.remove

Removes a performance measure.

Param Type DefaultValue Description
sId string

ID of the measurement

module:sap/ui/performance/Measurement.resume

Resumes a performance measure.

Param Type DefaultValue Description
sId string

ID of the measurement

module:sap/ui/performance/Measurement.setActive

Activates or deactivates the performance measure functionality.

Optionally a category or list of categories can be passed to restrict measurements to certain categories like "javascript", "require", "xmlhttprequest", "render"

Param Type DefaultValue Description
bOn boolean

state of the performance measurement functionality to set

aCategories string string[]

An optional list of categories that should be measured

module:sap/ui/performance/Measurement.start

Starts a performance measure.

Optionally a category or list of categories can be passed to allow filtering of measurements.

Param Type DefaultValue Description
sId string

ID of the measurement

sInfo string

Info for the measurement

aCategories string string[] "javascript"

An optional list of categories for the measure

module:sap/ui/performance/Measurement.unregisterAllMethods

Unregisters all average measurements.

Param Type DefaultValue Description

module:sap/ui/performance/Measurement.unregisterMethod

Unregisters an average measurement for a given objects method.

Param Type DefaultValue Description
sId string

the id of the measurement

oObject object

the object of the method

sMethod string

the name of the method