TAO_CosNotification
2.0.8
|
Implementation of ReconnectionRegistry. More...
#include <Reconnection_Registry.h>
Public Member Functions | |
Reconnection_Registry (Topology_Parent &parent) | |
Constructor. | |
virtual | ~Reconnection_Registry () |
Destructor. | |
::NotifyExt::ReconnectionRegistry::ReconnectionID | register_callback (::NotifyExt::ReconnectionCallback_ptr callback) |
Add a new callback to the registry. | |
void | unregister_callback (::NotifyExt::ReconnectionRegistry::ReconnectionID id) |
CORBA::Boolean | is_alive (void) |
virtual void | save_persistent (Topology_Saver &saver) |
virtual Topology_Object * | load_child (const ACE_CString &type, CORBA::Long id, const NVPList &attrs) |
Create a child of the appropriate type and return it. | |
void | send_reconnect (CosNotifyChannelAdmin::EventChannelFactory_ptr dest_factory) |
Private Types | |
typedef ACE_Hash_Map_Manager_Ex < NotifyExt::ReconnectionRegistry::ReconnectionID, ACE_CString, ACE_Hash < NotifyExt::ReconnectionRegistry::ReconnectionID > , ACE_Equal_To < NotifyExt::ReconnectionRegistry::ReconnectionID > , ACE_SYNCH_NULL_MUTEX > | Reconnection_Registry_Type |
The registry consists of a map from ReconnectionID to stringified IOR. | |
Private Member Functions | |
void | release (void) |
The release method is called when the refcount reaches 0. | |
Private Attributes | |
Reconnection_Registry_Type | reconnection_registry_ |
::NotifyExt::ReconnectionRegistry::ReconnectionID | highest_id_ |
Implementation of ReconnectionRegistry.
typedef ACE_Hash_Map_Manager_Ex<NotifyExt::ReconnectionRegistry::ReconnectionID, ACE_CString, ACE_Hash<NotifyExt::ReconnectionRegistry::ReconnectionID>, ACE_Equal_To<NotifyExt::ReconnectionRegistry::ReconnectionID>, ACE_SYNCH_NULL_MUTEX> TAO_Notify::Reconnection_Registry::Reconnection_Registry_Type [private] |
The registry consists of a map from ReconnectionID to stringified IOR.
TAO_Notify::Reconnection_Registry::Reconnection_Registry | ( | Topology_Parent & | parent | ) |
Constructor.
TAO_Notify::Reconnection_Registry::~Reconnection_Registry | ( | ) | [virtual] |
Destructor.
CORBA::Boolean TAO_Notify::Reconnection_Registry::is_alive | ( | void | ) |
Topology_Object * TAO_Notify::Reconnection_Registry::load_child | ( | const ACE_CString & | type, |
CORBA::Long | id, | ||
const NVPList & | attrs | ||
) | [virtual] |
Create a child of the appropriate type and return it.
Use "type" as passed in to determine what kind of child (supporting the Topology_Object interface) to create and return. Inform it of its new ID.
Reimplemented from TAO_Notify::Topology_Object.
NotifyExt::ReconnectionRegistry::ReconnectionID TAO_Notify::Reconnection_Registry::register_callback | ( | ::NotifyExt::ReconnectionCallback_ptr | callback | ) |
Add a new callback to the registry.
void TAO_Notify::Reconnection_Registry::release | ( | void | ) | [private, virtual] |
The release method is called when the refcount reaches 0.
Implements TAO_Notify_Refcountable.
void TAO_Notify::Reconnection_Registry::save_persistent | ( | Topology_Saver & | saver | ) | [virtual] |
Save our state to a Topology_Saver.
Use the methods of a Topology_Saver to store all information we want persisted. This function is called by our parent, which gives us a saver to use. In turn, we must call this function on all of our children. The implementation should look like: bool change = this->self_changed_; this->self_changed_ = false; this->children_changed_ = false; if (is_persistent ()) { bool want_all_children = saver.begin_object( this->id(), type, attrs, change); for all children { if (want_all_children || child.is_changed()) { child.save_persistent(saver); } } for all deleted children { saver.delete_child(child_type, child_id); } saver.end_object(this->id(), type); )
Implements TAO_Notify::Topology_Savable.
void TAO_Notify::Reconnection_Registry::send_reconnect | ( | CosNotifyChannelAdmin::EventChannelFactory_ptr | dest_factory | ) |
void TAO_Notify::Reconnection_Registry::unregister_callback | ( | ::NotifyExt::ReconnectionRegistry::ReconnectionID | id | ) |
::NotifyExt::ReconnectionRegistry::ReconnectionID TAO_Notify::Reconnection_Registry::highest_id_ [private] |