Template Class CUniqueID#

Class Documentation#

template<typename TType = uint64_t, size_t nDepth = sizeof(TType) * 8>
class CUniqueID#

Create a unique ID using the random number generator.

Template Parameters:
  • TType – Type of the variable that represents the ID.

  • nDepth – The depth of the ID generation in bits.

Public Functions

inline CUniqueID()#

Constructor.

inline TType Generate()#

Generate a unique ID.

Returns:

The optional result with the ID if successful or 0 when not successful.