Menu

Duration Events

       When reporting the preset event _appEnd, the duration starting from the last _appStart will be reported by default. That is, the duration of an exit event does not need to be configured additionally.

       It should be noted that there can only be one timing task for the same event. If set multiple times, only the last setting will take effect.


Create Duration Event

      Call eventStart to start timing. Configure the event name, and event properties to report. When the event comes to an end, a "_duration" property will automatically be added for this event (unit: millisecond).

ParameterDescriptionTypeRequired
eventNameCustom duration event nameStringYes

Sample Code

solarengine.eventStart("test");


Report Duration Event

       Call eventFinish to report duration event:

Parameters:

ParameterDescriptionTypeRequired
eventNameCustom duration event namestringYes
customPropertiesCustom duration event propertyobjectNo

Sample Code

let customProperties = {
	test1:"key1",
	test2:2,
	test3:[1,"2"]
}
solarengine.eventFinish("test",customProperties);

Note:

When reporting the preset event _appEnd, the duration will be automatically calculated based on the time elapsed since the last _appStart. This means the duration of the _appEnd event does not need to be manually configured, as it will be assigned by default.



Previous
Custom Events
Next
First-Time Event
Last modified: 2025-09-23Powered by