Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

TAO_ORB_Core_TSS_Resources Class Reference

The TSS resoures of an ORB core. More...

#include <ORB_Core.h>

Collaboration diagram for TAO_ORB_Core_TSS_Resources:

Collaboration graph
[legend]
List of all members.

Public Methods

 TAO_ORB_Core_TSS_Resources (void)
 Constructor. More...

 ~TAO_ORB_Core_TSS_Resources (void)
 destructor. More...


Public Attributes

int event_loop_thread_
 Counter for how (nested) calls this thread has made to run the event loop. More...

int client_leader_thread_
 Counter for how many times this thread has become a client leader. More...

void * lane_
 Lane for this thread. More...

ACE_Array_Base< void * > ts_objects_
 Generic container for thread-specific objects. More...

TAO_ORB_Coreorb_core_
 Pointer to the ORB core. Needed to get access to the TSS cleanup functions for the TSS objects stored in the TSS object array in this class. More...

TAO_PICurrent_Impl pi_current_
 The thread-specific portion of the PICurrent object. More...

TAO_ClientRequestInfoclient_request_info_
 The PortableInterceptor::ClientRequestInfo object for the current thread. More...

ACE_Allocatoroutput_cdr_dblock_allocator_
ACE_Allocatoroutput_cdr_buffer_allocator_
ACE_Allocatoroutput_cdr_msgblock_allocator_

Private Methods

 TAO_ORB_Core_TSS_Resources (const TAO_ORB_Core_TSS_Resources &)
 The ORB Core TSS resources should not be copied. More...

void operator= (const TAO_ORB_Core_TSS_Resources &)

Detailed Description

The TSS resoures of an ORB core.

This class is used by the ORB_Core to store the resources potentially bound to a thread in TSS storage. The members are public because only the ORB Core is expected to access them.

Definition at line 114 of file ORB_Core.h.


Constructor & Destructor Documentation

TAO_ORB_Core_TSS_Resources::TAO_ORB_Core_TSS_Resources void   
 

Constructor.

Definition at line 2713 of file ORB_Core.cpp.

References ACE_NEW.

02714   : output_cdr_dblock_allocator_ (0),
02715     output_cdr_buffer_allocator_ (0),
02716     output_cdr_msgblock_allocator_ (0),
02717     event_loop_thread_ (0),
02718     client_leader_thread_ (0),
02719     lane_ (0),
02720     ts_objects_ (),
02721     orb_core_ (0)
02722 #if TAO_HAS_INTERCEPTORS == 1
02723     , pi_current_ ()
02724     , client_request_info_ (0)
02725 #endif  /* TAO_HAS_INTERCEPTORS == 1 */
02726 {
02727 #if TAO_HAS_INTERCEPTORS == 1
02728   ACE_NEW (this->client_request_info_,
02729            TAO_ClientRequestInfo);
02730 #endif  /* TAO_HAS_INTERCEPTORS == 1 */
02731 }

TAO_ORB_Core_TSS_Resources::~TAO_ORB_Core_TSS_Resources void   
 

destructor.

Definition at line 2733 of file ORB_Core.cpp.

References output_cdr_buffer_allocator_, output_cdr_dblock_allocator_, output_cdr_msgblock_allocator_, CORBA::release, and ACE_Allocator::remove.

02734 {
02735   if (this->output_cdr_dblock_allocator_ != 0)
02736     this->output_cdr_dblock_allocator_->remove ();
02737   delete this->output_cdr_dblock_allocator_;
02738 
02739   if (this->output_cdr_buffer_allocator_ != 0)
02740     this->output_cdr_buffer_allocator_->remove ();
02741   delete this->output_cdr_buffer_allocator_;
02742 
02743   if (this->output_cdr_msgblock_allocator_ != 0)
02744     this->output_cdr_msgblock_allocator_->remove ();
02745   delete this->output_cdr_msgblock_allocator_;
02746 
02747 #if TAO_HAS_INTERCEPTORS == 1
02748   CORBA::release (this->client_request_info_);
02749 #endif  /* TAO_HAS_INTERCEPTORS == 1 */
02750 
02751   //@@ This is broken on platforms that use TSS emulation since this
02752   //   destructor is invoked after the ORB.  Since we're under
02753   //   pressure to release a beta, we'll have to leak the TSS objects
02754   //   stores in the <ts_objects_> array.  However, the only service
02755   //   known to currently use this array is the SSLIOP pluggable
02756   //   protocol.  Fortunately, it registeres a null cleanup function
02757   //   so we're not leaking anything yet.  We *do* need to fix this
02758   //   before other services start to use this array.
02759   //      -Ossama
02760   // if (this->orb_core_ != 0)
02761   //   this->orb_core_->tss_cleanup_funcs ()->cleanup (this->ts_objects_);
02762 }

TAO_ORB_Core_TSS_Resources::TAO_ORB_Core_TSS_Resources const TAO_ORB_Core_TSS_Resources &    [private]
 

The ORB Core TSS resources should not be copied.


Member Function Documentation

void TAO_ORB_Core_TSS_Resources::operator= const TAO_ORB_Core_TSS_Resources &    [private]
 


Member Data Documentation

int TAO_ORB_Core_TSS_Resources::client_leader_thread_
 

Counter for how many times this thread has become a client leader.

Definition at line 151 of file ORB_Core.h.

Referenced by TAO_Leader_Follower::is_client_leader_thread, TAO_Leader_Follower::reset_client_leader_thread, TAO_Leader_Follower::reset_client_thread, TAO_Leader_Follower::reset_event_loop_thread_i, TAO_Leader_Follower::set_client_leader_thread, TAO_Leader_Follower::set_client_thread, and TAO_Leader_Follower::set_event_loop_thread.

TAO_ClientRequestInfo* TAO_ORB_Core_TSS_Resources::client_request_info_
 

The PortableInterceptor::ClientRequestInfo object for the current thread.

Definition at line 170 of file ORB_Core.h.

int TAO_ORB_Core_TSS_Resources::event_loop_thread_
 

Counter for how (nested) calls this thread has made to run the event loop.

Todo:
The rest of the resources are not currently in use, just a plan for the future...

Definition at line 147 of file ORB_Core.h.

Referenced by TAO_Leader_Follower::reset_client_thread, TAO_Leader_Follower::reset_event_loop_thread, TAO_Leader_Follower::reset_event_loop_thread_i, TAO_Leader_Follower::set_client_thread, TAO_Leader_Follower::set_event_loop_thread, and TAO_Leader_Follower::set_upcall_thread.

void* TAO_ORB_Core_TSS_Resources::lane_
 

Lane for this thread.

Definition at line 154 of file ORB_Core.h.

TAO_ORB_Core* TAO_ORB_Core_TSS_Resources::orb_core_
 

Pointer to the ORB core. Needed to get access to the TSS cleanup functions for the TSS objects stored in the TSS object array in this class.

Definition at line 162 of file ORB_Core.h.

Referenced by TAO_ORB_Core::set_tss_resource.

ACE_Allocator* TAO_ORB_Core_TSS_Resources::output_cdr_buffer_allocator_
 

Definition at line 136 of file ORB_Core.h.

Referenced by TAO_ORB_Core::output_cdr_buffer_allocator, and ~TAO_ORB_Core_TSS_Resources.

ACE_Allocator* TAO_ORB_Core_TSS_Resources::output_cdr_dblock_allocator_
 

Definition at line 135 of file ORB_Core.h.

Referenced by TAO_ORB_Core::output_cdr_dblock_allocator, and ~TAO_ORB_Core_TSS_Resources.

ACE_Allocator* TAO_ORB_Core_TSS_Resources::output_cdr_msgblock_allocator_
 

Definition at line 137 of file ORB_Core.h.

Referenced by TAO_ORB_Core::output_cdr_msgblock_allocator, and ~TAO_ORB_Core_TSS_Resources.

TAO_PICurrent_Impl TAO_ORB_Core_TSS_Resources::pi_current_
 

The thread-specific portion of the PICurrent object.

Definition at line 166 of file ORB_Core.h.

Referenced by TAO_PICurrent::tsc.

ACE_Array_Base<void *> TAO_ORB_Core_TSS_Resources::ts_objects_
 

Generic container for thread-specific objects.

Definition at line 157 of file ORB_Core.h.

Referenced by TAO_ORB_Core::get_tss_resource, and TAO_ORB_Core::set_tss_resource.


The documentation for this class was generated from the following files:
Generated on Mon Jun 16 15:31:24 2003 for TAO by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002