Class ConnectionFactoryValidator
java.lang.Object
net.shibboleth.idp.attribute.resolver.dc.ldap.impl.ConnectionFactoryValidator
- All Implemented Interfaces:
Validator
Validator implementation that invokes
Connection.open() to determine if the ConnectionFactory is properly
configured.-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final org.slf4j.LoggerClass logger.private booleanWhether validate should throw. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanReturns whetherValidator.validate(DataConnector)should throw or log errors.voidsetThrowValidateError(boolean what) Sets whetherValidator.validate(DataConnector)should throw or log errors.voidvalidate(DataConnector dataConnector) Probe the data connector and conditionally fails if it is not valid and ready for use.
-
Field Details
-
log
@Nonnull private final org.slf4j.Logger logClass logger. -
throwOnValidateError
private boolean throwOnValidateErrorWhether validate should throw.
-
-
Constructor Details
-
ConnectionFactoryValidator
public ConnectionFactoryValidator()
-
-
Method Details
-
setThrowValidateError
public void setThrowValidateError(boolean what) Sets whetherValidator.validate(DataConnector)should throw or log errors.- Specified by:
setThrowValidateErrorin interfaceValidator- Parameters:
what- whetherValidator.validate(DataConnector)should throw or log errors
-
isThrowValidateError
public boolean isThrowValidateError()Returns whetherValidator.validate(DataConnector)should throw or log errors.- Specified by:
isThrowValidateErrorin interfaceValidator- Returns:
- whether
Validator.validate(DataConnector)should throw or log errors
-
validate
Probe the data connector and conditionally fails if it is not valid and ready for use.- Specified by:
validatein interfaceValidator- Parameters:
dataConnector- data connector to validate- Throws:
ValidationException- thrown if validation fails andValidator.isThrowValidateError()is true
-