org.apache.directory.server.core.jndi
Class ServerLdapContext
java.lang.Object
org.apache.directory.server.core.jndi.ServerContext
org.apache.directory.server.core.jndi.ServerDirContext
org.apache.directory.server.core.jndi.ServerLdapContext
- All Implemented Interfaces:
- javax.naming.Context, javax.naming.directory.DirContext, javax.naming.event.EventContext, javax.naming.event.EventDirContext, javax.naming.ldap.LdapContext
public class ServerLdapContext
- extends ServerDirContext
- implements javax.naming.ldap.LdapContext
An implementation of a JNDI LdapContext.
- Version:
- $Rev: 434579 $
- Author:
- Apache Directory Project
Fields inherited from interface javax.naming.ldap.LdapContext |
CONTROL_FACTORIES |
Fields inherited from interface javax.naming.directory.DirContext |
ADD_ATTRIBUTE, REMOVE_ATTRIBUTE, REPLACE_ATTRIBUTE |
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 |
Fields inherited from interface javax.naming.event.EventContext |
OBJECT_SCOPE, ONELEVEL_SCOPE, SUBTREE_SCOPE |
Method Summary |
boolean |
compare(org.apache.directory.shared.ldap.name.LdapDN name,
java.lang.String oid,
java.lang.Object value)
Explicitly exposes an LDAP compare operation which JNDI does not
directly provide. |
javax.naming.ldap.ExtendedResponse |
extendedOperation(javax.naming.ldap.ExtendedRequest request)
|
javax.naming.ldap.Control[] |
getConnectControls()
|
javax.naming.ldap.Control[] |
getRequestControls()
|
javax.naming.ldap.Control[] |
getResponseControls()
|
boolean |
isReferral(java.lang.String name)
|
void |
ldapUnbind()
Calling this method tunnels an unbind call down into the partition holding
the bindDn. |
javax.naming.ldap.LdapContext |
newInstance(javax.naming.ldap.Control[] requestControls)
|
void |
reconnect(javax.naming.ldap.Control[] connCtls)
|
void |
setRequestControls(javax.naming.ldap.Control[] requestControls)
|
Methods inherited from class org.apache.directory.server.core.jndi.ServerDirContext |
addNamingListener, addNamingListener, addNamingListener, addNamingListener, bind, bind, createSubcontext, createSubcontext, getAttributes, getAttributes, getAttributes, getAttributes, getSchema, getSchema, getSchemaClassDefinition, getSchemaClassDefinition, modifyAttributes, modifyAttributes, modifyAttributes, modifyAttributes, modifyAttributes, modifyAttributes, rebind, rebind, search, search, search, search, search, search, search, search, search |
Methods inherited from class org.apache.directory.server.core.jndi.ServerContext |
addNamingListener, addNamingListener, addToEnvironment, bind, bind, close, composeName, composeName, createSubcontext, createSubcontext, destroySubcontext, destroySubcontext, getDn, getEnvironment, getListeners, getNameInNamespace, getNameParser, getNameParser, getNexusProxy, getPrincipal, getService, list, list, listBindings, listBindings, lookup, lookup, lookupLink, lookupLink, rebind, rebind, removeFromEnvironment, removeNamingListener, rename, rename, setPrincipal, targetMustExist, unbind, unbind |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface javax.naming.directory.DirContext |
bind, bind, createSubcontext, createSubcontext, getAttributes, getAttributes, getAttributes, getAttributes, getSchema, getSchema, getSchemaClassDefinition, getSchemaClassDefinition, modifyAttributes, modifyAttributes, modifyAttributes, modifyAttributes, rebind, rebind, search, search, search, search, search, search, search, search |
Methods inherited from interface javax.naming.Context |
addToEnvironment, bind, bind, close, composeName, composeName, createSubcontext, createSubcontext, destroySubcontext, destroySubcontext, getEnvironment, getNameInNamespace, getNameParser, getNameParser, list, list, listBindings, listBindings, lookup, lookup, lookupLink, lookupLink, rebind, rebind, removeFromEnvironment, rename, rename, unbind, unbind |
Methods inherited from interface javax.naming.event.EventContext |
addNamingListener, addNamingListener, removeNamingListener, targetMustExist |
ServerLdapContext
public ServerLdapContext(DirectoryService service,
java.util.Hashtable env)
throws javax.naming.NamingException
- Creates an instance of an ServerLdapContext.
- Parameters:
service
- the parent service that manages this contextenv
- the JNDI environment parameters
- Throws:
javax.naming.NamingException
- the context cannot be created
extendedOperation
public javax.naming.ldap.ExtendedResponse extendedOperation(javax.naming.ldap.ExtendedRequest request)
- Specified by:
extendedOperation
in interface javax.naming.ldap.LdapContext
- See Also:
LdapContext.extendedOperation(
javax.naming.ldap.ExtendedRequest)
newInstance
public javax.naming.ldap.LdapContext newInstance(javax.naming.ldap.Control[] requestControls)
throws javax.naming.NamingException
- Specified by:
newInstance
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.newInstance(
javax.naming.ldap.Control[])
reconnect
public void reconnect(javax.naming.ldap.Control[] connCtls)
throws javax.naming.NamingException
- Specified by:
reconnect
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.reconnect(javax.naming.ldap.Control[])
getConnectControls
public javax.naming.ldap.Control[] getConnectControls()
throws javax.naming.NamingException
- Specified by:
getConnectControls
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.getConnectControls()
setRequestControls
public void setRequestControls(javax.naming.ldap.Control[] requestControls)
throws javax.naming.NamingException
- Specified by:
setRequestControls
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.setRequestControls(
javax.naming.ldap.Control[])
getRequestControls
public javax.naming.ldap.Control[] getRequestControls()
throws javax.naming.NamingException
- Specified by:
getRequestControls
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.getRequestControls()
getResponseControls
public javax.naming.ldap.Control[] getResponseControls()
throws javax.naming.NamingException
- Specified by:
getResponseControls
in interface javax.naming.ldap.LdapContext
- Throws:
javax.naming.NamingException
- See Also:
LdapContext.getResponseControls()
compare
public boolean compare(org.apache.directory.shared.ldap.name.LdapDN name,
java.lang.String oid,
java.lang.Object value)
throws javax.naming.NamingException
- Explicitly exposes an LDAP compare operation which JNDI does not
directly provide. All normalization and schema checking etcetera
is handled by this call.
- Parameters:
name
- the name of the entrioid
- the name or object identifier for the attribute to comparevalue
- the value to compare the attribute to
- Returns:
- true if the entry has the value for the attribute, false otherwise
- Throws:
javax.naming.NamingException
- if the backing store cannot be accessed, or
permission is not allowed for this operation or the oid is not recognized,
or the attribute is not present in the entry ... you get the picture.
ldapUnbind
public void ldapUnbind()
throws javax.naming.NamingException
- Calling this method tunnels an unbind call down into the partition holding
the bindDn. The bind() counter part is not exposed because it is automatically
called when you create a new initial context for a new connection (on wire) or
(programatic) caller.
- Throws:
javax.naming.NamingException
isReferral
public boolean isReferral(java.lang.String name)
throws javax.naming.NamingException
- Throws:
javax.naming.NamingException
Copyright © 2003-2010 Apache Software Foundation. All Rights Reserved.