TAO_ExtId Class Reference

Helper class for TAO_Transient_Bindings_Map: unifies several data items, so they can be stored together as a for a in a hash table holding the state of a Transient Naming Context. More...

#include <Entries.h>

List of all members.

Public Member Functions

 TAO_ExtId (void)
 Constructor.

 TAO_ExtId (const char *id, const char *kind)
 Constructor.

 TAO_ExtId (const TAO_ExtId &rhs)
 Copy constructor.

 ~TAO_ExtId (void)
 Destructor.

void operator= (const TAO_ExtId &rhs)
 Assignment operator (does copy memory).

bool operator== (const TAO_ExtId &rhs) const
 Equality comparison operator (must match both id_ and kind_).

bool operator!= (const TAO_ExtId &rhs) const
 Inequality comparison operator.

u_long hash (void) const
const char * id (void)
 Return in a const char * format.

const char * kind (void)
 Return in a const char * format.


Public Attributes

ACE_CString kind_
ACE_CString id_


Detailed Description

Helper class for TAO_Transient_Bindings_Map: unifies several data items, so they can be stored together as a for a in a hash table holding the state of a Transient Naming Context.

This class holds id and kind strings, so they can be stored together as a for a in a hash table holding the state of a Transient Naming Context.

Definition at line 84 of file Entries.h.


Constructor & Destructor Documentation

TAO_ExtId::TAO_ExtId void   ) 
 

Constructor.

Definition at line 60 of file Entries.cpp.

00061   : kind_ (),
00062     id_ ()
00063 {
00064 }

TAO_ExtId::TAO_ExtId const char *  id,
const char *  kind
 

Constructor.

Definition at line 66 of file Entries.cpp.

00068   : kind_ (kind),
00069     id_ (id)
00070 {
00071 }

TAO_ExtId::TAO_ExtId const TAO_ExtId rhs  ) 
 

Copy constructor.

Definition at line 73 of file Entries.cpp.

References id_, and kind_.

00074 {
00075   id_ = rhs.id_;
00076   kind_ = rhs.kind_;
00077 }

TAO_ExtId::~TAO_ExtId void   ) 
 

Destructor.

Definition at line 79 of file Entries.cpp.

00080 {
00081 }


Member Function Documentation

u_long TAO_ExtId::hash void   )  const
 

function is required in order for this class to be usable by ACE_Hash_Map_Manager.

Definition at line 119 of file Entries.cpp.

References ACE_CString.

00120 {
00121   ACE_CString temp (id_);
00122   temp += kind_;
00123 
00124   return temp.hash ();
00125 }

const char * TAO_ExtId::id void   ) 
 

Return in a const char * format.

Definition at line 84 of file Entries.cpp.

00085 {
00086   return id_.fast_rep ();
00087 }

const char * TAO_ExtId::kind void   ) 
 

Return in a const char * format.

Definition at line 90 of file Entries.cpp.

00091 {
00092   return kind_.fast_rep ();
00093 }

bool TAO_ExtId::operator!= const TAO_ExtId rhs  )  const
 

Inequality comparison operator.

Definition at line 113 of file Entries.cpp.

References id_, and kind_.

00114 {
00115   return id_ != rhs.id_ || kind_ != rhs.kind_;
00116 }

void TAO_ExtId::operator= const TAO_ExtId rhs  ) 
 

Assignment operator (does copy memory).

Definition at line 96 of file Entries.cpp.

References id_, and kind_.

00097 {
00098   // Check for self assignment.
00099   if (&rhs == this)
00100     return;
00101 
00102   id_ = rhs.id_;
00103   kind_ = rhs.kind_;
00104 }

bool TAO_ExtId::operator== const TAO_ExtId rhs  )  const
 

Equality comparison operator (must match both id_ and kind_).

Definition at line 107 of file Entries.cpp.

References id_, and kind_.

00108 {
00109   return id_ == rhs.id_ && kind_ == rhs.kind_;
00110 }


Member Data Documentation

ACE_CString TAO_ExtId::id_
 

portion of the name to be associated with some object reference in a Transient Naming Context.

Definition at line 125 of file Entries.h.

Referenced by operator!=(), operator=(), operator==(), and TAO_ExtId().

ACE_CString TAO_ExtId::kind_
 

portion of the name to be associated with some object reference in a Transient Naming Context.

Definition at line 121 of file Entries.h.

Referenced by operator!=(), operator=(), operator==(), and TAO_ExtId().


The documentation for this class was generated from the following files:
Generated on Thu Nov 9 13:57:36 2006 for TAO_CosNaming by doxygen 1.3.6