|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.codehaus.spice.jndikit.AbstractContext
org.codehaus.spice.jndikit.AbstractURLContext
Abstract JNDI Context that can be inherited from to provide a particular type of Context.
Field Summary |
---|
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 | |
---|---|
AbstractURLContext(String scheme,
Hashtable environment)
|
Method Summary | |
---|---|
protected void |
bind(Name name,
Object object,
boolean rebind)
Helper method to bind |
Context |
createSubcontext(Name name)
Create a Subcontext. |
void |
destroySubcontext(Name name)
|
protected ResolveResult |
getBaseURLContext(Name name,
Hashtable environment)
|
protected int |
getEndIndexOfURLPart(String name,
int index)
Find end index of url part in string. |
String |
getNameInNamespace()
|
protected NameParser |
getNameParser()
|
NamingEnumeration |
list(Name name)
Enumerates the names bound in the named context. |
NamingEnumeration |
listBindings(Name name)
Enumerates the names bound in the named context, along with the objects bound to them. |
Object |
lookup(Name name)
Get the object named. |
protected abstract Context |
newContext(String urlPart)
Return a new instance of the base context for a URL. |
Name |
parse(String name)
|
void |
unbind(Name name)
Unbind a object from a name. |
Methods inherited from class org.codehaus.spice.jndikit.AbstractContext |
---|
addToEnvironment, bind, bind, close, 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 AbstractURLContext(String scheme, Hashtable environment)
Method Detail |
public Name parse(String name) throws NamingException
parse
in interface NameParser
NamingException
protected NameParser getNameParser() throws NamingException
getNameParser
in class AbstractContext
NamingException
protected void bind(Name name, Object object, boolean rebind) throws NamingException
bind
in class AbstractContext
NamingException
public Context createSubcontext(Name name) throws NamingException
createSubcontext
in interface Context
name
- the name of subcontext
NamingException
- if an error occurs (ie context
exists, badly formated name etc)public void destroySubcontext(Name name) throws NamingException
destroySubcontext
in interface Context
NamingException
public String getNameInNamespace() throws NamingException
getNameInNamespace
in interface Context
NamingException
public NamingEnumeration list(Name name) throws NamingException
list
in interface Context
name
- the name of the context
NamingException
- if an error occurspublic NamingEnumeration listBindings(Name name) throws NamingException
listBindings
in interface Context
name
- the name of the context
NamingException
- if an error occurspublic Object lookup(Name name) throws NamingException
lookup
in interface Context
name
- the name
NamingException
- if an error occurs (ie object
name is inavlid or unbound)public void unbind(Name name) throws NamingException
unbind
in interface Context
name
- the name
NamingException
- if an error occursprotected ResolveResult getBaseURLContext(Name name, Hashtable environment) throws NamingException
NamingException
protected int getEndIndexOfURLPart(String name, int index) throws NamingException
name
- the nameindex
- the index where "scheme:" ends
NamingException
- if an error occursprotected abstract Context newContext(String urlPart) throws NamingException
urlPart
- the part of url string not including "scheme:"
NamingException
- if an error occurs
|
||||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |