Package org.arakhne.afc.inputoutput.xml
Class XMLValueConstraint<E>
- java.lang.Object
-
- org.arakhne.afc.inputoutput.xml.XMLValueConstraint<E>
-
- Type Parameters:
E- is the type of the attribute value to test.
- All Implemented Interfaces:
XMLConstraint
public abstract class XMLValueConstraint<E> extends Object implements XMLConstraint
Matches the attribute "id" with the given value.- Since:
- 14.0
- Version:
- 17.0 2020-01-04 14:41:40
- Author:
- Stéphane GALLAND
- Maven Group Id:
- org.arakhne.afc.core
- Maven Artifact Id:
- inputoutput
-
-
Constructor Summary
Constructors Constructor Description XMLValueConstraint(String name, E value)Constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract EconvertValue(String stringValue)Invoked to convert the string into the value to test.booleanisValidElement(Element element)Replies if the given element is validating the constraints.
-
-
-
Method Detail
-
convertValue
protected abstract E convertValue(String stringValue)
Invoked to convert the string into the value to test.- Parameters:
stringValue- the value to convert.- Returns:
- the value to test.
-
isValidElement
public boolean isValidElement(Element element)
Description copied from interface:XMLConstraintReplies if the given element is validating the constraints.- Specified by:
isValidElementin interfaceXMLConstraint- Parameters:
element- the element to validate.- Returns:
trueif validation is success, otherwisefalse.
-
-