Package org.apache.struts2.mock
Class MockInterceptor
java.lang.Object
org.apache.struts2.interceptor.AbstractInterceptor
org.apache.struts2.mock.MockInterceptor
- All Implemented Interfaces:
- Serializable,- ConditionalInterceptor,- Interceptor
Mock for an 
Interceptor.- Author:
- Jason Carreira
- See Also:
- 
Field SummaryFields
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionbooleangetFoo()inthashCode()intercept(ActionInvocation invocation) Allows the Interceptor to do some processing on the request before and/or after the rest of the processing of the request by the DefaultActionInvocation or to short-circuit the processing and just return a String return code.booleanvoidsetExpectedFoo(String expectedFoo) voidMethods inherited from class org.apache.struts2.interceptor.AbstractInterceptordestroy, init, setDisabled, shouldIntercept
- 
Field Details- 
DEFAULT_FOO_VALUE- See Also:
 
 
- 
- 
Constructor Details- 
MockInterceptorpublic MockInterceptor()
 
- 
- 
Method Details- 
isExecutedpublic boolean isExecuted()
- 
setExpectedFoo
- 
getExpectedFoo
- 
setFoo
- 
getFoo
- 
equals
- 
hashCodepublic int hashCode()
- 
interceptAllows the Interceptor to do some processing on the request before and/or after the rest of the processing of the request by the DefaultActionInvocation or to short-circuit the processing and just return a String return code.- Specified by:
- interceptin interface- Interceptor
- Specified by:
- interceptin class- AbstractInterceptor
- Parameters:
- invocation- the action invocation
- Returns:
- the return code, either returned from ActionInvocation.invoke(), or from the interceptor itself.
- Throws:
- Exception- any system-level error, as defined in- Action.execute().
 
 
-