TAO_Notify_Container_T< TYPE > Class Template Reference

A template class that manages a collection. TYPE = type of collection. More...

#include <Container_T.h>

List of all members.

Public Member Functions

 TAO_Notify_Container_T (void)
 Constuctor.

virtual ~TAO_Notify_Container_T ()
 Destructor.

void init ()
 Init this object.

virtual void insert (TYPE *type)
 Insert object to this container.

virtual void remove (TYPE *type)
 Remove type from container_.

virtual void shutdown ()
 Shutdown.

COLLECTIONcollection (void)
 Collection.


Protected Attributes

COLLECTIONcollection_
 The collection data structure that we add objects to.


Private Types

typedef TAO_ESF_Proxy_Collection<
TYPE > 
COLLECTION


Detailed Description

template<class TYPE>
class TAO_Notify_Container_T< TYPE >

A template class that manages a collection. TYPE = type of collection.

Definition at line 35 of file Container_T.h.


Member Typedef Documentation

template<class TYPE>
typedef TAO_ESF_Proxy_Collection<TYPE> TAO_Notify_Container_T< TYPE >::COLLECTION [private]
 

Definition at line 37 of file Container_T.h.


Constructor & Destructor Documentation

template<class TYPE>
TAO_BEGIN_VERSIONED_NAMESPACE_DECL TAO_Notify_Container_T< TYPE >::TAO_Notify_Container_T void   ) 
 

Constuctor.

Definition at line 22 of file Container_T.cpp.

00023   : collection_ (0)
00024 {
00025 }

template<class TYPE>
TAO_Notify_Container_T< TYPE >::~TAO_Notify_Container_T  )  [virtual]
 

Destructor.

Definition at line 28 of file Container_T.cpp.

00029 {
00030   delete collection_;
00031 }


Member Function Documentation

template<class TYPE>
TAO_BEGIN_VERSIONED_NAMESPACE_DECL ACE_INLINE ACE_TYPENAME TAO_Notify_Container_T< TYPE >::COLLECTION * TAO_Notify_Container_T< TYPE >::collection void   ) 
 

Collection.

Definition at line 8 of file Container_T.inl.

Referenced by TAO_Notify_EventChannelFactory::reconnect(), TAO_Notify_EventChannel::reconnect(), TAO_Notify_Admin::reconnect(), TAO_Notify_EventChannelFactory::save_persistent(), TAO_Notify_EventChannel::save_persistent(), and TAO_Notify_Admin::save_persistent().

00009 {
00010   return this->collection_;
00011 }

template<class TYPE>
void TAO_Notify_Container_T< TYPE >::init  ) 
 

Init this object.

Definition at line 54 of file Container_T.cpp.

References ACE_ENV_ARG_PARAMETER, TAO_Notify_Factory::create(), and TAO_Singleton< TYPE, ACE_LOCK >::instance().

Referenced by TAO_Notify_EventChannelFactory::init(), TAO_Notify_EventChannel::init(), and TAO_Notify_Admin::init().

00055 {
00056   // get the factory
00057   TAO_Notify_Factory* factory = TAO_Notify_PROPERTIES::instance ()->factory ();
00058 
00059   // Init variables
00060   factory->create (this->collection_ ACE_ENV_ARG_PARAMETER);
00061 }

template<class TYPE>
void TAO_Notify_Container_T< TYPE >::insert TYPE *  type  )  [virtual]
 

Insert object to this container.

Definition at line 42 of file Container_T.cpp.

References ACE_ENV_ARG_PARAMETER.

Referenced by TAO_Notify_Admin::insert().

00043 {
00044   this->collection_->connected (type ACE_ENV_ARG_PARAMETER);
00045 }

template<class TYPE>
void TAO_Notify_Container_T< TYPE >::remove TYPE *  type  )  [virtual]
 

Remove type from container_.

Definition at line 48 of file Container_T.cpp.

References ACE_ENV_ARG_PARAMETER.

Referenced by TAO_Notify_EventChannelFactory::remove(), TAO_Notify_EventChannel::remove(), and TAO_Notify_Admin::remove().

00049 {
00050   this->collection_->disconnected (type ACE_ENV_ARG_PARAMETER);
00051 }

template<class TYPE>
void TAO_Notify_Container_T< TYPE >::shutdown  )  [virtual]
 

Shutdown.

Definition at line 34 of file Container_T.cpp.

References ACE_ENV_ARG_PARAMETER.

Referenced by TAO_Notify_EventChannelFactory::shutdown(), TAO_Notify_EventChannel::shutdown(), and TAO_Notify_Admin::shutdown().

00035 {
00036   TAO_ESF_Shutdown_Proxy<TYPE> shutdown_worker;
00037 
00038   this->collection_->for_each (&shutdown_worker ACE_ENV_ARG_PARAMETER);
00039 }


Member Data Documentation

template<class TYPE>
COLLECTION* TAO_Notify_Container_T< TYPE >::collection_ [protected]
 

The collection data structure that we add objects to.

Definition at line 63 of file Container_T.h.


The documentation for this class was generated from the following files:
Generated on Thu Nov 9 13:31:45 2006 for TAO_CosNotification by doxygen 1.3.6