Class: QgsRuntimeProfiler

class qgis.core.QgsRuntimeProfiler

Bases: sip.wrapper

Constructor to create a new runtime profiler.

QgsRuntimeProfiler(QgsRuntimeProfiler)

Methods

beginGroup

Begin the group for the profiler.

childGroups

Returns a list of all child groups with the specified parent.

clear

clear Clear all profile data.

end

End the current profile event.

endGroup

End the current active group.

profileTime

Returns the profile time for the specified name.

start

Start a profile event with the given name.

totalTime

The current total time collected in the profiler.

beginGroup(self, name: str)

Begin the group for the profiler. Groups will append {GroupName}/ to the front of the profile tag set using start.

Parameters

name (str) – The name of the group.

Deprecated since version use: start() instead

childGroups(self, parent: str = '') → List[str]

Returns a list of all child groups with the specified parent.

New in version 3.14.

Parameters

parent (str = '') –

Return type

List[str]

clear(self)

clear Clear all profile data.

end(self)

End the current profile event.

endGroup(self)

End the current active group.

Deprecated since version use: end() instead

profile

alias of qgis.core.additions.runtimeprofiler.ScopedRuntimeProfileContextManager

profileTime(self, name: str) → float

Returns the profile time for the specified name.

New in version 3.14.

Parameters

name (str) –

Return type

float

start(self, name: str)

Start a profile event with the given name.

Parameters

name (str) – The name of the profile event. Will have the name of the active group appended after ending.

totalTime(self) → float

The current total time collected in the profiler.

Return type

float

Returns

The current total time collected in the profiler.