Package net.sf.saxon.ma.jnode
Class JNodeType
java.lang.Object
net.sf.saxon.type.gnode.GNodeType
net.sf.saxon.ma.jnode.JNodeType
- All Implemented Interfaces:
NodePredicate,NodeTest,ItemType,ItemTypeWithSequenceTypeCache
- Direct Known Subclasses:
AnyJNodeType,RootJNodeType,SpecificJNodeType
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionasXNodeTest(Configuration config) Get an XNodeTest that will match any XNode that this NodeTest matches: that is, eliminate the possibility of matching a JNode.Get an alphabetic code representing the type, or at any rate, the nearest built-in type from which this type is derived.getCoercionPlan(int version) Get the coercion plan for use when this type is the required type for (say) coercion of arguments in a function calldoubleGet the default priority when this ItemType is used as an XSLT patterngetGenre()Determine the Genre (top-level classification) of this typeGet the primitive item type corresponding to this item type.intGet the primitive type corresponding to this item type.getUType()Get the correspondingUType.Methods inherited from class net.sf.saxon.type.gnode.GNodeType
explainMismatch, getAtomizedItemType, getContentType, getItemType, getQNameTest, isAtomicType, isAtomizable, isPlainType, matches, one, oneOrMore, test, toShortString, zeroOrMore, zeroOrOneMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface net.sf.saxon.type.ItemType
asChoiceItemType, getNormalizedDefaultPriority, normalizeItemType, toExportStringMethods inherited from interface net.sf.saxon.pattern.nodetest.NodeTest
export, isNillable
-
Constructor Details
-
JNodeType
public JNodeType()
-
-
Method Details
-
getValueType
-
getGenre
Determine the Genre (top-level classification) of this type -
getPrimitiveItemType
Get the primitive item type corresponding to this item type. For item(), this is Type.ITEM. For node(), it is Type.NODE. For specific node kinds, it is the value representing the node kind, for example Type.ELEMENT. For anyAtomicValue and union types it is Type.ATOMIC_VALUE. For numeric it is Type.NUMBER. For other atomic types it is the primitive type as defined in XML Schema, except that integer, xs:dayTimeDuration, and xs:yearMonthDuration are considered to be primitive types.- Specified by:
getPrimitiveItemTypein interfaceItemType- Overrides:
getPrimitiveItemTypein classGNodeType- Returns:
- the corresponding primitive type
-
getPrimitiveType
public int getPrimitiveType()Get the primitive type corresponding to this item type. For item(), this is Type.ITEM. For node(), it is Type.NODE. For specific node kinds, it is the value representing the node kind, for example Type.ELEMENT. For anyAtomicValue it is BuiltInAtomicType.ANY_ATOMIC. For numeric it is Type.NUMBER. For other atomic types it is the primitive type as defined in XML Schema, except that INTEGER is considered to be a primitive type.- Specified by:
getPrimitiveTypein interfaceItemType- Overrides:
getPrimitiveTypein classGNodeType- Returns:
- the integer fingerprint of the corresponding primitive type
-
getUType
Get the correspondingUType. A UType is a union of primitive item types. -
getDefaultPriority
public double getDefaultPriority()Get the default priority when this ItemType is used as an XSLT pattern- Returns:
- the default priority
-
getCoercionPlan
Get the coercion plan for use when this type is the required type for (say) coercion of arguments in a function call- Specified by:
getCoercionPlanin interfaceItemType- Overrides:
getCoercionPlanin classGNodeType- Parameters:
version- the XPath language version (40 or 31)
-
getBasicAlphaCode
Get an alphabetic code representing the type, or at any rate, the nearest built-in type from which this type is derived. The codes are designed so that for any two built-in types A and B, alphaCode(A) is a prefix of alphaCode(B) if and only if A is a supertype of B.- Returns:
- the alphacode for the nearest containing built-in type. For example: for xs:string return "AS", for xs:boolean "AB", for node() "N", for element() "NE", for map(*) "FM", for array(*) "FA".
-
asXNodeTest
Description copied from interface:NodeTestGet an XNodeTest that will match any XNode that this NodeTest matches: that is, eliminate the possibility of matching a JNode.
-