Module de.cuioss.java.tools
Class Validator<F extends FormatterSupport>
java.lang.Object
de.cuioss.tools.formatting.template.Validator<F>
- Type Parameters:
F- at leastFormatterSupport
- All Implemented Interfaces:
Serializable
- See Also:
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic final classValidator.ValidatorBuilder<E extends FormatterSupport> -
Method Summary
Modifier and TypeMethodDescriptionstatic <E extends FormatterSupport>
Validator.ValidatorBuilder<E>builder()voidstatic <E extends FormatterSupport>
voidvalidateTemplate(String template, Lexer<E> lexer) This method provide validation for template of specific expression language.static <E extends FormatterSupport>
voidvalidateTemplate(String template, E source) This method provide only validation of simple expression language with squared brackets.static <E extends FormatterSupport>
voidvalidateTemplate(String template, Class<E> source) This method provide only validation of simple expression language with squared brackets.
-
Method Details
-
validate
- Parameters:
template- must not be null if template doesn't fit to el-expression or use tokens which are not supported.
-
builder
- Returns:
- an
Validator.ValidatorBuilder
-
validateTemplate
This method provide only validation of simple expression language with squared brackets. If some other expression language is used on the template validation will fail. If there is a need for usage of other expression language usevalidateTemplate(String, Lexer)- Parameters:
template- input which should be validatedsource- source must not be null
-
validateTemplate
This method provide only validation of simple expression language with squared brackets. If some other expression language is used on the template validation will fail. If there is a need for usage of other expression language usevalidateTemplate(String, Lexer)- Parameters:
template- input which should be validatedsource- target type must not be null
-
validateTemplate
This method provide validation for template of specific expression language. Therefore, you need to provide a fitting Lexer.- Parameters:
template- input which should be validatedlexer-Lexerfor usage of specific expression language on template
-