net.sf.saxon.type
public final class AnyType extends Object implements ComplexType, Serializable
Method Summary | |
---|---|
boolean | allowsAttributes()
Return true if this type (or any known type derived from it by extension) allows the element
to have one or more attributes. |
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.
|
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
|
boolean | containsElementWildcard()
Ask whether this type (or any known type derived from it by extension) allows the element
to have children that match a wildcard |
void | gatherAllPermittedChildren(IntHashSet children)
Get a list of all the names of elements that can appear as children of an element having this
complex type, as integer fingerprints. |
void | gatherAllPermittedDescendants(IntHashSet descendants)
Get a list of all the names of elements that can appear as descendants of an element having this
complex type, as integer fingerprints. |
SimpleType | getAttributeUseType(int fingerprint)
Find an attribute use within this complex type definition having a given attribute name
(identified by fingerprint), and return the schema type associated with that attribute.
|
SchemaType | getBaseType()
Get the base type |
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
|
int | getDerivationMethod()
Gets the integer code of the derivation method used to derive this type from its
parent. |
String | getDescription()
Get a description of this type for use in diagnostics |
String | getDisplayName()
Get the display name of the type: that is, a lexical QName with an arbitrary prefix
|
int | getElementParticleCardinality(int fingerprint)
Find an element particle within this complex type definition having a given element name
(identified by fingerprint), and return the cardinality associated with that element particle,
that is, the number of times the element can occur within this complex type. |
SchemaType | getElementParticleType(int fingerprint, boolean considerExtensions)
Find an element particle within this complex type definition having a given element name
(identified by fingerprint), and return the schema type associated with that element particle.
|
int | getFingerprint()
Get the fingerprint of the name of this type |
static AnyType | getInstance()
Get the singular instance of this class |
SchemaType | getKnownBaseType()
Returns the base type that this type inherits from. |
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. |
SimpleType | getSimpleContentType()
For a complex type with simple content, return the simple type of the content.
|
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 |
int | getValidationStatus()
Get the validation status - always valid |
int | getVariety()
Get the variety of this complex type. |
boolean | isAbstract()
Test whether this ComplexType has been marked as abstract. |
boolean | isAllContent()
Test whether this complex type has "all" content, that is, a content model
using an xs:all compositor |
boolean | isAnonymousType()
Test whether this is an anonymous type |
boolean | isAtomicType()
Test whether this SchemaType is an atomic type |
boolean | isComplexContent()
Test whether this complex type has complex content |
boolean | isComplexType()
Test whether this SchemaType is a complex type
|
boolean | isEmptiable()
Test whether the content model of this complexType allows empty content |
boolean | isEmptyContent()
Test whether the content type of this complex type is empty |
boolean | isIdRefType()
Ask whether this type is an IDREF or IDREFS type. |
boolean | isIdType()
Ask whether this type is an ID type. |
boolean | isMixedContent()
Test whether this complex type allows mixed content |
boolean | isRestricted()
Test whether this complex type is derived by restriction |
boolean | isSameType(SchemaType other)
Test whether this is the same type as another type. |
boolean | isSimpleContent()
Test whether this complex type has simple content |
boolean | isSimpleType()
Test whether this SchemaType is a simple type |
Returns: true if attributes are allowed
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
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: true if the content model of this type, or its extensions, contains an element wildcard
Parameters: children an integer set, initially empty, which on return will hold the fingerprints of all permitted child elements; if the result contains the value -1, this indicates that it is not possible to enumerate all the children, typically because of wildcards. In this case the other contents of the set should be ignored.
Parameters: descendants an integer set, initially empty, which on return will hold the fingerprints of all permitted descendant elements; if the result contains the value -1, this indicates that it is not possible to enumerate all the descendants, typically because of wildcards. In this case the other contents of the set should be ignored.
Parameters: fingerprint Identifies the name of the child element within this content model
Returns: null (this is the root of the type hierarchy)
Returns: the value of the 'block' attribute for this type
Returns: a numeric code representing the derivation method, for example DERIVATION_RESTRICTION
Returns: the string "xs:anyType"
Returns: a lexical QName identifying the type
Parameters: fingerprint Identifies the name of the child element within this content model
Parameters: fingerprint Identifies the name of the child element within this content model considerExtensions
Returns: the fingerprint.
Returns: the singular object representing xs:anyType
Returns: the base type.
Throws: IllegalStateException if this type is not valid.
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: this complex type does not have simple content
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: an iterator returning a single untyped atomic value, equivalent to the string value of the node. This follows the standard rules for elements with mixed content.
Returns: false: this class is not abstract.
Returns: false: this complex type does not use an "all" compositor
Returns: true if this SchemaType is an anonymous type
Returns: true if this SchemaType is an atomic type
Returns: true: this complex type has complex content
Returns: true if this SchemaType is a complex type
Returns: true: the content is allowed to be empty
Returns: false: the content model is not empty
Returns: true: mixed content is allowed
Returns: false: this type is not a restriction
Returns: false: this complex type has complex content
Returns: true if this SchemaType is a simple type