Class NotBlankValidator
java.lang.Object
org.apache.logging.log4j.core.config.plugins.validation.validators.NotBlankValidator
- All Implemented Interfaces:
ConstraintValidator<NotBlank>
Validator that checks if a
CharSequence
is not entirely composed of
whitespace.- Since:
- 2.18.0
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
initialize
(NotBlank anAnnotation) Called before this validator is used with the constraint annotation value.boolean
Indicates if the given value is valid.
-
Constructor Details
-
NotBlankValidator
public NotBlankValidator()
-
-
Method Details
-
initialize
Description copied from interface:ConstraintValidator
Called before this validator is used with the constraint annotation value.- Specified by:
initialize
in interfaceConstraintValidator<NotBlank>
- Parameters:
anAnnotation
- the annotation value this validator will be validating.
-
isValid
Description copied from interface:ConstraintValidator
Indicates if the given value is valid.- Specified by:
isValid
in interfaceConstraintValidator<NotBlank>
- Parameters:
name
- the name to use for error reportingvalue
- the value to validate.- Returns:
true
if the given value is valid.
-