|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.tie.ext.DynamicInterceptorStack
public class DynamicInterceptorStack
A DynamicInterceptorStack
uses a list of InterceptorFactory
to
build the interceptor stack for each required endPoint.
Constructor Summary | |
---|---|
DynamicInterceptorStack()
|
Method Summary | ||
---|---|---|
void |
addFactory(InterceptorFactory factory)
Add a factory to the collection of factory to be consulted during a call to getInterceptors(Class, Object) . |
|
|
getInterceptors(Class<T> type,
T endPoint)
Consults the collection of InterceptorFactory instances to build an interception stack.The factories will be consulted in the order in which they are added
- the first factory added will be the first one consulted, and any interceptor it creates will be at the
top of the stack.A factory may return null if it does not have an interceptor to provide. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DynamicInterceptorStack()
Method Detail |
---|
public void addFactory(InterceptorFactory factory)
getInterceptors(Class, Object)
.
The factory collection follows the semantics of a List
. A factory may be safely added twice if it is to be
consulted twice during the execution of getInterceptors(Class, Object)
.
public <T> Iterable<MethodInterceptor> getInterceptors(Class<T> type, T endPoint)
InterceptorFactory
instances to build an interception stack.added
- the first factory added will be the first one consulted, and any interceptor it creates will be at the
top of the stack.
getInterceptors
in interface MethodInterceptorStack
type
- The java type (typically an interface) which declares the methods to be intercepted.endPoint
- The java object that provides an implementation of those methods.
endPoint
.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |