TAO_CosNaming  2.1.9
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | List of all members
TAO_Naming_Context_Impl Class Referenceabstract

This abstract base class plays a role of the 'Implementor' in the Bridge pattern architecture of the NamingContext implementation. More...

#include <Naming_Context_Interface.h>

Inheritance diagram for TAO_Naming_Context_Impl:
Inheritance graph
Collaboration diagram for TAO_Naming_Context_Impl:
Collaboration graph

Public Member Functions

virtual ~TAO_Naming_Context_Impl (void)
 Destructor. More...
 
virtual void bind (const CosNaming::Name &n, CORBA::Object_ptr obj)=0
 
virtual void rebind (const CosNaming::Name &n, CORBA::Object_ptr obj)=0
 
virtual void bind_context (const CosNaming::Name &n, CosNaming::NamingContext_ptr nc)=0
 
virtual void rebind_context (const CosNaming::Name &n, CosNaming::NamingContext_ptr nc)=0
 
virtual CORBA::Object_ptr resolve (const CosNaming::Name &n)=0
 
virtual void unbind (const CosNaming::Name &n)=0
 
virtual
CosNaming::NamingContext_ptr 
new_context (void)=0
 
virtual
CosNaming::NamingContext_ptr 
bind_new_context (const CosNaming::Name &n)=0
 
virtual void destroy (void)=0
 
virtual void list (CORBA::ULong how_many, CosNaming::BindingList_out &bl, CosNaming::BindingIterator_out &bi)=0
 
virtual PortableServer::POA_ptr _default_POA (void)=0
 Returns the Default POA of this Servant object. More...
 
virtual void stale (bool value)
 
virtual bool stale (void)
 

Detailed Description

This abstract base class plays a role of the 'Implementor' in the Bridge pattern architecture of the NamingContext implementation.

Subclasses of TAO_Naming_Context_Impl provide concrete implementations of the NamingContext functionality.

Constructor & Destructor Documentation

TAO_Naming_Context_Impl::~TAO_Naming_Context_Impl ( void  )
virtual

Destructor.

Member Function Documentation

virtual PortableServer::POA_ptr TAO_Naming_Context_Impl::_default_POA ( void  )
pure virtual

Returns the Default POA of this Servant object.

Implemented in TAO_Hash_Naming_Context.

virtual void TAO_Naming_Context_Impl::bind ( const CosNaming::Name n,
CORBA::Object_ptr  obj 
)
pure virtual

Create a binding for name <n> and object <obj> in the naming context. Compound names are treated as follows: ctx->bind (<c1; c2; c3; cn>, obj) = (ctx->resolve (<c1; c2; cn-1>))->bind (<cn>, obj) if the there already exists a binding for the specified name, <AlreadyBound> exception is thrown. Naming contexts should be bound using <bind_context> and <rebind_context> in order to participate in name resolution later.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual void TAO_Naming_Context_Impl::bind_context ( const CosNaming::Name n,
CosNaming::NamingContext_ptr  nc 
)
pure virtual

This is the version of <bind> specifically for binding naming contexts, so that they will participate in name resolution when compound names are passed to be resolved.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual CosNaming::NamingContext_ptr TAO_Naming_Context_Impl::bind_new_context ( const CosNaming::Name n)
pure virtual

This operation creates a new context and binds it to the name supplied as an argument. The newly-created context is implemented by the same server as the context in which it was bound (the name argument excluding the last component).

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual void TAO_Naming_Context_Impl::destroy ( void  )
pure virtual

Delete the naming context. The user should take care to <unbind> any bindings in which the given context is bound to some names, to avoid dangling references when invoking <destroy> operation. NOTE: <destory> is a no-op on the root context. NOTE: after <destroy> is invoked on a Naming Context, all BindingIterators associated with that Naming Context are also destroyed.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual void TAO_Naming_Context_Impl::list ( CORBA::ULong  how_many,
CosNaming::BindingList_out &  bl,
CosNaming::BindingIterator_out &  bi 
)
pure virtual

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.

Implemented in TAO_Storable_Naming_Context, TAO_Persistent_Naming_Context, and TAO_Transient_Naming_Context.

virtual CosNaming::NamingContext_ptr TAO_Naming_Context_Impl::new_context ( void  )
pure virtual

This operation returns a new naming context implemented by the same naming server in which the operation was invoked. The context is not bound.

Implemented in TAO_Storable_Naming_Context, TAO_Persistent_Naming_Context, and TAO_Transient_Naming_Context.

virtual void TAO_Naming_Context_Impl::rebind ( const CosNaming::Name n,
CORBA::Object_ptr  obj 
)
pure virtual

This is similar to <bind> operation above, except for when the binding for the specified name already exists in the specified context. In that case, the existing binding is replaced with the new one.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual void TAO_Naming_Context_Impl::rebind_context ( const CosNaming::Name n,
CosNaming::NamingContext_ptr  nc 
)
pure virtual

This is a version of <rebind> specifically for naming contexts, so that they can participate in name resolution when compound names are passed.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

virtual CORBA::Object_ptr TAO_Naming_Context_Impl::resolve ( const CosNaming::Name n)
pure virtual

Return object reference that is bound to the name. Compound name resolve is defined as follows: ctx->resolve (<c1; c2; cn>) = ctx->resolve (<c1; c2 cn-1>)->resolve (<cn>) The naming service does not return the type of the object. Clients are responsible for "narrowing" the object to the appropriate type.

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.

void TAO_Naming_Context_Impl::stale ( bool  value)
virtual

Set the stale flag for replicated persistence support.

bool TAO_Naming_Context_Impl::stale ( void  )
virtual

Query if the the implementation is stale for replicated persistence support.

virtual void TAO_Naming_Context_Impl::unbind ( const CosNaming::Name n)
pure virtual

Remove the name binding from the context. When compound names are used, unbind is defined as follows: ctx->unbind (<c1; c2; cn>) = (ctx->resolve (<c1; c2; cn-1>))->unbind (<cn>)

Implemented in TAO_Storable_Naming_Context, and TAO_Hash_Naming_Context.


The documentation for this class was generated from the following files: