Package org.grails.web.servlet.mvc
Class AbstractTokenResponseHandler
- java.lang.Object
-
- org.grails.web.servlet.mvc.AbstractTokenResponseHandler
-
- All Implemented Interfaces:
TokenResponseHandler
public abstract class AbstractTokenResponseHandler extends java.lang.Object implements TokenResponseHandler
Implements the behavior of wasInvoked in the TokenResponseHandler interface.- Since:
- 1.1
- See Also:
TokenResponseHandler.wasInvoked()
-
-
Field Summary
-
Fields inherited from interface org.grails.web.servlet.mvc.TokenResponseHandler
INVALID_TOKEN_ATTRIBUTE, KEY
-
-
Constructor Summary
Constructors Constructor Description AbstractTokenResponseHandler(boolean valid)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.lang.ObjectinvalidToken(groovy.lang.Closure callable)Specify behavior in the event of an invalid token.protected abstract java.lang.ObjectinvalidTokenInternal(groovy.lang.Closure callable)booleanwasInvalidToken()Return whether the token was invalidbooleanwasInvoked()Return whether the response handle was invoked.
-
-
-
Method Detail
-
invalidToken
public final java.lang.Object invalidToken(groovy.lang.Closure callable)
Description copied from interface:TokenResponseHandlerSpecify behavior in the event of an invalid token.- Specified by:
invalidTokenin interfaceTokenResponseHandler- Parameters:
callable- The closure to invoke in the event of an invalid token- Returns:
- A Grails model or null
-
invalidTokenInternal
protected abstract java.lang.Object invalidTokenInternal(groovy.lang.Closure callable)
-
wasInvoked
public boolean wasInvoked()
Description copied from interface:TokenResponseHandlerReturn whether the response handle was invoked.- Specified by:
wasInvokedin interfaceTokenResponseHandler- Returns:
- true if it was
-
wasInvalidToken
public boolean wasInvalidToken()
Description copied from interface:TokenResponseHandlerReturn whether the token was invalid- Specified by:
wasInvalidTokenin interfaceTokenResponseHandler- Returns:
- true if it was
-
-