|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.avalon.excalibur.naming.AbstractContext | +--org.apache.avalon.excalibur.naming.AbstractLocalContext
Abstract local JNDI Context that can be inherited from to provide a particular type of Context. These contexts are assumed to be on the same machine.
Fields inherited from interface javax.naming.Context |
APPLET, AUTHORITATIVE, BATCHSIZE, DNS_URL, INITIAL_CONTEXT_FACTORY, LANGUAGE, OBJECT_FACTORIES, PROVIDER_URL, REFERRAL, SECURITY_AUTHENTICATION, SECURITY_CREDENTIALS, SECURITY_PRINCIPAL, SECURITY_PROTOCOL, STATE_FACTORIES, URL_PKG_PREFIXES |
Constructor Summary | |
AbstractLocalContext(Namespace namespace,
java.util.Hashtable environment,
javax.naming.Context parent)
|
Method Summary | |
protected void |
bind(javax.naming.Name name,
java.lang.Object object,
boolean rebind)
Helper method to bind |
protected void |
checkUnbindContext(javax.naming.Name name,
java.lang.Object entry)
|
protected abstract javax.naming.Context |
cloneContext()
|
void |
close()
Release resources associated with context. |
javax.naming.Context |
createSubcontext(javax.naming.Name name)
Create a Subcontext. |
void |
destroySubcontext(javax.naming.Name name)
|
protected abstract void |
doLocalBind(javax.naming.Name name,
java.lang.Object object)
|
protected abstract javax.naming.NamingEnumeration |
doLocalList()
|
protected abstract javax.naming.NamingEnumeration |
doLocalListBindings()
|
protected abstract java.lang.Object |
doLocalLookup(javax.naming.Name name)
Actually lookup raw entry in local context. |
protected abstract void |
doLocalUnbind(javax.naming.Name name)
Actually unbind raw entry in local context. |
java.lang.String |
getNameInNamespace()
|
protected javax.naming.NameParser |
getNameParser()
|
protected Namespace |
getNamespace()
Utility method to retrieve the Namespace. |
protected javax.naming.Context |
getParent()
Utility method to retrieve parent Context. |
protected boolean |
isDestroyableContext(java.lang.Object object)
|
javax.naming.NamingEnumeration |
list(javax.naming.Name name)
Enumerates the names bound in the named context. |
javax.naming.NamingEnumeration |
listBindings(javax.naming.Name name)
Enumerates the names bound in the named context, along with the objects bound to them. |
protected java.lang.Object |
localLookup(javax.naming.Name name)
Lookup entry in local context. |
java.lang.Object |
lookup(javax.naming.Name name)
Get the object named. |
protected javax.naming.Context |
lookupSubContext(javax.naming.Name name)
Lookup a sub-context of current context. |
protected abstract javax.naming.Context |
newContext()
|
void |
unbind(javax.naming.Name name)
Unbind a object from a name. |
Methods inherited from class org.apache.avalon.excalibur.naming.AbstractContext |
addToEnvironment, bind, bind, composeName, composeName, createSubcontext, destroySubcontext, getEnvironment, getLeafName, getNameParser, getNameParser, getPathName, getRawEnvironment, isSelf, list, listBindings, lookup, lookupLink, lookupLink, rebind, rebind, removeFromEnvironment, rename, rename, unbind |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AbstractLocalContext(Namespace namespace, java.util.Hashtable environment, javax.naming.Context parent)
Method Detail |
protected final javax.naming.Context getParent()
protected final Namespace getNamespace()
protected boolean isDestroyableContext(java.lang.Object object) throws javax.naming.NamingException
protected abstract javax.naming.Context newContext() throws javax.naming.NamingException
protected abstract javax.naming.Context cloneContext() throws javax.naming.NamingException
protected void bind(javax.naming.Name name, java.lang.Object object, boolean rebind) throws javax.naming.NamingException
bind
in class AbstractContext
protected abstract void doLocalBind(javax.naming.Name name, java.lang.Object object) throws javax.naming.NamingException
public void close()
AbstractContext
close
in class AbstractContext
public javax.naming.Context createSubcontext(javax.naming.Name name) throws javax.naming.NamingException
name
- the name of subcontextjavax.naming.NamingException
- if an error occurs (ie context exists, badly formated name etc)public void destroySubcontext(javax.naming.Name name) throws javax.naming.NamingException
protected void checkUnbindContext(javax.naming.Name name, java.lang.Object entry) throws javax.naming.NamingException
public java.lang.String getNameInNamespace() throws javax.naming.NamingException
protected javax.naming.NameParser getNameParser() throws javax.naming.NamingException
getNameParser
in class AbstractContext
public javax.naming.NamingEnumeration list(javax.naming.Name name) throws javax.naming.NamingException
name
- the name of the contextjavax.naming.NamingException
- if an error occursprotected abstract javax.naming.NamingEnumeration doLocalList() throws javax.naming.NamingException
protected abstract javax.naming.NamingEnumeration doLocalListBindings() throws javax.naming.NamingException
public javax.naming.NamingEnumeration listBindings(javax.naming.Name name) throws javax.naming.NamingException
name
- the name of the contextjavax.naming.NamingException
- if an error occurspublic java.lang.Object lookup(javax.naming.Name name) throws javax.naming.NamingException
name
- the namejavax.naming.NamingException
- if an error occurs (ie object name is inavlid or unbound)protected java.lang.Object localLookup(javax.naming.Name name) throws javax.naming.NamingException
name
- the name in local context (size() == 1)javax.naming.NamingException
- if an error occursprotected abstract java.lang.Object doLocalLookup(javax.naming.Name name) throws javax.naming.NamingException
name
- the name in local context (size() == 1)javax.naming.NamingException
- if an error occursprotected javax.naming.Context lookupSubContext(javax.naming.Name name) throws javax.naming.NamingException
name
- the name of subcontextjavax.naming.NamingException
- if an error occurs (like named entry is not a Context)public void unbind(javax.naming.Name name) throws javax.naming.NamingException
name
- the namejavax.naming.NamingException
- if an error occursprotected abstract void doLocalUnbind(javax.naming.Name name) throws javax.naming.NamingException
name
- the name in local context (size() == 1)javax.naming.NamingException
- if an error occurs
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |