|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface represents a simple type, which may be a built-in simple type, or a user-defined simple type.
Field Summary |
Fields inherited from interface net.sf.saxon.type.SchemaType |
DERIVATION_EXTENSION, DERIVATION_LIST, DERIVATION_RESTRICTION, DERIVATION_UNION, DERIVE_BY_SUBSTITUTION |
Fields inherited from interface net.sf.saxon.type.SchemaComponent |
FIXED_UP, INCOMPLETE, INVALID, UNVALIDATED, VALIDATED, VALIDATING |
Method Summary | |
SchemaType |
getBuiltInBaseType()
Get the built-in type from which this type is derived by restriction |
AtomicType |
getCommonAtomicType()
Get the most specific possible atomic type that all items in this SimpleType belong to |
SequenceIterator |
getTypedValue(java.lang.CharSequence value,
NamespaceResolver resolver,
NameChecker nameChecker)
Get the typed value corresponding to a given string value, assuming it is valid against this type |
int |
getWhitespaceAction(TypeHierarchy th)
Determine how values of this simple type are whitespace-normalized. |
boolean |
isAtomicType()
Test whether this Simple Type is an atomic type |
boolean |
isExternalType()
Return true if this is an external object type, that is, a Saxon-defined type for external Java or .NET objects |
boolean |
isListType()
Test whether this Simple Type is a list type |
boolean |
isNamespaceSensitive()
Test whether this type is namespace sensitive, that is, if a namespace context is needed to translate between the lexical space and the value space. |
boolean |
isUnionType()
Test whether this Simple Type is a union type |
ValidationException |
validateContent(java.lang.CharSequence value,
NamespaceResolver nsResolver,
NameChecker nameChecker)
Check whether a given input string is valid according to this SimpleType |
Methods inherited from interface net.sf.saxon.type.SchemaType |
allowsDerivation, analyzeContentExpression, atomize, checkTypeDerivationIsOK, getBaseType, getBlock, getDerivationMethod, getDescription, getDisplayName, getFingerprint, getNameCode, getTypedValue, isAnonymousType, isComplexType, isSameType, isSimpleType |
Methods inherited from interface net.sf.saxon.type.SchemaComponent |
getValidationStatus |
Method Detail |
public boolean isAtomicType()
isAtomicType
in interface SchemaType
public boolean isListType()
public boolean isUnionType()
public boolean isExternalType()
public AtomicType getCommonAtomicType()
public SchemaType getBuiltInBaseType()
public SequenceIterator getTypedValue(java.lang.CharSequence value, NamespaceResolver resolver, NameChecker nameChecker) throws ValidationException
value
- the string valueresolver
- a namespace resolver used to resolve any namespace prefixes appearing
in the content of values. Can supply null, in which case any namespace-sensitive content
will be rejected.nameChecker
- a NameChecker used in the case of types that are defined in terms of the
XML NCName syntax: this is used to check conformance to XML 1.0 or XML 1.1 naming rules, as
appropriate
AtomicValue
ValidationException
- if the supplied value is not in the lexical space of the data typepublic ValidationException validateContent(java.lang.CharSequence value, NamespaceResolver nsResolver, NameChecker nameChecker)
value
- the input string to be checkednsResolver
- a namespace resolver used to resolve namespace prefixes if the type
is namespace sensitive. The value supplied may be null; in this case any namespace-sensitive
content will throw an UnsupportedOperationException.nameChecker
-
java.lang.UnsupportedOperationException
- if the type is namespace-sensitive and no namespace
resolver is suppliedpublic boolean isNamespaceSensitive()
public int getWhitespaceAction(TypeHierarchy th)
th
-
Whitespace.PRESERVE
, Whitespace.COLLAPSE
,
Whitespace.REPLACE
.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |