public abstract class AbstractFederatedContext extends AbstractContext
Modifier and Type | Field and Description |
---|---|
private ContextFederation |
contextFederation |
private AbstractFederatedContext |
masterContext |
Constructor and Description |
---|
AbstractFederatedContext() |
AbstractFederatedContext(AbstractFederatedContext masterContext,
java.lang.String nameInNamespace) |
AbstractFederatedContext(java.lang.String nameInNamespace) |
AbstractFederatedContext(java.lang.String nameInNamespace,
ContextAccess contextAccess) |
AbstractFederatedContext(java.lang.String nameInNamespace,
ContextAccess contextAccess,
java.util.Set<javax.naming.Context> federatedContexts) |
Modifier and Type | Method and Description |
---|---|
protected boolean |
addBinding(java.lang.String name,
java.lang.Object value,
boolean rebind) |
protected static void |
addFederatedContext(AbstractFederatedContext wrappingContext,
javax.naming.Context innerContext) |
protected java.lang.Object |
faultLookup(java.lang.String stringName,
javax.naming.Name parsedName)
When a value can not be found within this context, this method is called as a last ditch effort befrore
thowing a null pointer exception.
|
protected java.lang.Object |
getBinding(java.lang.String name)
Gets the object bound to the name.
|
protected java.util.Map<java.lang.String,java.lang.Object> |
getBindings()
Gets a map of the bindings for the current node (i.e., no names with slashes).
|
protected java.util.Map<java.lang.String,java.lang.Object> |
getBindings(java.lang.String name) |
protected java.lang.Object |
getDeepBinding(java.lang.String name)
Gets the object bound to the name.
|
protected AbstractFederatedContext |
getMasterContext() |
protected abstract java.util.Map<java.lang.String,java.lang.Object> |
getWrapperBindings() |
boolean |
isNestedSubcontext(java.lang.Object value)
Is the specified value an instance of a nested context
|
protected boolean |
removeBinding(java.lang.String name,
boolean removeNotEmptyContext)
Removes the binding from the context.
|
protected static void |
removeFederatedContext(AbstractFederatedContext wrappingContext,
javax.naming.Context innerContext) |
addBinding, addDeepBinding, addToEnvironment, bind, bind, close, composeName, composeName, createSubcontext, createSubcontext, createSubcontextTree, destroySubcontext, destroySubcontext, getContextAccess, getEnvironment, getNameInNamespace, getNameInNamespace, getNameInNamespace, getNameParser, getNameParser, getNameParser, getParsedNameInNamespace, getSize, isEmpty, list, list, list, listBindings, listBindings, listBindings, lookup, lookup, lookup, lookupFinalContext, lookupLink, lookupLink, rebind, rebind, removeDeepBinding, removeDeepBinding, removeFromEnvironment, rename, rename, unbind, unbind
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
createNestedSubcontext
private final ContextFederation contextFederation
private final AbstractFederatedContext masterContext
public AbstractFederatedContext()
public AbstractFederatedContext(java.lang.String nameInNamespace)
public AbstractFederatedContext(java.lang.String nameInNamespace, ContextAccess contextAccess)
public AbstractFederatedContext(java.lang.String nameInNamespace, ContextAccess contextAccess, java.util.Set<javax.naming.Context> federatedContexts)
public AbstractFederatedContext(AbstractFederatedContext masterContext, java.lang.String nameInNamespace) throws javax.naming.NamingException
javax.naming.NamingException
protected java.lang.Object faultLookup(java.lang.String stringName, javax.naming.Name parsedName)
AbstractContext
faultLookup
in class AbstractContext
stringName
- the string version of the name; will not be nullparsedName
- the parsed name; will not be nullprotected java.lang.Object getDeepBinding(java.lang.String name)
AbstractContext
getDeepBinding
in class AbstractContext
name
- the nameprotected java.lang.Object getBinding(java.lang.String name) throws javax.naming.NamingException
AbstractContext
getBinding
in class AbstractContext
name
- the namejavax.naming.NamingException
- on errorprotected final java.util.Map<java.lang.String,java.lang.Object> getBindings() throws javax.naming.NamingException
AbstractContext
getBindings
in class AbstractContext
javax.naming.NamingException
- if a problem occurs while getting the bindignsprotected final java.util.Map<java.lang.String,java.lang.Object> getBindings(java.lang.String name) throws javax.naming.NamingException
javax.naming.NamingException
protected abstract java.util.Map<java.lang.String,java.lang.Object> getWrapperBindings() throws javax.naming.NamingException
javax.naming.NamingException
protected boolean addBinding(java.lang.String name, java.lang.Object value, boolean rebind) throws javax.naming.NamingException
addBinding
in class AbstractContext
javax.naming.NamingException
protected boolean removeBinding(java.lang.String name, boolean removeNotEmptyContext) throws javax.naming.NamingException
AbstractContext
removeBinding
in class AbstractContext
name
- name under which the value should be boundremoveNotEmptyContext
- ??? TODO figure this outjavax.naming.NamingException
- if a problem occurs during the bind such as a value already being boundprotected static void addFederatedContext(AbstractFederatedContext wrappingContext, javax.naming.Context innerContext) throws javax.naming.NamingException
javax.naming.NamingException
protected static void removeFederatedContext(AbstractFederatedContext wrappingContext, javax.naming.Context innerContext) throws javax.naming.NamingException
javax.naming.NamingException
public boolean isNestedSubcontext(java.lang.Object value)
NestedContextFactory
value
- the value to inspectprotected AbstractFederatedContext getMasterContext()