Class RegexpValidator
- java.lang.Object
-
- org.apache.avalon.framework.logger.AbstractLogEnabled
-
- org.ametys.runtime.parameter.DefaultValidator
-
- org.ametys.plugins.core.impl.validator.RegexpValidator
-
- All Implemented Interfaces:
Validator
,PluginAware
,Configurable
,LogEnabled
,Serviceable
public class RegexpValidator extends DefaultValidator
This validator validates that the regular expression set is valid
-
-
Field Summary
-
Fields inherited from class org.ametys.runtime.parameter.DefaultValidator
_invalidText, _isMandatory, _pluginName, _regexp, _smanager
-
-
Constructor Summary
Constructors Constructor Description RegexpValidator()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private void
_validateRegexp(String regexp, Errors errors)
void
configure(Configuration configuration)
protected void
validateArrayValues(Object[] values, Errors errors)
Validates a array of values.protected void
validateSingleValue(Object value, Errors errors)
Validates a single value.-
Methods inherited from class org.ametys.runtime.parameter.DefaultValidator
equals, getConfiguration, hashCode, service, setPluginInfo, validate
-
Methods inherited from class org.apache.avalon.framework.logger.AbstractLogEnabled
enableLogging, getLogger, setupLogger, setupLogger, setupLogger
-
-
-
-
Constructor Detail
-
RegexpValidator
public RegexpValidator()
-
-
Method Detail
-
configure
public void configure(Configuration configuration) throws ConfigurationException
- Specified by:
configure
in interfaceConfigurable
- Overrides:
configure
in classDefaultValidator
- Throws:
ConfigurationException
-
validateSingleValue
protected void validateSingleValue(Object value, Errors errors)
Description copied from class:DefaultValidator
Validates a single value.- Overrides:
validateSingleValue
in classDefaultValidator
- Parameters:
value
- the value to validate (can benull
).errors
- the structure to populate if the validation failed.
-
validateArrayValues
protected void validateArrayValues(Object[] values, Errors errors)
Description copied from class:DefaultValidator
Validates a array of values.- Overrides:
validateArrayValues
in classDefaultValidator
- Parameters:
values
- the values to validateerrors
- the structure to populate if the validation failed.
-
_validateRegexp
private void _validateRegexp(String regexp, Errors errors)
-
-