|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.saxonica.schema.Facet com.saxonica.schema.LengthFacet
public class LengthFacet
Represents the length facet. Sublclasses represent the minLength and maxLength facets.
Field Summary |
---|
Fields inherited from class com.saxonica.schema.Facet |
---|
ENUMERATION, FRACTIONDIGITS, LENGTH, MAX_EXCLUSIVE, MAX_INCLUSIVE, MAX_LENGTH, MIN_EXCLUSIVE, MIN_INCLUSIVE, MIN_LENGTH, PATTERN, TOTALDIGITS, WHITESPACE |
Constructor Summary | |
---|---|
LengthFacet()
|
Method Summary | |
---|---|
void |
checkFacetRestriction(UserSimpleType type,
SimpleType base)
Check that this facet is legal when used on a type derived by restriction |
String |
getName()
Returns the name of this Facet |
String |
getValue()
Returns the character (String) representation of this facet |
void |
setIntegerValue(int value)
Set the value as an integer |
void |
setValue(String value)
Set the value of this facet as a string. |
boolean |
testAtomicValue(AtomicValue value)
Test whether an atomic value conforms to this facet |
boolean |
testLength(int actualLength)
Test whether a supplied length conforms to this required length. |
long |
toLong()
Returns the numeric value of this facet |
Methods inherited from class com.saxonica.schema.Facet |
---|
appliesToWholeList, getWhitespaceAction, isFacetName, isFixed, isNewlyIntroduced, makeFacet, serializeFacet, setFixed |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LengthFacet()
Method Detail |
---|
public String getName()
Facet
getName
in class Facet
public String getValue()
Facet
getValue
in class Facet
public long toLong()
Facet
toLong
in class Facet
public void setIntegerValue(int value)
public void setValue(String value) throws SchemaException
setValue
in class Facet
value
- the value as a string, which must parse as an integer
SchemaException
- if the value is invalid.public void checkFacetRestriction(UserSimpleType type, SimpleType base) throws SchemaException, ValidationException
checkFacetRestriction
in class Facet
base
- the type from which the restricted type is derivedtype
- the type on which the facet is defined
SchemaException
- if the facet is not legal
ValidationException
public boolean testAtomicValue(AtomicValue value)
testAtomicValue
in class Facet
value
- the value to be tested
public boolean testLength(int actualLength)
testLength
in class Facet
actualLength
- the actual length of the list
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |