|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface Interceptor
Filters invocations on DirectoryPartitionNexus
. Interceptor
filters most method calls performed on DirectoryPartitionNexus
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,
java.lang.String userProvidedName,
javax.naming.Name normalizedName,
javax.naming.directory.Attributes entry)
Filters DirectoryPartition.add(String, Name, Attributes) call. |
void |
addContextPartition(NextInterceptor next,
DirectoryPartitionConfiguration cfg)
Filters DirectoryPartitionNexus.addContextPartition(DirectoryPartitionConfiguration) call. |
boolean |
compare(NextInterceptor next,
javax.naming.Name name,
java.lang.String oid,
java.lang.Object value)
Filters DirectoryPartitionNexus.compare(Name,String,Object) call. |
void |
delete(NextInterceptor next,
javax.naming.Name name)
Filters DirectoryPartition.delete(Name) call. |
void |
destroy()
Deinitializes this interceptor. |
javax.naming.Name |
getMatchedName(NextInterceptor next,
javax.naming.Name name,
boolean normalized)
Filters DirectoryPartitionNexus.getMatchedName(Name, boolean) call. |
javax.naming.directory.Attributes |
getRootDSE(NextInterceptor next)
Filters DirectoryPartitionNexus.getRootDSE() call. |
javax.naming.Name |
getSuffix(NextInterceptor next,
javax.naming.Name name,
boolean normalized)
Filters DirectoryPartitionNexus.getSuffix(Name, boolean) call. |
boolean |
hasEntry(NextInterceptor next,
javax.naming.Name name)
Filters DirectoryPartition.lookup(Name, String[]) call. |
void |
init(DirectoryServiceConfiguration factoryCfg,
InterceptorConfiguration cfg)
Intializes this interceptor. |
boolean |
isSuffix(NextInterceptor next,
javax.naming.Name name)
Filters DirectoryPartition.isSuffix(Name) call. |
javax.naming.NamingEnumeration |
list(NextInterceptor next,
javax.naming.Name baseName)
Filters DirectoryPartition.list(Name) call. |
java.util.Iterator |
listSuffixes(NextInterceptor next,
boolean normalized)
Filters DirectoryPartitionNexus.listSuffixes(boolean) call. |
javax.naming.directory.Attributes |
lookup(NextInterceptor next,
javax.naming.Name name)
Filters DirectoryPartition.lookup(Name) call. |
javax.naming.directory.Attributes |
lookup(NextInterceptor next,
javax.naming.Name dn,
java.lang.String[] attrIds)
Filters DirectoryPartition.lookup(Name, String[]) call. |
void |
modify(NextInterceptor next,
javax.naming.Name name,
int modOp,
javax.naming.directory.Attributes attributes)
Filters DirectoryPartition.modify(Name, int, Attributes) call. |
void |
modify(NextInterceptor next,
javax.naming.Name name,
javax.naming.directory.ModificationItem[] items)
Filters DirectoryPartition.modify(Name, ModificationItem[]) call. |
void |
modifyRn(NextInterceptor next,
javax.naming.Name name,
java.lang.String newRn,
boolean deleteOldRn)
Filters DirectoryPartition.modifyRn(Name, String, boolean) call. |
void |
move(NextInterceptor next,
javax.naming.Name oldName,
javax.naming.Name newParentName)
Filters DirectoryPartition.move(Name, Name) call. |
void |
move(NextInterceptor next,
javax.naming.Name oldName,
javax.naming.Name newParentName,
java.lang.String newRn,
boolean deleteOldRn)
Filters DirectoryPartition.move(Name, Name, String, boolean) call. |
void |
removeContextPartition(NextInterceptor next,
javax.naming.Name suffix)
Filters DirectoryPartitionNexus.removeContextPartition(Name) call. |
javax.naming.NamingEnumeration |
search(NextInterceptor next,
javax.naming.Name baseName,
java.util.Map environment,
org.apache.ldap.common.filter.ExprNode filter,
javax.naming.directory.SearchControls searchControls)
Filters DirectoryPartition.search(Name, Map, ExprNode, SearchControls) call. |
Method Detail |
---|
void init(DirectoryServiceConfiguration factoryCfg, InterceptorConfiguration cfg) throws javax.naming.NamingException
InterceptorChain
when this intercepter is loaded into interceptor chain.
javax.naming.NamingException
void destroy()
InterceptorChain
when this intercepter is unloaded from interceptor chain.
javax.naming.directory.Attributes getRootDSE(NextInterceptor next) throws javax.naming.NamingException
DirectoryPartitionNexus.getRootDSE()
call.
javax.naming.NamingException
javax.naming.Name getMatchedName(NextInterceptor next, javax.naming.Name name, boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus.getMatchedName(Name, boolean)
call.
javax.naming.NamingException
javax.naming.Name getSuffix(NextInterceptor next, javax.naming.Name name, boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus.getSuffix(Name, boolean)
call.
javax.naming.NamingException
java.util.Iterator listSuffixes(NextInterceptor next, boolean normalized) throws javax.naming.NamingException
DirectoryPartitionNexus.listSuffixes(boolean)
call.
javax.naming.NamingException
void addContextPartition(NextInterceptor next, DirectoryPartitionConfiguration cfg) throws javax.naming.NamingException
DirectoryPartitionNexus.addContextPartition(DirectoryPartitionConfiguration)
call.
javax.naming.NamingException
void removeContextPartition(NextInterceptor next, javax.naming.Name suffix) throws javax.naming.NamingException
DirectoryPartitionNexus.removeContextPartition(Name)
call.
javax.naming.NamingException
boolean compare(NextInterceptor next, javax.naming.Name name, java.lang.String oid, java.lang.Object value) throws javax.naming.NamingException
DirectoryPartitionNexus.compare(Name,String,Object)
call.
javax.naming.NamingException
void delete(NextInterceptor next, javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition.delete(Name)
call.
javax.naming.NamingException
void add(NextInterceptor next, java.lang.String userProvidedName, javax.naming.Name normalizedName, javax.naming.directory.Attributes entry) throws javax.naming.NamingException
DirectoryPartition.add(String, Name, Attributes)
call.
javax.naming.NamingException
void modify(NextInterceptor next, javax.naming.Name name, int modOp, javax.naming.directory.Attributes attributes) throws javax.naming.NamingException
DirectoryPartition.modify(Name, int, Attributes)
call.
javax.naming.NamingException
void modify(NextInterceptor next, javax.naming.Name name, javax.naming.directory.ModificationItem[] items) throws javax.naming.NamingException
DirectoryPartition.modify(Name, ModificationItem[])
call.
javax.naming.NamingException
javax.naming.NamingEnumeration list(NextInterceptor next, javax.naming.Name baseName) throws javax.naming.NamingException
DirectoryPartition.list(Name)
call.
javax.naming.NamingException
javax.naming.NamingEnumeration search(NextInterceptor next, javax.naming.Name baseName, java.util.Map environment, org.apache.ldap.common.filter.ExprNode filter, javax.naming.directory.SearchControls searchControls) throws javax.naming.NamingException
DirectoryPartition.search(Name, Map, ExprNode, SearchControls)
call.
javax.naming.NamingException
javax.naming.directory.Attributes lookup(NextInterceptor next, javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition.lookup(Name)
call.
javax.naming.NamingException
javax.naming.directory.Attributes lookup(NextInterceptor next, javax.naming.Name dn, java.lang.String[] attrIds) throws javax.naming.NamingException
DirectoryPartition.lookup(Name, String[])
call.
javax.naming.NamingException
boolean hasEntry(NextInterceptor next, javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition.lookup(Name, String[])
call.
javax.naming.NamingException
boolean isSuffix(NextInterceptor next, javax.naming.Name name) throws javax.naming.NamingException
DirectoryPartition.isSuffix(Name)
call.
javax.naming.NamingException
void modifyRn(NextInterceptor next, javax.naming.Name name, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
DirectoryPartition.modifyRn(Name, String, boolean)
call.
javax.naming.NamingException
void move(NextInterceptor next, javax.naming.Name oldName, javax.naming.Name newParentName) throws javax.naming.NamingException
DirectoryPartition.move(Name, Name)
call.
javax.naming.NamingException
void move(NextInterceptor next, javax.naming.Name oldName, javax.naming.Name newParentName, java.lang.String newRn, boolean deleteOldRn) throws javax.naming.NamingException
DirectoryPartition.move(Name, Name, String, boolean)
call.
javax.naming.NamingException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |