web/src/main/java/org/springframework/security/web/authentication/switchuser/SwitchUserFilter.java
public void setSwitchFailureUrl(String switchFailureUrl) {
		Assert.isTrue(UrlUtils.isValidRedirectUrl(switchFailureUrl),
				"switchFailureUrl must be a valid redirect URL");
		this.switchFailureUrl = switchFailureUrl;
	}
public void setSwitchFailureUrl(String switchFailureUrl) {
		Assert.isTrue(UrlUtils.isValidRedirectUrl(switchFailureUrl),
				"switchFailureUrl must be a valid redirect URL");
		this.switchFailureUrl = switchFailureUrl;
	}
public void setSwitchFailureUrl ( String switchFailureUrl ) { Assert . isTrue ( UrlUtils . isValidRedirectUrl ( switchFailureUrl ) , "switchFailureUrl must be a valid redirect URL" ) ; this . switchFailureUrl = switchFailureUrl ; }
Sets the URL to which a user should be redirected if the switch fails. For example,
this might happen because the account they are attempting to switch to is invalid
(the user doesn't exist, account is locked etc).
<p>
If not set, an error message will be written to the response.
<p>
Use {@link #setFailureHandler(AuthenticationFailureHandler) failureHandler} instead
if you need more customized behaviour.

@param switchFailureUrl the url to redirect to.
Sets the URL to which a user should be redirected if the switch fails . For example this might happen because the account they are attempting to switch to is invalid ( the user doesn t exist account is locked etc ) . <p > If not set an error message will be written to the response . <p > Use { @link #setFailureHandler ( AuthenticationFailureHandler ) failureHandler } instead if you need more customized behaviour .