Module org.tquadrat.foundation.xml
Enum Class XMLBuilderUtils.Validator
java.lang.Object
java.lang.Enum<XMLBuilderUtils.Validator>
org.tquadrat.foundation.xml.builder.XMLBuilderUtils.Validator
- All Implemented Interfaces:
Serializable
,Comparable<XMLBuilderUtils.Validator>
,Constable
- Enclosing class:
XMLBuilderUtils
@ClassVersion(sourceVersion="$Id: XMLBuilderUtils.java 1101 2024-02-18 00:18:48Z tquadrat $")
@API(status=STABLE,
since="0.0.5")
public static enum XMLBuilderUtils.Validator
extends Enum<XMLBuilderUtils.Validator>
The (default) validators.
- Author:
- Thomas Thrien (thomas.thrien@tquadrat.org)
- Version:
- $Id: XMLBuilderUtils.java 1101 2024-02-18 00:18:48Z tquadrat $
- Since:
- 0.0.5
- UML Diagram
-
UML Diagram for "org.tquadrat.foundation.xml.builder.XMLBuilderUtils.Validator"
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionThe attribute name validator.The element name validator.The nmtoken validator.The namespace prefix validator. -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate Supplier
<? extends Predicate<CharSequence>> The method that retrieves the current validator.private Predicate
<CharSequence> The default validator. -
Constructor Summary
ConstructorsModifierConstructorDescriptionprivate
Validator
(Predicate<CharSequence> defaultValidator, Supplier<? extends Predicate<CharSequence>> currentValidatorSupplier) Creates a newValidator
instance. -
Method Summary
Modifier and TypeMethodDescriptionfinal Predicate
<CharSequence> Returns the current validator.final Predicate
<CharSequence> Returns the default validator.static XMLBuilderUtils.Validator
Returns the enum constant of this class with the specified name.static XMLBuilderUtils.Validator[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
VALIDATOR_AttributeName
The attribute name validator. -
VALIDATOR_ElementName
The element name validator. -
VALIDATOR_NMToken
The nmtoken validator. -
VALIDATOR_Prefix
The namespace prefix validator.
-
-
Field Details
-
m_CurrentValidatorSupplier
The method that retrieves the current validator. -
m_DefaultValidator
The default validator.
-
-
Constructor Details
-
Validator
private Validator(Predicate<CharSequence> defaultValidator, Supplier<? extends Predicate<CharSequence>> currentValidatorSupplier) Creates a newValidator
instance.- Parameters:
defaultValidator
- The default validator.currentValidatorSupplier
- The method that retrieves the current validator.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
getCurrent
Returns the current validator.- Returns:
- The current validator.
-
getDefault
Returns the default validator.- Returns:
- The default validator.
-