public abstract class

AtomicContext

extends ComponentContext
java.lang.Object
   ↳ com.sun.jndi.toolkit.ctx.PartialCompositeContext
     ↳ com.sun.jndi.toolkit.ctx.ComponentContext
       ↳ com.sun.jndi.toolkit.ctx.AtomicContext
Known Direct Subclasses
Known Indirect Subclasses

Class Overview

Clients: deal only with names for its own naming service and deals with single contexts that can be built up into hierarchical naming systems. Direct subclasses of AtomicContext must provide implementations for the abstract a_ Context methods, and c_parseComponent(). If the subclass implements the notion of implicit nns, it must override the a_*_nns Context methods as well.

Summary

[Expand]
Inherited Constants
From class com.sun.jndi.toolkit.ctx.ComponentContext
From class com.sun.jndi.toolkit.ctx.PartialCompositeContext
From interface javax.naming.Context
[Expand]
Inherited Fields
From class com.sun.jndi.toolkit.ctx.PartialCompositeContext
Protected Constructors
AtomicContext()
Protected Methods
abstract void a_bind(String name, Object obj, Continuation cont)
void a_bind_nns(String name, Object obj, Continuation cont)
abstract Context a_createSubcontext(String name, Continuation cont)
Context a_createSubcontext_nns(String name, Continuation cont)
abstract void a_destroySubcontext(String name, Continuation cont)
void a_destroySubcontext_nns(String name, Continuation cont)
abstract NameParser a_getNameParser(Continuation cont)
NameParser a_getNameParser_nns(Continuation cont)
abstract NamingEnumeration a_list(Continuation cont)
abstract NamingEnumeration a_listBindings(Continuation cont)
NamingEnumeration a_listBindings_nns(Continuation cont)
NamingEnumeration a_list_nns(Continuation cont)
abstract Object a_lookup(String name, Continuation cont)
abstract Object a_lookupLink(String name, Continuation cont)
Object a_lookupLink_nns(String name, Continuation cont)
Object a_lookup_nns(String name, Continuation cont)
void a_processJunction_nns(Continuation cont)
This function is used when implementing a naming system that supports junctions.
void a_processJunction_nns(String name, Continuation cont)
This function is used when implementing a naming system that supports junctions.
abstract void a_rebind(String name, Object obj, Continuation cont)
void a_rebind_nns(String name, Object obj, Continuation cont)
abstract void a_rename(String oldname, Name newname, Continuation cont)
void a_rename_nns(String oldname, Name newname, Continuation cont)
Object a_resolveIntermediate_nns(String name, Continuation cont)
Resolves the nns for 'name' when the named context is acting as an intermediate context.
abstract void a_unbind(String name, Continuation cont)
void a_unbind_nns(String name, Continuation cont)
void c_bind(Name name, Object obj, Continuation cont)
void c_bind_nns(Name name, Object obj, Continuation cont)
Context c_createSubcontext(Name name, Continuation cont)
Context c_createSubcontext_nns(Name name, Continuation cont)
void c_destroySubcontext(Name name, Continuation cont)
void c_destroySubcontext_nns(Name name, Continuation cont)
NameParser c_getNameParser(Name name, Continuation cont)
NameParser c_getNameParser_nns(Name name, Continuation cont)
NamingEnumeration c_list(Name name, Continuation cont)
NamingEnumeration c_listBindings(Name name, Continuation cont)
NamingEnumeration c_listBindings_nns(Name name, Continuation cont)
NamingEnumeration c_list_nns(Name name, Continuation cont)
Object c_lookup(Name name, Continuation cont)
Object c_lookupLink(Name name, Continuation cont)
Object c_lookupLink_nns(Name name, Continuation cont)
Object c_lookup_nns(Name name, Continuation cont)
abstract StringHeadTail c_parseComponent(String inputName, Continuation cont)
Parse 'inputName' into two parts: head: the first component in this name tail: the rest of the unused name.
void c_rebind(Name name, Object obj, Continuation cont)
void c_rebind_nns(Name name, Object obj, Continuation cont)
void c_rename(Name oldname, Name newname, Continuation cont)
void c_rename_nns(Name oldname, Name newname, Continuation cont)
Object c_resolveIntermediate_nns(Name name, Continuation cont)
Resolves the nns for 'name' when the named context is acting as an intermediate context.
void c_unbind(Name name, Continuation cont)
void c_unbind_nns(Name name, Continuation cont)
boolean isEmpty(String name)
boolean resolve_to_context(Name name, Continuation cont)
Resolve to context named by 'name'.
void resolve_to_nns_and_continue(Name name, Continuation cont)
Resolves to nns associated with 'name' and set Continuation to the result.
boolean resolve_to_penultimate_context(Name name, Continuation cont)
Resolves to penultimate context named by 'name'.
boolean resolve_to_penultimate_context_nns(Name name, Continuation cont)
This function is similar to resolve_to_penultimate_context() except it should only be called by the nns() functions.
[Expand]
Inherited Methods
From class com.sun.jndi.toolkit.ctx.ComponentContext
From class com.sun.jndi.toolkit.ctx.PartialCompositeContext
From class java.lang.Object
From interface javax.naming.Context
From interface javax.naming.spi.Resolver

Protected Constructors

protected AtomicContext ()

Protected Methods

protected abstract void a_bind (String name, Object obj, Continuation cont)

protected void a_bind_nns (String name, Object obj, Continuation cont)

protected abstract Context a_createSubcontext (String name, Continuation cont)

protected Context a_createSubcontext_nns (String name, Continuation cont)

protected abstract void a_destroySubcontext (String name, Continuation cont)

protected void a_destroySubcontext_nns (String name, Continuation cont)

protected abstract NameParser a_getNameParser (Continuation cont)

protected NameParser a_getNameParser_nns (Continuation cont)

protected abstract NamingEnumeration a_list (Continuation cont)

protected abstract NamingEnumeration a_listBindings (Continuation cont)

protected NamingEnumeration a_listBindings_nns (Continuation cont)

protected NamingEnumeration a_list_nns (Continuation cont)

protected abstract Object a_lookup (String name, Continuation cont)

protected abstract Object a_lookupLink (String name, Continuation cont)

protected Object a_lookupLink_nns (String name, Continuation cont)

protected Object a_lookup_nns (String name, Continuation cont)

protected void a_processJunction_nns (Continuation cont)

This function is used when implementing a naming system that supports junctions. For example, when the a_list_nns(newobj) method is invoked, that means the caller is attempting to list the the nns context of of this context. For a context that supports junctions, it by default does not have any nns. Consequently, a NameNotFoundException is thrown.

protected void a_processJunction_nns (String name, Continuation cont)

This function is used when implementing a naming system that supports junctions. For example, when the a_bind_nns(name, newobj) method is invoked, that means the caller is attempting to bind the object 'newobj' to the nns of 'name'. For context that supports junctions, 'name' names a junction and is pointing to the root of another naming system, which in turn might have an nns. This means that a_bind_nns() should first resolve 'name' and attempt to continue the operation in the context named by 'name'. (i.e. bind to the nns of the context named by 'name'). If name is already empty, then throw NameNotFoundException because this context by default does not have any nns.

protected abstract void a_rebind (String name, Object obj, Continuation cont)

protected void a_rebind_nns (String name, Object obj, Continuation cont)

protected abstract void a_rename (String oldname, Name newname, Continuation cont)

protected void a_rename_nns (String oldname, Name newname, Continuation cont)

protected Object a_resolveIntermediate_nns (String name, Continuation cont)

Resolves the nns for 'name' when the named context is acting as an intermediate context. For a system that supports junctions, this would be equilvalent to a_lookup(name, cont); because for junctions, an intermediate slash simply signifies a syntactic separator. For a system that supports implicit nns, this would be equivalent to a_lookup_nns(name, cont); because for implicit nns, a slash always signifies the implicit nns, regardless of whether it is intermediate or trailing. By default this method supports junctions, and also allows for an implicit nns to be dynamically determined through the use of the "nns" reference (see a_processJunction_nns()). Contexts that implement implicit nns directly should provide an appropriate override.

protected abstract void a_unbind (String name, Continuation cont)

protected void a_unbind_nns (String name, Continuation cont)

protected void c_bind (Name name, Object obj, Continuation cont)

protected void c_bind_nns (Name name, Object obj, Continuation cont)

protected Context c_createSubcontext (Name name, Continuation cont)

protected Context c_createSubcontext_nns (Name name, Continuation cont)

protected void c_destroySubcontext (Name name, Continuation cont)

protected void c_destroySubcontext_nns (Name name, Continuation cont)

protected NameParser c_getNameParser (Name name, Continuation cont)

protected NameParser c_getNameParser_nns (Name name, Continuation cont)

protected NamingEnumeration c_list (Name name, Continuation cont)

protected NamingEnumeration c_listBindings (Name name, Continuation cont)

protected NamingEnumeration c_listBindings_nns (Name name, Continuation cont)

protected NamingEnumeration c_list_nns (Name name, Continuation cont)

protected Object c_lookup (Name name, Continuation cont)

protected Object c_lookupLink (Name name, Continuation cont)

protected Object c_lookupLink_nns (Name name, Continuation cont)

protected Object c_lookup_nns (Name name, Continuation cont)

protected abstract StringHeadTail c_parseComponent (String inputName, Continuation cont)

Parse 'inputName' into two parts: head: the first component in this name tail: the rest of the unused name. Subclasses should provide an implementation for this method which parses inputName using its own name syntax.

protected void c_rebind (Name name, Object obj, Continuation cont)

protected void c_rebind_nns (Name name, Object obj, Continuation cont)

protected void c_rename (Name oldname, Name newname, Continuation cont)

protected void c_rename_nns (Name oldname, Name newname, Continuation cont)

protected Object c_resolveIntermediate_nns (Name name, Continuation cont)

Resolves the nns for 'name' when the named context is acting as an intermediate context. For a system that supports only junctions, this would be equilvalent to c_lookup(name, cont); because for junctions, an intermediate slash simply signifies a syntactic separator. For a system that supports only implicit nns, this would be equivalent to c_lookup_nns(name, cont); because for implicit nns, a slash always signifies the implicit nns, regardless of whether it is intermediate or trailing. By default this method supports junctions, and also allows for an implicit nns to be dynamically determined through the use of the "nns" reference (see c_processJunction_nns()). Contexts that implement implicit nns directly should provide an appropriate override. A junction, by definition, is a binding of a name in one namespace to an object in another. The default implementation of this method detects the crossover into another namespace using the following heuristic: there is a junction when "name" resolves to a context that is not an instance of this.getClass(). Contexts supporting junctions for which this heuristic is inappropriate should override this method.

protected void c_unbind (Name name, Continuation cont)

protected void c_unbind_nns (Name name, Continuation cont)

protected boolean isEmpty (String name)

protected boolean resolve_to_context (Name name, Continuation cont)

Resolve to context named by 'name'. Returns true if at named context (i.e. 'name' is empty name). Returns false otherwise, and sets Continuation on parts of 'name' not yet resolved.

protected void resolve_to_nns_and_continue (Name name, Continuation cont)

Resolves to nns associated with 'name' and set Continuation to the result.

protected boolean resolve_to_penultimate_context (Name name, Continuation cont)

Resolves to penultimate context named by 'name'. Returns true if penultimate context has been reached (i.e. name only has one atomic component left). Returns false otherwise, and sets Continuation to parts of name not yet resolved.

protected boolean resolve_to_penultimate_context_nns (Name name, Continuation cont)

This function is similar to resolve_to_penultimate_context() except it should only be called by the nns() functions. This function fixes any exception or continuations so that it will have the proper nns name.