net.sf.saxon.type
public class BuiltInListType extends Object implements ListType, Serializable
This class is used to implement the built-in list types NMTOKENS, ENTITIES, IDREFS. It is also used to represent the anonymous type of the xsi:schemaLocation attribute (a list of xs:anyURI values).
Field Summary | |
---|---|
static BuiltInListType | ANY_URIS |
static BuiltInListType | ENTITIES |
static BuiltInListType | IDREFS |
static BuiltInListType | NMTOKENS |
Constructor Summary | |
---|---|
BuiltInListType(int fingerprint)
Create a new ListType. |
Method Summary | |
---|---|
boolean | allowsDerivation(int derivation)
Determines whether derivation (of a particular kind)
from this type is allowed, based on the "final" property
|
void | analyzeContentExpression(Expression expression, int kind, StaticContext env)
Analyze an expression to see whether the expression is capable of delivering a value of this
type.
|
String | applyWhitespaceNormalization(String value)
Apply the whitespace normalization rules for this simple type |
Value | atomize(NodeInfo node)
Get the typed value of a node that is annotated with this schema type. |
void | checkTypeDerivationIsOK(SchemaType type, int block)
Check that this type is validly derived from a given type
|
SchemaType | getBaseType()
Returns the base type that this type inherits from.
|
int | getBlock()
Returns the value of the 'block' attribute for this type, as a bit-signnificant
integer with fields such as DERIVATION_LIST and DERIVATION_EXTENSION
|
SchemaType | getBuiltInBaseType() |
AtomicType | getCommonAtomicType()
Get the most specific possible atomic type that all items in this SimpleType belong to
|
int | getDerivationMethod()
Gets the integer code of the derivation method used to derive this type from its
parent. |
String | getDescription() |
String | getDisplayName()
Get the display name of the type: that is, a lexical QName with an arbitrary prefix
|
int | getFingerprint()
Get the fingerprint of the name of this type |
SimpleType | getItemType()
Returns the simpleType of the items in this ListType. |
SchemaType | getKnownBaseType()
Returns the base type that this type inherits from. |
String | getLocalName()
Get the local name of this type |
String | getName()
Get the local name of this type
|
int | getNameCode()
Get the namecode of the name of this type. |
int | getRedefinitionLevel()
Get the redefinition level. |
String | getSystemId()
Get the URI of the schema document containing the definition of this type |
String | getTargetNamespace()
Get the target namespace of this type
|
SequenceIterator | getTypedValue(NodeInfo node)
Get the typed value of a node that is annotated with this schema type. |
SequenceIterator | getTypedValue(CharSequence value, NamespaceResolver resolver, NameChecker nameChecker)
Get the typed value of a given input string. |
int | getValidationStatus()
Get the validation status - always valid |
int | getWhitespaceAction(TypeHierarchy th)
Determine how values of this simple type are whitespace-normalized.
|
boolean | isAnonymousType()
Test whether this is an anonymous type |
boolean | isAtomicType()
Test whether this Simple Type is an atomic type |
boolean | isBuiltInType()
Determine whether this is a built-in type or a user-defined type |
boolean | isComplexType()
Test whether this SchemaType is a complex 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 | isIdRefType()
Ask whether this type is an IDREF or IDREFS type. |
boolean | isIdType()
Ask whether this type is an ID type. |
boolean | isListType()
Returns true if this type is derived by list, or if it is derived by restriction
from a list type, or if it is a union that contains a list as one of its members |
boolean | isNamespaceSensitive() |
boolean | isSameType(SchemaType other)
Test whether this is the same type as another type. |
boolean | isSimpleType()
Test whether this SchemaType is a simple type |
boolean | isUnionType() |
CharSequence | postprocess(CharSequence input)
Reverse any pre-lexical facets, other than whitespace. |
CharSequence | preprocess(CharSequence input)
Apply any pre-lexical facets, other than whitespace. |
ValidationFailure | validateContent(CharSequence value, NamespaceResolver nsResolver, NameChecker nameChecker)
Check whether a given input string is valid according to this SimpleType |
Parameters: fingerprint identifies the name of the type
Parameters: derivation the kind of derivation, for example DERIVATION_LIST
Returns: true if this kind of derivation is allowed
Parameters: expression the expression that delivers the content kind the node kind whose content is being delivered: ELEMENT, ATTRIBUTE, or DOCUMENT env the XPath static context
Throws: net.sf.saxon.trans.XPathException if the expression will never deliver a value of the correct type
Parameters: value the string before whitespace normalization
Returns: the string after whitespace normalization
Parameters: node the node whose typed value is required
Returns: the typed value.
Since: 8.5
Parameters: type the type from which this type is derived block the derivations that are blocked by the relevant element declaration
Throws: SchemaException if the derivation is not allowed
Returns: the base type.
Returns: the value of the 'block' attribute for this type
Returns: the lowest common supertype of all member types
Returns: a numeric code representing the derivation method, for example DERIVATION_RESTRICTION
Returns: a lexical QName identifying the type
Returns: the fingerprint. Returns an invented fingerprint for an anonymous type.
Returns: the simpleType of the items in this ListType.
Returns: the base type.
Throws: IllegalStateException if this type is not valid.
Returns: the local part of the name, or null if the type is anonymous
Returns: the local name of this type definition, if it has one. Return null in the case of an anonymous type.
Returns: the redefinition level
Returns: null for a built-in type
Returns: the target namespace of this type definition, if it has one. Return null in the case of an anonymous type, and in the case of a global type defined in a no-namespace schema.
Parameters: node the node whose typed value is required
Returns: a SequenceIterator over the atomic values making up the typed value of the specified node. The objects returned by this iterator are of type AtomicValue
Parameters: value the string whose typed value is required resolver namespace resolver for namespace-sensitive content nameChecker name checker for XML-version sensitive content
Parameters: th the type hierarchy cache
Returns: true if this SchemaType is an anonymous type
Returns: false, this is not an atomic type
Returns: true if this SchemaType is a complex type
Returns: true if this SchemaType is a simple type
Parameters: input the value to be postprocessed: this is the "ordinary" result of converting the value to a string
Returns: the value after postprocessing
Parameters: input the value to be preprocessed
Returns: the value after preprocessing
Parameters: value the input string to be checked nsResolver 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 XML 1.0 or 1.1 name checker, for types such as xs:NCName
Throws: UnsupportedOperationException if the type is namespace-sensitive and no namespace resolver is supplied