ACE 8.0.0
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Private Attributes | Friends | List of all members
ACE_TSS_Info Class Reference

Thread Specific Key management. More...

#include <OS_NS_Thread.h>

Public Types

typedef void(* Destructor) (void *)
 Declare pointer to function to destroy tss object.
 

Public Member Functions

 ACE_TSS_Info (ACE_thread_key_t key, Destructor dest=0)
 Constructor.
 
 ACE_TSS_Info ()
 Default constructor.
 
int key_in_use () const
 Returns 1 if the key is in use, 0 if not.
 
void key_in_use (int flag)
 
bool operator== (const ACE_TSS_Info &) const
 Check for equality.
 
bool operator!= (const ACE_TSS_Info &) const
 Check for inequality.
 
void dump ()
 Dump the state.
 

Private Attributes

ACE_thread_key_t key_
 Key to the thread-specific storage item.
 
Destructor destructor_
 "Destructor" that gets called when the item is finally released.
 
int thread_count_
 

Friends

class ACE_TSS_Cleanup
 

Detailed Description

Thread Specific Key management.

This class maps a key to a "destructor."

Member Typedef Documentation

◆ Destructor

typedef void(* ACE_TSS_Info::Destructor) (void *)

Declare pointer to function to destroy tss object.

Constructor & Destructor Documentation

◆ ACE_TSS_Info() [1/2]

ACE_TSS_Info::ACE_TSS_Info ( ACE_thread_key_t key,
ACE_TSS_Info::Destructor dest = 0 )

Constructor.

◆ ACE_TSS_Info() [2/2]

ACE_TSS_Info::ACE_TSS_Info ( )

Default constructor.

Member Function Documentation

◆ dump()

void ACE_TSS_Info::dump ( )

Dump the state.

◆ key_in_use() [1/2]

int ACE_TSS_Info::key_in_use ( ) const
inline

Returns 1 if the key is in use, 0 if not.

◆ key_in_use() [2/2]

void ACE_TSS_Info::key_in_use ( int flag)
inline

Mark the key as being in use if the flag is non-zero, or not in use if the flag is 0.

◆ operator!=()

bool ACE_TSS_Info::operator!= ( const ACE_TSS_Info & info) const

Check for inequality.

◆ operator==()

bool ACE_TSS_Info::operator== ( const ACE_TSS_Info & info) const

Check for equality.

Friends And Related Symbol Documentation

◆ ACE_TSS_Cleanup

Member Data Documentation

◆ destructor_

Destructor ACE_TSS_Info::destructor_
private

"Destructor" that gets called when the item is finally released.

◆ key_

ACE_thread_key_t ACE_TSS_Info::key_
private

Key to the thread-specific storage item.

◆ thread_count_

int ACE_TSS_Info::thread_count_
private

Count of threads that are using this key. Contains -1 when the key is not in use.


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