public interface XSSimpleType extends XSSimpleTypeDefinition
XSSimpleType
represents the simple type
definition of schema component and defines methods to query the information
contained.
Any simple type (atomic, list or union) will implement this interface.
It inherits from XSTypeDecl
.Modifier and Type | Field and Description |
---|---|
static short |
PRIMITIVE_ANYURI
"anyURI" type
|
static short |
PRIMITIVE_BASE64BINARY
"base64Binary" type
|
static short |
PRIMITIVE_BOOLEAN
"boolean" type
|
static short |
PRIMITIVE_DATE
"date" type
|
static short |
PRIMITIVE_DATETIME
"dataTime" type
|
static short |
PRIMITIVE_DECIMAL
"decimal" type
|
static short |
PRIMITIVE_DOUBLE
"double" type
|
static short |
PRIMITIVE_DURATION
"duration" type
|
static short |
PRIMITIVE_FLOAT
"float" type
|
static short |
PRIMITIVE_GDAY
"gDay" type
|
static short |
PRIMITIVE_GMONTH
"gMonth" type
|
static short |
PRIMITIVE_GMONTHDAY
"gMonthDay" type
|
static short |
PRIMITIVE_GYEAR
"gYear" type
|
static short |
PRIMITIVE_GYEARMONTH
"gYearMonth" type
|
static short |
PRIMITIVE_HEXBINARY
"hexBinary" type
|
static short |
PRIMITIVE_NOTATION
"NOTATION" type
|
static short |
PRIMITIVE_PRECISIONDECIMAL
"precisionDecimal" type
|
static short |
PRIMITIVE_QNAME
"QName" type
|
static short |
PRIMITIVE_STRING
"string" type
|
static short |
PRIMITIVE_TIME
"time" type
|
static short |
WS_COLLAPSE
collapse the white spaces
|
static short |
WS_PRESERVE
preserve the white spaces
|
static short |
WS_REPLACE
replace the white spaces
|
FACET_ENUMERATION, FACET_FRACTIONDIGITS, FACET_LENGTH, FACET_MAXEXCLUSIVE, FACET_MAXINCLUSIVE, FACET_MAXLENGTH, FACET_MINEXCLUSIVE, FACET_MININCLUSIVE, FACET_MINLENGTH, FACET_NONE, FACET_PATTERN, FACET_TOTALDIGITS, FACET_WHITESPACE, ORDERED_FALSE, ORDERED_PARTIAL, ORDERED_TOTAL, VARIETY_ABSENT, VARIETY_ATOMIC, VARIETY_LIST, VARIETY_UNION
COMPLEX_TYPE, SIMPLE_TYPE
Modifier and Type | Method and Description |
---|---|
void |
applyFacets(XSFacets facets,
short presentFacet,
short fixedFacet,
ValidationContext context)
If this type is created from restriction, then some facets can be applied
to the simple type.
|
short |
getPrimitiveKind()
return an ID representing the built-in primitive base type.
|
short |
getWhitespace()
Return the whitespace corresponding to this datatype.
|
boolean |
isEqual(Object value1,
Object value2)
Check whether two actual values are equal.
|
boolean |
isIDType()
Check whether this type is or is derived from ID.
|
Object |
validate(Object content,
ValidationContext context,
ValidatedInfo validatedInfo)
validate a given string value, represented by content.toString().
|
Object |
validate(String content,
ValidationContext context,
ValidatedInfo validatedInfo)
validate a given string against this simple type.
|
void |
validate(ValidationContext context,
ValidatedInfo validatedInfo)
Validate an actual value against this simple type.
|
getAnnotations, getBounded, getBuiltInKind, getDefinedFacets, getFacet, getFacets, getFinite, getFixedFacets, getItemType, getLexicalEnumeration, getLexicalFacetValue, getLexicalPattern, getMemberTypes, getMultiValueFacets, getNumeric, getOrdered, getPrimitiveType, getVariety, isDefinedFacet, isFixedFacet
derivedFrom, derivedFromType, getAnonymous, getBaseType, getFinal, getTypeCategory, isFinal
getName, getNamespace, getNamespaceItem, getType
static final short WS_PRESERVE
static final short WS_REPLACE
static final short WS_COLLAPSE
static final short PRIMITIVE_STRING
static final short PRIMITIVE_BOOLEAN
static final short PRIMITIVE_DECIMAL
static final short PRIMITIVE_FLOAT
static final short PRIMITIVE_DOUBLE
static final short PRIMITIVE_DURATION
static final short PRIMITIVE_DATETIME
static final short PRIMITIVE_TIME
static final short PRIMITIVE_DATE
static final short PRIMITIVE_GYEARMONTH
static final short PRIMITIVE_GYEAR
static final short PRIMITIVE_GMONTHDAY
static final short PRIMITIVE_GDAY
static final short PRIMITIVE_GMONTH
static final short PRIMITIVE_HEXBINARY
static final short PRIMITIVE_BASE64BINARY
static final short PRIMITIVE_ANYURI
static final short PRIMITIVE_QNAME
static final short PRIMITIVE_PRECISIONDECIMAL
static final short PRIMITIVE_NOTATION
short getPrimitiveKind()
Object validate(String content, ValidationContext context, ValidatedInfo validatedInfo) throws InvalidDatatypeValueException
content
- the string value that needs to be validatedcontext
- the validation contextvalidatedInfo
- used to store validation resultInvalidDatatypeValueException
Object validate(Object content, ValidationContext context, ValidatedInfo validatedInfo) throws InvalidDatatypeValueException
content
- the string value that needs to be validatedcontext
- the validation contextvalidatedInfo
- used to store validation resultInvalidDatatypeValueException
void validate(ValidationContext context, ValidatedInfo validatedInfo) throws InvalidDatatypeValueException
context
- the validation contextvalidatedInfo
- used to provide the actual value and member typesInvalidDatatypeValueException
- exception for invalid values.void applyFacets(XSFacets facets, short presentFacet, short fixedFacet, ValidationContext context) throws InvalidDatatypeFacetException
XSFacets
is used to pass the value of
different facets.facets
- the value of all the facetspresentFacet
- bit combination value of the costraining facet
constants which are present.fixedFacet
- bit combination value of the costraining facet
constants which are fixed.context
- the validation contextInvalidDatatypeFacetException
- exception for invalid facet values.boolean isEqual(Object value1, Object value2)
value1
- the first valuevalue2
- the second valueboolean isIDType()
short getWhitespace() throws DatatypeException
DatatypeException
- union datatypes don't have whitespace facet associated with themCopyright © 2017 JBoss by Red Hat. All rights reserved.