added check to make sure only serverName or serviceName is set, but not both.
This commit is contained in:
Scott Battaglia 2011-06-27 03:00:45 +00:00
parent f3b6ae5a4d
commit 413837e4df
1 changed files with 1 additions and 0 deletions

View File

@ -101,6 +101,7 @@ public abstract class AbstractCasFilter extends AbstractConfigurationFilter {
CommonUtils.assertNotNull(this.artifactParameterName, "artifactParameterName cannot be null.");
CommonUtils.assertNotNull(this.serviceParameterName, "serviceParameterName cannot be null.");
CommonUtils.assertTrue(CommonUtils.isNotEmpty(this.serverName) || CommonUtils.isNotEmpty(this.service), "serverName or service must be set.");
CommonUtils.assertTrue(CommonUtils.isBlank(this.serverName) || CommonUtils.isBlank(this.service), "serverName and service cannot both be set. You MUST ONLY set one.");
}
// empty implementation as most filters won't need this.