|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Filters invocations on PartitionNexus
. Interceptor
filters most method calls performed on PartitionNexus
just
like Servlet filters do.
NextInterceptor
. The flow control is returned when the next
interceptor's filter method returns. You can therefore implement pre-, post-,
around- invocation handler by how you place the statement. Otherwise, you
can transform the invocation into other(s).
public void delete( NextInterceptor nextInterceptor, Name name ) { System.out.println( "Starting invocation." ); nextInterceptor.delete( name ); }
public void delete( NextInterceptor nextInterceptor, Name name ) { nextInterceptor.delete( name ); System.out.println( "Invocation ended." ); }
public void delete( NextInterceptor nextInterceptor, Name name ) { long startTime = System.currentTimeMillis(); try { nextInterceptor.delete( name ); } finally { long endTime = System.currentTimeMillis(); System.out.println( ( endTime - startTime ) + "ms elapsed." ); } }
public void delete( NextInterceptor nextInterceptor, Name name ) { // transform deletion into modification. Attribute mark = new BasicAttribute( "entryDeleted", "true" ); nextInterceptor.modify( name, DirContext.REPLACE_ATTRIBUTE, mark ); }
NextInterceptor
Method Summary | |
void |
add(NextInterceptor next,
LdapDN name,
javax.naming.directory.Attributes entry)
Filters Partition#add(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.Attributes) call. |
void |
addContextPartition(NextInterceptor next,
PartitionConfiguration cfg)
Filters PartitionNexus.addContextPartition(PartitionConfiguration) call. |
void |
bind(NextInterceptor next,
LdapDN bindDn,
byte[] credentials,
java.util.List mechanisms,
java.lang.String saslAuthId)
Filters Partition#bind(org.apache.directory.shared.ldap.name.LdapDN,byte[],java.util.List,String) call. |
boolean |
compare(NextInterceptor next,
LdapDN name,
java.lang.String oid,
java.lang.Object value)
Filters PartitionNexus#compare(org.apache.directory.shared.ldap.name.LdapDN,String,Object) call. |
void |
delete(NextInterceptor next,
LdapDN name)
Filters Partition#delete(org.apache.directory.shared.ldap.name.LdapDN) call. |
void |
destroy()
Deinitializes this interceptor. |
LdapDN |
getMatchedName(NextInterceptor next,
LdapDN name)
Filters PartitionNexus#getMatchedName(org.apache.directory.shared.ldap.name.LdapDN) call. |
javax.naming.directory.Attributes |
getRootDSE(NextInterceptor next)
Filters PartitionNexus.getRootDSE() call. |
LdapDN |
getSuffix(NextInterceptor next,
LdapDN name)
Filters PartitionNexus#getSuffix(org.apache.directory.shared.ldap.name.LdapDN) call. |
boolean |
hasEntry(NextInterceptor next,
LdapDN name)
Filters Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call. |
void |
init(DirectoryServiceConfiguration factoryCfg,
InterceptorConfiguration cfg)
Intializes this interceptor. |
boolean |
isSuffix(NextInterceptor next,
LdapDN name)
Filters Partition#isSuffix(org.apache.directory.shared.ldap.name.LdapDN) call. |
javax.naming.NamingEnumeration |
list(NextInterceptor next,
LdapDN baseName)
Filters Partition#list(org.apache.directory.shared.ldap.name.LdapDN) call. |
java.util.Iterator |
listSuffixes(NextInterceptor next)
Filters PartitionNexus.listSuffixes() call. |
javax.naming.directory.Attributes |
lookup(NextInterceptor next,
LdapDN name)
Filters Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN) call. |
javax.naming.directory.Attributes |
lookup(NextInterceptor next,
LdapDN dn,
java.lang.String[] attrIds)
Filters Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN,String[]) call. |
void |
modify(NextInterceptor next,
LdapDN name,
int modOp,
javax.naming.directory.Attributes attributes)
Filters Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,int,javax.naming.directory.Attributes) call. |
void |
modify(NextInterceptor next,
LdapDN name,
javax.naming.directory.ModificationItem[] items)
Filters Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.ModificationItem[]) call. |
void |
modifyRn(NextInterceptor next,
LdapDN name,
java.lang.String newRn,
boolean deleteOldRn)
Filters Partition#modifyRn(org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call. |
void |
move(NextInterceptor next,
LdapDN oldName,
LdapDN newParentName)
Filters Partition#move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN) call. |
void |
move(NextInterceptor next,
LdapDN oldName,
LdapDN newParentName,
java.lang.String newRn,
boolean deleteOldRn)
Filters Partition#move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN,String,boolean) call. |
void |
removeContextPartition(NextInterceptor next,
LdapDN suffix)
Filters PartitionNexus#removeContextPartition(org.apache.directory.shared.ldap.name.LdapDN) call. |
javax.naming.NamingEnumeration |
search(NextInterceptor next,
LdapDN baseName,
java.util.Map environment,
ExprNode filter,
javax.naming.directory.SearchControls searchControls)
Filters Partition#search(org.apache.directory.shared.ldap.name.LdapDN,java.util.Map,org.apache.directory.shared.ldap.filter.ExprNode,javax.naming.directory.SearchControls) call. |
void |
unbind(NextInterceptor next,
LdapDN bindDn)
Filters Partition#unbind(org.apache.directory.shared.ldap.name.LdapDN) call. |
Method Detail |
public void init(DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg) throws javax.naming.NamingException
InterceptorChain
when this intercepter is loaded into interceptor chain.
javax.naming.NamingException
public void destroy()
InterceptorChain
when this intercepter is unloaded from interceptor chain.
public javax.naming.directory.Attributes getRootDSE(NextInterceptor next) throws javax.naming.NamingException
PartitionNexus.getRootDSE()
call.
javax.naming.NamingException
public LdapDN getMatchedName(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
PartitionNexus#getMatchedName(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public LdapDN getSuffix(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
PartitionNexus#getSuffix(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public java.util.Iterator listSuffixes(NextInterceptor next) throws javax.naming.NamingException
PartitionNexus.listSuffixes()
call.
javax.naming.NamingException
public void addContextPartition(NextInterceptor next, PartitionConfiguration cfg) throws javax.naming.NamingException
PartitionNexus.addContextPartition(PartitionConfiguration)
call.
javax.naming.NamingException
public void removeContextPartition(NextInterceptor next, LdapDN suffix) throws javax.naming.NamingException
PartitionNexus#removeContextPartition(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public boolean compare(NextInterceptor next, LdapDN name, java.lang.String oid, java.lang.Object value) throws javax.naming.NamingException
PartitionNexus#compare(org.apache.directory.shared.ldap.name.LdapDN,String,Object)
call.
javax.naming.NamingException
public void delete(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
Partition#delete(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public void add(NextInterceptor next, LdapDN name, javax.naming.directory.Attributes entry) throws javax.naming.NamingException
Partition#add(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.Attributes)
call.
javax.naming.NamingException
public void modify(NextInterceptor next, LdapDN name, int modOp, javax.naming.directory.Attributes attributes) throws javax.naming.NamingException
Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,int,javax.naming.directory.Attributes)
call.
javax.naming.NamingException
public void modify(NextInterceptor next, LdapDN name, javax.naming.directory.ModificationItem[] items) throws javax.naming.NamingException
Partition#modify(org.apache.directory.shared.ldap.name.LdapDN,javax.naming.directory.ModificationItem[])
call.
javax.naming.NamingException
public javax.naming.NamingEnumeration list(NextInterceptor next, LdapDN baseName) throws javax.naming.NamingException
Partition#list(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public javax.naming.NamingEnumeration search(NextInterceptor next, LdapDN baseName, java.util.Map environment, ExprNode filter, javax.naming.directory.SearchControls searchControls) throws javax.naming.NamingException
Partition#search(org.apache.directory.shared.ldap.name.LdapDN,java.util.Map,org.apache.directory.shared.ldap.filter.ExprNode,javax.naming.directory.SearchControls)
call.
javax.naming.NamingException
public javax.naming.directory.Attributes lookup(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public javax.naming.directory.Attributes lookup(NextInterceptor next, LdapDN dn, java.lang.String[] attrIds) throws javax.naming.NamingException
Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN,String[])
call.
javax.naming.NamingException
public boolean hasEntry(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
Partition#lookup(org.apache.directory.shared.ldap.name.LdapDN,String[])
call.
javax.naming.NamingException
public boolean isSuffix(NextInterceptor next, LdapDN name) throws javax.naming.NamingException
Partition#isSuffix(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public void modifyRn(NextInterceptor next, LdapDN name, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
Partition#modifyRn(org.apache.directory.shared.ldap.name.LdapDN,String,boolean)
call.
javax.naming.NamingException
public void move(NextInterceptor next, LdapDN oldName, LdapDN newParentName) throws javax.naming.NamingException
Partition#move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
public void move(NextInterceptor next, LdapDN oldName, LdapDN newParentName, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
Partition#move(org.apache.directory.shared.ldap.name.LdapDN,org.apache.directory.shared.ldap.name.LdapDN,String,boolean)
call.
javax.naming.NamingException
public void bind(NextInterceptor next, LdapDN bindDn, byte[] credentials, java.util.List mechanisms, java.lang.String saslAuthId) throws javax.naming.NamingException
Partition#bind(org.apache.directory.shared.ldap.name.LdapDN,byte[],java.util.List,String)
call.
javax.naming.NamingException
public void unbind(NextInterceptor next, LdapDN bindDn) throws javax.naming.NamingException
Partition#unbind(org.apache.directory.shared.ldap.name.LdapDN)
call.
javax.naming.NamingException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |