SEC-1058: Renamed "forwardToDestination" to "useForward" for simplicity and consistency with the namespace.

This commit is contained in:
Luke Taylor 2008-12-14 22:53:31 +00:00
parent 2927b8464f
commit 3f38035057
2 changed files with 3 additions and 7 deletions

View File

@ -27,10 +27,6 @@ import org.springframework.util.Assert;
public class SimpleUrlAuthenticationFailureHandler implements AuthenticationFailureHandler {
private String defaultFailureUrl;
private boolean forwardToDestination = false;
/**
* If true, causes any redirection URLs to be calculated minus the protocol
* and context path (defaults to false).
*/
private boolean useRelativeContext = false;
public void onAuthenticationFailure(HttpServletRequest request, HttpServletResponse response,
@ -56,7 +52,7 @@ public class SimpleUrlAuthenticationFailureHandler implements AuthenticationFail
this.defaultFailureUrl = defaultFailureUrl;
}
protected boolean isForwardToDestination() {
protected boolean isUseForward() {
return forwardToDestination;
}
@ -64,7 +60,7 @@ public class SimpleUrlAuthenticationFailureHandler implements AuthenticationFail
* If set to <tt>true</tt>, performs a forward to the failure destination URL instead of a redirect. Defaults to
* <tt>false</tt>.
*/
public void setForwardToDestination(boolean forwardToDestination) {
public void setUseForward(boolean forwardToDestination) {
this.forwardToDestination = forwardToDestination;
}

View File

@ -511,7 +511,7 @@ public class AbstractProcessingFilterTests extends TestCase {
successHandler.setDefaultTargetUrl("http://monkeymachine.co.uk/");
filter.setSuccessHandler(successHandler);
filter.setFailureHandler(failureHandler);
failureHandler.setForwardToDestination(true);
failureHandler.setUseForward(true);
failureHandler.setDefaultFailureUrl("/error");
executeFilterInContainerSimulator(config, filter, request, response, chain);