instance

This method creates and retrieves the singleton instance of OMMainThread.

Visibility
Public
Signature
static OMThread* instance (int create = 1);
Parameters
create

Specifies whether an instance should be created. If this is set to 1, an OMMainThread instance is created.

If create is set to 0, the instance method returns one of the following values:

Returns

OMThread*

Notes

If a main thread does not exist, OMMainThread creates one and returns OMMainThread. If a main thread already exists, OMMainThread returns the OMMainThread.


Feedback