API reference
API reference
Select your platform
No SDKs available
No versions available

UniqueIdentifier Class

A numerical identifier guaranteed to be unique within an instance of an application.
This is used to uniquely associate instances with data they generate, most commonly PointerEvents retaining the IInteractorView.Identifier of their originating interactors as their own PointerEvent.Identifier.

Properties

The numerical identifier associated with this UniqueIdentifier.
This number is guaranteed to be unique at any given time within an instance of an application. "Unique at any given time" means there is never more than one valid UniqueIdentifier with the same ID at the same time within an instance of an application. However, different UniqueIdentifiers may have the same numerical ID if they do not exist at the same time as long as Release(UniqueIdentifier) has been called on the earlier instance before Generate produces the later.This number is often used in place of the UniqueIdentifier itself; for example, IInteractorView.Identifier and the PointerEvent.Identifiers which refer to it both leveral the numerical value of the interactor's underlying UniqueIdentifier.ID.

Static Member Functions

Creates a new UniqueIdentifier with a numerical which is guaranteed to be unique in the application for the lifespan of the new UniqueIdentifier (i.e., until Release(UniqueIdentifier) is called upon it).
Returns
Creates a new UniqueIdentifier with a numerical which is guaranteed to be unique in the application for the lifespan of the new UniqueIdentifier (i.e., until Release(UniqueIdentifier) is called upon it).
Associates that identifier with the provided instance for future retrieval via TryGetInstanceFromIdentifier(Context, int, out object).
Parameters
context
The context in which the instance will be associated with the new identifier
instance
The instance associated with the new identifier
Returns
Invalidates a UniqueIdentifier and returns its to the space of allowable s for new UniqueIdentifiers.
Any further use of the identifier after release is unsupported and can cause undefined behavior.
Parameters
identifier
The UniqueIdentifier to be invalidated
Attempts to retrieve the instance associated with the provided identifier in the given context .
Parameters
context
The Context in which to look for an instance association
identifier
The of the UniqueIdentifier for which to find the instance
instance
Out parameter, the discovered associated instance, if one exists
Returns
True if the instance was found, false otherwise
Attempts to retrieve the instance associated with the provided identifier in the provided context .
Parameters
context
The Context in which to look for an instance association
identifier
The of the UniqueIdentifier for which to find the instance
Returns
A task returning the associated instance, if one exists
Did you find this page helpful?