TAO_Persistent_Naming_Context Class ReferenceThis class plays a role of a 'ConcreteImplementor' in the Bridge pattern architecture of the CosNaming::NamingContext implementation. More...
Inheritance diagram for TAO_Persistent_Naming_Context:
Collaboration diagram for TAO_Persistent_Naming_Context:
Detailed DescriptionThis class plays a role of a 'ConcreteImplementor' in the Bridge pattern architecture of the CosNaming::NamingContext implementation.This class provides a persistent implementation of the NamingContext functionality, i.e., the state is preserved across process boundaries. Derives from TAO_Hash_Naming_Context and uses TAO_Persistent_Bindings_Map to store name to object bindings. Member Typedef DocumentationUnderlying data structure - typedef for ease of use.
Constructor & Destructor Documentation
Constructor. MUST be followed up by <init> to allocate the underlying data structure from persistent storage!
Constructor that takes in preallocated data structure and takes ownership of it. This constructor is for 'recreating' servants from persistent state.
Destructor.
Member Function Documentation
Allocate the underlying data structure from persistent storage. Returns 0 on success and -1 on failure.
This utility method factors out the code needed to create a new Persistent Naming Context servant and activate it under the specified POA with the specified id. This function is static so that the code can be used, both from inside the class (e.g., <new_context>), and from outside (e.g., Naming_Utils.cpp).
This operation returns a new naming context implemented by the same naming server in which the operation was invoked. The context is not bound. Implements TAO_Naming_Context_Impl.
Returns at most the requested number of bindings <how_many> in <bl>. If the naming context contains additional bindings, they are returned with a BindingIterator. In the naming context does not contain any additional bindings <bi> returned as null. Implements TAO_Naming_Context_Impl.
Set <destroyed_> flag (inherited from TAO_Hash_Naming_Context) to <level>. Legal values for <destroyed_> are 0, 1, and 2. The values specify the extent of cleanup that should take place in the context's destructor: '0' - no cleanup (e.g., if the context goes out of scope, but it's state is to remain in persistent storage); '1' - free up the underlying data structure in persistent storage (e.g., if the initialization of this context was only partially completed due to some failures, and we need to roll back); '2' - free up the underlying data structure, and deregister this naming context from its <index_> (e.g., if the context had <destroy> method invoked and needs to be completely removed from existence).
Member Data Documentation
Counter used for generation of POA ids for children Naming Contexts. A pointer to the underlying data structure used to store name bindings. While our superclass (TAO_Hash_Naming_Context) also maintains a pointer to the data structure, keeping this pointer around saves us from the need to downcast when invoking non-virtual methods. A pointer to the index object of this naming service: it keeps track of all the naming contexts created. Every time we make a new context or destroy one, we need to make an entry there. Also, we get the allocator needed to initialize us from this guy.
The documentation for this class was generated from the following files: Generated on Mon Sep 15 08:42:05 2008 for TAO_CosNaming by 1.5.5 |