|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
ObjectInterceptorChain
public abstract class InterceptorChain
Abstract base class that represents an interceptor chain.
Constructor Summary | |
---|---|
protected |
InterceptorChain(InterceptorContext context,
List interceptors)
Create an interceptor chain with the InterceptorContext and a List of
interceptors. |
Method Summary | |
---|---|
Object |
continueChain()
Execute the next interceptor in the chain of interceptors. |
InterceptorContext |
getContext()
Get the InterceptorContext |
protected abstract Object |
invoke(Interceptor interceptor)
Invoke an interceptor. |
boolean |
isEmpty()
Check to see if the interception chain is empty. |
protected Interceptor |
removeFirst()
Remove the first Interceptor that is currently the first interceptor in the chain. |
Methods inherited from class Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
protected InterceptorChain(InterceptorContext context, List interceptors)
InterceptorContext
and a List
of
interceptors.
context
- the contextinterceptors
- the interceptorsMethod Detail |
---|
public Object continueChain() throws InterceptorException
InterceptorException
- the exception thrown if an error occurs while invoking the interceptorprotected abstract Object invoke(Interceptor interceptor) throws InterceptorException
interceptor
- the interceptor to invoke
InterceptorException
- the exception thrown if an error occurs while invoking the interceptorpublic InterceptorContext getContext()
InterceptorContext
public boolean isEmpty()
true
if the chain is empty; false
otherwise.protected Interceptor removeFirst()
Interceptor
that is currently the first interceptor in the chain.
This method can be used to advance to the "next" interceptor in the chain when executing
a chain of interceptors.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |