|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.ldap.server.partition.DirectoryPartitionNexus
org.apache.ldap.server.partition.DirectoryPartitionNexusProxy
public class DirectoryPartitionNexusProxy
A decorator that wraps other DirectoryPartitionNexus
to enable
InterceptorChain
and InvocationStack
support.
All Invocation
s made to this nexus is automatically pushed to
InvocationStack
of the current thread, and popped when
the operation ends. All invocations are filtered by InterceptorChain
.
Field Summary | |
---|---|
static java.lang.String |
BYPASS_ALL
Bypass String to use when ALL interceptors should be skipped |
static java.util.Collection |
BYPASS_ALL_COLLECTION
Bypass String to use when ALL interceptors should be skipped |
static java.util.Collection |
GETMATCHEDDN_BYPASS
safe to use set of bypass instructions to getMatchedDn |
static java.util.Collection |
LOOKUP_BYPASS
safe to use set of bypass instructions to lookup raw entries |
Fields inherited from class org.apache.ldap.server.partition.DirectoryPartitionNexus |
---|
ADMIN_PASSWORD, ADMIN_PRINCIPAL, ADMIN_UID, GROUPS_BASE_NAME, SYSTEM_PARTITION_SUFFIX, USERS_BASE_NAME |
Fields inherited from interface org.apache.ldap.server.partition.DirectoryPartition |
---|
ALIAS_ATTRIBUTE, ALIAS_OBJECT |
Constructor Summary | |
---|---|
DirectoryPartitionNexusProxy(javax.naming.Context caller,
DirectoryService service)
Creates a new instance. |
Method Summary | |
---|---|
void |
add(java.lang.String upName,
javax.naming.Name normName,
javax.naming.directory.Attributes entry)
Adds an entry to this ContextPartition. |
void |
add(java.lang.String upName,
javax.naming.Name normName,
javax.naming.directory.Attributes entry,
java.util.Collection bypass)
|
void |
addContextPartition(DirectoryPartitionConfiguration config)
|
void |
addContextPartition(DirectoryPartitionConfiguration config,
java.util.Collection bypass)
|
void |
addNamingListener(javax.naming.event.EventContext ctx,
javax.naming.Name name,
org.apache.ldap.common.filter.ExprNode filter,
javax.naming.directory.SearchControls searchControls,
javax.naming.event.NamingListener namingListener)
|
void |
close()
|
boolean |
compare(javax.naming.Name name,
java.lang.String oid,
java.lang.Object value)
Performs a comparison check to see if an attribute of an entry has a specified value. |
boolean |
compare(javax.naming.Name name,
java.lang.String oid,
java.lang.Object value,
java.util.Collection bypass)
|
void |
delete(javax.naming.Name name)
Deletes a leaf entry from this ContextPartition: non-leaf entries cannot be deleted until this operation has been applied to their children. |
void |
delete(javax.naming.Name name,
java.util.Collection bypass)
|
void |
destroy()
Deinitialized this partition. |
javax.naming.ldap.LdapContext |
getLdapContext()
Gets the LdapContext associated with the calling thread. |
javax.naming.Name |
getMatchedName(javax.naming.Name dn,
boolean normalized)
Gets the most significant Dn that exists within the server for any Dn. |
javax.naming.Name |
getMatchedName(javax.naming.Name dn,
boolean normalized,
java.util.Collection bypass)
|
javax.naming.directory.Attributes |
getRootDSE()
Get's the RootDSE entry for the DSA. |
javax.naming.directory.Attributes |
getRootDSE(java.util.Collection bypass)
|
javax.naming.Name |
getSuffix(boolean normalized)
Gets the distinguished/absolute name of the suffix for all entries stored within this ContextPartition. |
javax.naming.Name |
getSuffix(javax.naming.Name dn,
boolean normalized)
Gets the distinguished name of the suffix that would hold an entry with the supplied distinguished name parameter. |
javax.naming.Name |
getSuffix(javax.naming.Name dn,
boolean normalized,
java.util.Collection bypass)
|
DirectoryPartition |
getSystemPartition()
|
boolean |
hasEntry(javax.naming.Name name)
Fast operation to check and see if a particular entry exists. |
boolean |
hasEntry(javax.naming.Name name,
java.util.Collection bypass)
|
void |
init(DirectoryServiceConfiguration factoryCfg,
DirectoryPartitionConfiguration cfg)
Initializes this partition. |
boolean |
isInitialized()
Checks to see if this partition is initialized or not. |
boolean |
isSuffix(javax.naming.Name name)
Checks to see if name is a context suffix. |
boolean |
isSuffix(javax.naming.Name name,
java.util.Collection bypass)
|
javax.naming.NamingEnumeration |
list(javax.naming.Name base)
A specialized form of one level search used to return a minimal set of information regarding child entries under a base. |
javax.naming.NamingEnumeration |
list(javax.naming.Name base,
java.util.Collection bypass)
|
java.util.Iterator |
listSuffixes(boolean normalized)
Gets an iteration over the Name suffixes of the Backends managed by this DirectoryPartitionNexus . |
java.util.Iterator |
listSuffixes(boolean normalized,
java.util.Collection bypass)
|
javax.naming.directory.Attributes |
lookup(javax.naming.Name name)
Looks up an entry by distinguished/absolute name. |
javax.naming.directory.Attributes |
lookup(javax.naming.Name name,
java.util.Collection bypass)
|
javax.naming.directory.Attributes |
lookup(javax.naming.Name dn,
java.lang.String[] attrIds)
Looks up an entry by distinguished/absolute name. |
javax.naming.directory.Attributes |
lookup(javax.naming.Name dn,
java.lang.String[] attrIds,
java.util.Collection bypass)
|
void |
modify(javax.naming.Name name,
int modOp,
javax.naming.directory.Attributes mods)
Modifies an entry by adding, removing or replacing a set of attributes. |
void |
modify(javax.naming.Name name,
int modOp,
javax.naming.directory.Attributes mods,
java.util.Collection bypass)
|
void |
modify(javax.naming.Name name,
javax.naming.directory.ModificationItem[] mods)
Modifies an entry by using a combination of adds, removes or replace operations using a set of ModificationItems. |
void |
modify(javax.naming.Name name,
javax.naming.directory.ModificationItem[] mods,
java.util.Collection bypass)
|
void |
modifyRn(javax.naming.Name name,
java.lang.String newRn,
boolean deleteOldRn)
Modifies an entry by changing its relative name. |
void |
modifyRn(javax.naming.Name name,
java.lang.String newRn,
boolean deleteOldRn,
java.util.Collection bypass)
|
void |
move(javax.naming.Name oriChildName,
javax.naming.Name newParentName)
Transplants a child entry, to a position in the namespace under a new parent entry. |
void |
move(javax.naming.Name oriChildName,
javax.naming.Name newParentName,
java.util.Collection bypass)
|
void |
move(javax.naming.Name oriChildName,
javax.naming.Name newParentName,
java.lang.String newRn,
boolean deleteOldRn)
Transplants a child entry, to a position in the namespace under a new parent entry and changes the RN of the child entry which can optionally have its old RN attributes removed. |
void |
move(javax.naming.Name oriChildName,
javax.naming.Name newParentName,
java.lang.String newRn,
boolean deleteOldRn,
java.util.Collection bypass)
|
void |
removeContextPartition(javax.naming.Name suffix)
|
void |
removeContextPartition(javax.naming.Name suffix,
java.util.Collection bypass)
|
void |
removeNamingListener(javax.naming.event.EventContext ctx,
javax.naming.event.NamingListener namingListener)
|
javax.naming.NamingEnumeration |
search(javax.naming.Name base,
java.util.Map env,
org.apache.ldap.common.filter.ExprNode filter,
javax.naming.directory.SearchControls searchCtls)
Conducts a search against this ContextPartition. |
javax.naming.NamingEnumeration |
search(javax.naming.Name base,
java.util.Map env,
org.apache.ldap.common.filter.ExprNode filter,
javax.naming.directory.SearchControls searchCtls,
java.util.Collection bypass)
|
void |
sync()
Flushes any changes made to this partition now. |
Methods inherited from class org.apache.ldap.server.partition.DirectoryPartitionNexus |
---|
getAdminName, getGroupsBaseName, getUsersBaseName |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.util.Collection LOOKUP_BYPASS
public static final java.util.Collection GETMATCHEDDN_BYPASS
public static final java.lang.String BYPASS_ALL
public static final java.util.Collection BYPASS_ALL_COLLECTION
Constructor Detail |
---|
public DirectoryPartitionNexusProxy(javax.naming.Context caller, DirectoryService service)
caller
- a JNDI Context
object that will call this proxyservice
- a JNDI serviceMethod Detail |
---|
public javax.naming.ldap.LdapContext getLdapContext()
DirectoryPartitionNexus
getLdapContext
in class DirectoryPartitionNexus
public void init(DirectoryServiceConfiguration factoryCfg, DirectoryPartitionConfiguration cfg)
DirectoryPartition
public void destroy()
DirectoryPartition
public DirectoryPartition getSystemPartition()
getSystemPartition
in class DirectoryPartitionNexus
public javax.naming.Name getSuffix(boolean normalized) throws javax.naming.NamingException
DirectoryPartition
normalized
- boolean value used to control the normalization of the
returned Name. If true the normalized Name is returned, otherwise the
original user provided Name without normalization is returned.
javax.naming.NamingException
public void sync() throws javax.naming.NamingException
DirectoryPartition
javax.naming.NamingException
public void close() throws javax.naming.NamingException
javax.naming.NamingException
public boolean isInitialized()
DirectoryPartition
public javax.naming.Name getMatchedName(javax.naming.Name dn, boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus
getMatchedName
in class DirectoryPartitionNexus
dn
- the normalized distinguished name to use for matching.normalized
- boolean if true cause the return of a normalized Dn,
if false it returns the original user provided distinguished name for
the matched portion of the Dn as it was provided on entry creation.
javax.naming.NamingException
- if there are any problemspublic javax.naming.Name getMatchedName(javax.naming.Name dn, boolean normalized, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.Name getSuffix(javax.naming.Name dn, boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus
getSuffix
in class DirectoryPartitionNexus
dn
- the normalized distinguished name to use for finding a suffix.normalized
- if true causes the return of a normalized Dn, but
if false it returns the original user provided distinguished name for
the suffix Dn as it was provided on suffix entry creation.
javax.naming.NamingException
- if there are any problemspublic javax.naming.Name getSuffix(javax.naming.Name dn, boolean normalized, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public java.util.Iterator listSuffixes(boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus
DirectoryPartitionNexus
.
listSuffixes
in class DirectoryPartitionNexus
normalized
- if true the returned Iterator contains normalized Dn
but, if false, it returns the original user provided distinguished names
in the Iterator.
javax.naming.NamingException
- if there are any problemspublic java.util.Iterator listSuffixes(boolean normalized, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public boolean compare(javax.naming.Name name, java.lang.String oid, java.lang.Object value) throws javax.naming.NamingException
DirectoryPartitionNexus
compare
in class DirectoryPartitionNexus
name
- the normalized name of the entryoid
- the attribute being comparedvalue
- the value the attribute is compared to
javax.naming.NamingException
- if there is a problem accessing the entry and its valuespublic boolean compare(javax.naming.Name name, java.lang.String oid, java.lang.Object value, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void delete(javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the entry to
delete from this ContextPartition.
javax.naming.NamingException
- if there are any problemspublic void delete(javax.naming.Name name, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void add(java.lang.String upName, javax.naming.Name normName, javax.naming.directory.Attributes entry) throws javax.naming.NamingException
DirectoryPartition
upName
- the user provided distinguished/absolute name of the entrynormName
- the normalized distinguished/absolute name of the entryentry
- the entry to add to this ContextPartition
javax.naming.NamingException
- if there are any problemspublic void add(java.lang.String upName, javax.naming.Name normName, javax.naming.directory.Attributes entry, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void modify(javax.naming.Name name, int modOp, javax.naming.directory.Attributes mods) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the entry to
modifymodOp
- the modification operation to perform on the entry which
is one of constants specified by the DirContext interface:
ADD_ATTRIBUTE, REMOVE_ATTRIBUTE, REPLACE_ATTRIBUTE
.mods
- the attributes and their values used to affect the
modification with.
javax.naming.NamingException
- if there are any problemsDirContext
,
DirContext.ADD_ATTRIBUTE
,
DirContext.REMOVE_ATTRIBUTE
,
DirContext.REPLACE_ATTRIBUTE
public void modify(javax.naming.Name name, int modOp, javax.naming.directory.Attributes mods, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void modify(javax.naming.Name name, javax.naming.directory.ModificationItem[] mods) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the entry to modifymods
- the ModificationItems used to affect the modification with
javax.naming.NamingException
- if there are any problemsModificationItem
public void modify(javax.naming.Name name, javax.naming.directory.ModificationItem[] mods, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.NamingEnumeration list(javax.naming.Name base) throws javax.naming.NamingException
DirectoryPartition
base
- the base distinguished/absolute name for the search/listing
SearchResult
javax.naming.NamingException
- if there are any problemspublic javax.naming.NamingEnumeration list(javax.naming.Name base, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.NamingEnumeration search(javax.naming.Name base, java.util.Map env, org.apache.ldap.common.filter.ExprNode filter, javax.naming.directory.SearchControls searchCtls) throws javax.naming.NamingException
DirectoryPartition
base
- the normalized distinguished/absolute name of the search baseenv
- the environment under which operation occursfilter
- the root node of the filter expression treesearchCtls
- the search controls
javax.naming.NamingException
- if there are any problemspublic javax.naming.NamingEnumeration search(javax.naming.Name base, java.util.Map env, org.apache.ldap.common.filter.ExprNode filter, javax.naming.directory.SearchControls searchCtls, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.directory.Attributes lookup(javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished name of the object to lookup
javax.naming.NamingException
- if there are any problemspublic javax.naming.directory.Attributes lookup(javax.naming.Name name, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.directory.Attributes lookup(javax.naming.Name dn, java.lang.String[] attrIds) throws javax.naming.NamingException
DirectoryPartition
dn
- the normalized distinguished name of the object to lookupattrIds
- the set of attributes to return
javax.naming.NamingException
- if there are any problemspublic javax.naming.directory.Attributes lookup(javax.naming.Name dn, java.lang.String[] attrIds, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public boolean hasEntry(javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the object to
check for existance
javax.naming.NamingException
- if there are any problemspublic boolean hasEntry(javax.naming.Name name, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public boolean isSuffix(javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the context
javax.naming.NamingException
- if there are any problemspublic boolean isSuffix(javax.naming.Name name, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void modifyRn(javax.naming.Name name, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
DirectoryPartition
name
- the normalized distinguished/absolute name of the entry to
modify the RN of.newRn
- the new RN of the entry specified by namedeleteOldRn
- boolean flag which removes the old RN attribute
from the entry if set to true, and has no affect if set to false
javax.naming.NamingException
- if there are any problemspublic void modifyRn(javax.naming.Name name, java.lang.String newRn, boolean deleteOldRn, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void move(javax.naming.Name oriChildName, javax.naming.Name newParentName) throws javax.naming.NamingException
DirectoryPartition
oriChildName
- the normalized distinguished/absolute name of the
original child name representing the child entry to movenewParentName
- the normalized distinguished/absolute name of the
new parent to move the target entry to
javax.naming.NamingException
- if there are any problemspublic void move(javax.naming.Name oriChildName, javax.naming.Name newParentName, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void move(javax.naming.Name oriChildName, javax.naming.Name newParentName, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
DirectoryPartition
oriChildName
- the normalized distinguished/absolute name of the
original child name representing the child entry to movenewParentName
- the normalized distinguished/absolute name of the
new parent to move the targeted entry tonewRn
- the new RN of the entrydeleteOldRn
- boolean flag which removes the old RN attribute
from the entry if set to true, and has no affect if set to false
javax.naming.NamingException
- if there are any problemspublic void move(javax.naming.Name oriChildName, javax.naming.Name newParentName, java.lang.String newRn, boolean deleteOldRn, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public javax.naming.directory.Attributes getRootDSE() throws javax.naming.NamingException
DirectoryPartitionNexus
getRootDSE
in class DirectoryPartitionNexus
javax.naming.NamingException
public javax.naming.directory.Attributes getRootDSE(java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void addContextPartition(DirectoryPartitionConfiguration config) throws javax.naming.NamingException
addContextPartition
in class DirectoryPartitionNexus
javax.naming.NamingException
public void addContextPartition(DirectoryPartitionConfiguration config, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void removeContextPartition(javax.naming.Name suffix) throws javax.naming.NamingException
removeContextPartition
in class DirectoryPartitionNexus
javax.naming.NamingException
public void removeContextPartition(javax.naming.Name suffix, java.util.Collection bypass) throws javax.naming.NamingException
javax.naming.NamingException
public void addNamingListener(javax.naming.event.EventContext ctx, javax.naming.Name name, org.apache.ldap.common.filter.ExprNode filter, javax.naming.directory.SearchControls searchControls, javax.naming.event.NamingListener namingListener) throws javax.naming.NamingException
javax.naming.NamingException
public void removeNamingListener(javax.naming.event.EventContext ctx, javax.naming.event.NamingListener namingListener) throws javax.naming.NamingException
javax.naming.NamingException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |