ACE_At_Thread_Exit Class Reference

Contains a method to be applied when a thread is terminated. More...

#include <Thread_Manager.h>

Inheritance diagram for ACE_At_Thread_Exit:
Inheritance graph
[legend]
Collaboration diagram for ACE_At_Thread_Exit:
Collaboration graph
[legend]

List of all members.

Public Member Functions

 ACE_At_Thread_Exit (void)
 Default constructor.
virtual ~ACE_At_Thread_Exit (void)
 The destructor.
bool is_owner (void) const
 At_Thread_Exit has the ownership?
bool is_owner (bool owner)
 Set the ownership of the At_Thread_Exit.
bool was_applied (void) const
 This At_Thread_Exit was applied?
bool was_applied (bool applied)
 Set applied state of At_Thread_Exit.

Protected Member Functions

void do_apply (void)
 Do the apply if necessary.
virtual void apply (void)=0
 The apply method.

Protected Attributes

ACE_At_Thread_Exitnext_
 The next At_Thread_Exit hook in the list.
ACE_Thread_Descriptortd_
 The Thread_Descriptor where this at is registered.
bool was_applied_
 The at was applied?
bool is_owner_
 The at has the ownership of this?

Friends

class ACE_Thread_Descriptor
class ACE_Thread_Manager

Detailed Description

Contains a method to be applied when a thread is terminated.

Definition at line 89 of file Thread_Manager.h.


Constructor & Destructor Documentation

ACE_At_Thread_Exit::ACE_At_Thread_Exit ( void   ) 

Default constructor.

Definition at line 8 of file Thread_Manager.inl.

00009   : next_ (0),
00010     td_ (0),
00011     was_applied_ (false),
00012     is_owner_ (true)
00013 {
00014 }

virtual ACE_At_Thread_Exit::~ACE_At_Thread_Exit ( void   )  [virtual]

The destructor.


Member Function Documentation

virtual void ACE_At_Thread_Exit::apply ( void   )  [protected, pure virtual]

The apply method.

Implemented in ACE_At_Thread_Exit_Func.

void ACE_At_Thread_Exit::do_apply ( void   )  [protected]

Do the apply if necessary.

Definition at line 45 of file Thread_Manager.inl.

00046 {
00047   if (!this->was_applied_ && this->is_owner_)
00048     td_->at_pop();
00049 }

bool ACE_At_Thread_Exit::is_owner ( bool  owner  ) 

Set the ownership of the At_Thread_Exit.

Definition at line 38 of file Thread_Manager.inl.

00039 {
00040   is_owner_ = owner;
00041   return is_owner_;
00042 }

bool ACE_At_Thread_Exit::is_owner ( void   )  const

At_Thread_Exit has the ownership?

Definition at line 32 of file Thread_Manager.inl.

00033 {
00034   return is_owner_;
00035 }

bool ACE_At_Thread_Exit::was_applied ( bool  applied  ) 

Set applied state of At_Thread_Exit.

Definition at line 23 of file Thread_Manager.inl.

00024 {
00025   was_applied_ = applied;
00026   if (was_applied_)
00027     td_ = 0;
00028   return was_applied_;
00029 }

bool ACE_At_Thread_Exit::was_applied ( void   )  const

This At_Thread_Exit was applied?

Definition at line 17 of file Thread_Manager.inl.

00018 {
00019    return was_applied_;
00020 }


Friends And Related Function Documentation

friend class ACE_Thread_Descriptor [friend]

Definition at line 91 of file Thread_Manager.h.

friend class ACE_Thread_Manager [friend]

Definition at line 92 of file Thread_Manager.h.


Member Data Documentation

The at has the ownership of this?

Definition at line 129 of file Thread_Manager.h.

The next At_Thread_Exit hook in the list.

Definition at line 114 of file Thread_Manager.h.

The Thread_Descriptor where this at is registered.

Definition at line 123 of file Thread_Manager.h.

The at was applied?

Definition at line 126 of file Thread_Manager.h.


The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines

Generated on Sun Nov 22 23:13:49 2009 for ACE by  doxygen 1.6.1