OW_NAMESPACE::PollingManager Class Reference

#include <OW_PollingManager.hpp>

Inheritance diagram for OW_NAMESPACE::PollingManager:

Inheritance graph
[legend]
Collaboration diagram for OW_NAMESPACE::PollingManager:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 PollingManager (const ProviderManagerRef &providerManager)
virtual ~PollingManager ()
virtual String getName () const
 Every service may have a name.
virtual StringArray getDependencies () const
 Get the list of services this service depends on.
virtual void init (const ServiceEnvironmentIFCRef &env)
 init() will be called to give the derived class an opportunity to initialize itself.
virtual void start ()
 In start(), a service should start doing whatever it does, such as starting a new thread or adding selectables to the environment.
virtual void shutdown ()
 The service must shutdown completely before returning from this function.
void addPolledProvider (const PolledProviderIFCRef &p)

Private Attributes

IntrusiveReference< PollingManagerThreadm_pollingManagerThread

Detailed Description

Definition at line 58 of file OW_PollingManager.hpp.


Constructor & Destructor Documentation

OW_NAMESPACE::PollingManager::PollingManager const ProviderManagerRef providerManager  ) 
 

Definition at line 82 of file OW_PollingManager.cpp.

OW_NAMESPACE::PollingManager::~PollingManager  )  [virtual]
 

Definition at line 89 of file OW_PollingManager.cpp.


Member Function Documentation

void OW_NAMESPACE::PollingManager::addPolledProvider const PolledProviderIFCRef p  ) 
 

Definition at line 117 of file OW_PollingManager.cpp.

References m_pollingManagerThread.

StringArray OW_NAMESPACE::PollingManager::getDependencies  )  const [virtual]
 

Get the list of services this service depends on.

The returned services will be started before and shutdown after this service. It is an error to return the name of a non-existent service, and the cimom startup will fail. The default is to have no dependencies.

Reimplemented from OW_NAMESPACE::ServiceIFC.

Definition at line 145 of file OW_PollingManager.cpp.

References OW_NAMESPACE::ServiceIFCNames::CIMServer, and OW_NAMESPACE::Array< T >::push_back().

String OW_NAMESPACE::PollingManager::getName  )  const [virtual]
 

Every service may have a name.

The name is used to calculate dependencies, other services can return the name from getDependencies(), to instruct the cimom about which order to start and shutdown all the services. The default is to have no name, in that case, no other service can depend on it.

Reimplemented from OW_NAMESPACE::ServiceIFC.

Definition at line 138 of file OW_PollingManager.cpp.

References OW_NAMESPACE::ServiceIFCNames::PollingManager.

void OW_NAMESPACE::PollingManager::init const ServiceEnvironmentIFCRef env  )  [virtual]
 

init() will be called to give the derived class an opportunity to initialize itself.

Do not create threads which interact with the environment until start() is called. During the loading/initializing phase, the environment is single-threaded.

Parameters:
env The service's interface to it's environment. A copy of this may be saved and re-used. All copies of env or objects obtained by calling member functions of env should be set to 0 in shutdown() to prevent circular reference counts.

Implements OW_NAMESPACE::ServiceIFC.

Definition at line 95 of file OW_PollingManager.cpp.

References env, and m_pollingManagerThread.

void OW_NAMESPACE::PollingManager::shutdown  )  [virtual]
 

The service must shutdown completely before returning from this function.

All copies of the service environment or objects obtained from it should be set to 0 to avoid circular reference counts.

Implements OW_NAMESPACE::ServiceIFC.

Definition at line 110 of file OW_PollingManager.cpp.

References m_pollingManagerThread.

void OW_NAMESPACE::PollingManager::start  )  [virtual]
 

In start(), a service should start doing whatever it does, such as starting a new thread or adding selectables to the environment.

A service can't rely on the order of initalization, so if it needs to communicate with another one, that works hould be done in started() start() should not return until the service is actually started, but it must return.

Reimplemented from OW_NAMESPACE::ServiceIFC.

Definition at line 102 of file OW_PollingManager.cpp.

References m_pollingManagerThread.


Member Data Documentation

IntrusiveReference<PollingManagerThread> OW_NAMESPACE::PollingManager::m_pollingManagerThread [private]
 

Definition at line 72 of file OW_PollingManager.hpp.

Referenced by addPolledProvider(), init(), shutdown(), and start().


The documentation for this class was generated from the following files:
Generated on Thu Feb 9 09:12:52 2006 for openwbem by  doxygen 1.4.6