ACE 8.0.3
Loading...
Searching...
No Matches
Classes | Public Types | Public Member Functions | Public Attributes | Static Public Attributes | Private Member Functions | Private Attributes | List of all members
ACE_Utils::UUID Class Reference

#include <UUID.h>

Collaboration diagram for ACE_Utils::UUID:
Collaboration graph
[legend]

Classes

struct  data
 Data Members for Class Attributes. More...
 

Public Types

enum  { BINARY_SIZE = 16 }
 The size of a binary UUID. More...
 

Public Member Functions

 UUID ()
 Constructor.
 
 UUID (const ACE_CString &uuidString)
 Constructs a UUID from a string representation.
 
 UUID (const UUID &right)
 
 ~UUID ()=default
 
ACE_UINT32 time_low () const
 
void time_low (ACE_UINT32)
 
ACE_UINT16 time_mid () const
 
void time_mid (ACE_UINT16)
 
ACE_UINT16 time_hi_and_version () const
 
void time_hi_and_version (ACE_UINT16)
 
u_char clock_seq_hi_and_reserved () const
 
void clock_seq_hi_and_reserved (u_char)
 
u_char clock_seq_low () const
 
void clock_seq_low (u_char)
 
UUID_Nodenode ()
 
const UUID_Nodenode () const
 
void node (const UUID_Node &node)
 
ACE_CStringthr_id ()
 
void thr_id (char *)
 
ACE_CStringpid ()
 
void pid (char *)
 
const ACE_CStringto_string () const
 Returns a string representation of the UUID.
 
void from_string (const ACE_CString &uuid_string)
 Set the value using a string.
 
bool operator== (const UUID &right) const
 Equality Operations.
 
bool operator!= (const UUID &right) const
 
unsigned long hash () const
 Compute a hash value for the UUID.
 
const UUIDoperator= (const UUID &rhs)
 Assign an existing UUID to this UUID.
 

Public Attributes

 ACE_ALLOC_HOOK_DECLARE
 

Static Public Attributes

static const UUID NIL_UUID
 NIL UUID.
 

Private Member Functions

void init ()
 Initialize the UUID.
 
void from_string_i (const ACE_CString &uuid_string)
 

Private Attributes

struct ACE_Utils::UUID::data uuid_
 
ACE_CString thr_id_
 
ACE_CString pid_
 
std::unique_ptr< ACE_CStringas_string_
 

Member Enumeration Documentation

◆ anonymous enum

The size of a binary UUID.

Enumerator
BINARY_SIZE 

Constructor & Destructor Documentation

◆ UUID() [1/3]

ACE_Utils::UUID::UUID ( )
inline

Constructor.

◆ UUID() [2/3]

ACE_Utils::UUID::UUID ( const ACE_CString & uuidString)

Constructs a UUID from a string representation.

◆ UUID() [3/3]

ACE_Utils::UUID::UUID ( const UUID & right)
inline

◆ ~UUID()

ACE_Utils::UUID::~UUID ( )
default

Member Function Documentation

◆ clock_seq_hi_and_reserved() [1/2]

u_char ACE_Utils::UUID::clock_seq_hi_and_reserved ( ) const
inline

◆ clock_seq_hi_and_reserved() [2/2]

void ACE_Utils::UUID::clock_seq_hi_and_reserved ( u_char clock_seq_hi_and_reserved)
inline

◆ clock_seq_low() [1/2]

u_char ACE_Utils::UUID::clock_seq_low ( ) const
inline

◆ clock_seq_low() [2/2]

void ACE_Utils::UUID::clock_seq_low ( u_char clock_seq_low)
inline

◆ from_string()

void ACE_Utils::UUID::from_string ( const ACE_CString & uuid_string)
inline

Set the value using a string.

◆ from_string_i()

void ACE_Utils::UUID::from_string_i ( const ACE_CString & uuid_string)
private

Helper method to convert from a string UUID.

Parameters
[in]uuid_stringString version of UUID.

Special case for the nil UUID.

Support versions 1, 3, and 4 only

◆ hash()

unsigned long ACE_Utils::UUID::hash ( ) const
inline

Compute a hash value for the UUID.

◆ init()

void ACE_Utils::UUID::init ( )
inlineprivate

Initialize the UUID.

◆ node() [1/3]

UUID_Node & ACE_Utils::UUID::node ( )
inline

◆ node() [2/3]

const UUID_Node & ACE_Utils::UUID::node ( ) const
inline

◆ node() [3/3]

void ACE_Utils::UUID::node ( const UUID_Node & node)
inline

◆ operator!=()

bool ACE_Utils::UUID::operator!= ( const UUID & right) const
inline

◆ operator=()

const UUID & ACE_Utils::UUID::operator= ( const UUID & rhs)

Assign an existing UUID to this UUID.

Todo
We should create an UUID_Ex class for UUIDs that contain the thread id and process id.

◆ operator==()

bool ACE_Utils::UUID::operator== ( const UUID & right) const
inline

Equality Operations.

◆ pid() [1/2]

ACE_CString * ACE_Utils::UUID::pid ( )
inline

◆ pid() [2/2]

void ACE_Utils::UUID::pid ( char * pid)
inline

◆ thr_id() [1/2]

ACE_CString * ACE_Utils::UUID::thr_id ( )
inline

◆ thr_id() [2/2]

void ACE_Utils::UUID::thr_id ( char * thr_id)
inline

◆ time_hi_and_version() [1/2]

ACE_UINT16 ACE_Utils::UUID::time_hi_and_version ( ) const
inline

◆ time_hi_and_version() [2/2]

void ACE_Utils::UUID::time_hi_and_version ( ACE_UINT16 time_hi_and_version)
inline

◆ time_low() [1/2]

ACE_UINT32 ACE_Utils::UUID::time_low ( ) const
inline

◆ time_low() [2/2]

void ACE_Utils::UUID::time_low ( ACE_UINT32 timelow)
inline

◆ time_mid() [1/2]

ACE_UINT16 ACE_Utils::UUID::time_mid ( ) const
inline

◆ time_mid() [2/2]

void ACE_Utils::UUID::time_mid ( ACE_UINT16 time_mid)
inline

◆ to_string()

const ACE_CString * ACE_Utils::UUID::to_string ( ) const

Returns a string representation of the UUID.

Member Data Documentation

◆ ACE_ALLOC_HOOK_DECLARE

ACE_Utils::UUID::ACE_ALLOC_HOOK_DECLARE

◆ as_string_

std::unique_ptr<ACE_CString> ACE_Utils::UUID::as_string_
mutableprivate

The string representation of the UUID. This is created and updated only on demand.

◆ NIL_UUID

const UUID ACE_Utils::UUID::NIL_UUID
static

NIL UUID.

◆ pid_

ACE_CString ACE_Utils::UUID::pid_
private

◆ thr_id_

ACE_CString ACE_Utils::UUID::thr_id_
private

◆ uuid_

struct ACE_Utils::UUID::data ACE_Utils::UUID::uuid_
private

The documentation for this class was generated from the following files: