Saxon.Api

Class DocumentBuilder

Class DomDestination

Class DynamicContext

Class DynamicError

Class EmptyEnumerator

Class ExtensionFunctionCall

Class ExtensionFunctionDefinition

Class InvalidityHandlerWrapper

Class NamespaceConstant

Class NullDestination

Class Processor

Class QName

Class SchemaManager

Class SchemaValidator

Class Serializer

Class StandardLogger

Class StaticContext

Class StaticError

Class TextWriterDestination

Class WhitespacePolicy

Class XPathCompiler

Class XPathExecutable

Class XPathSelector

Class XQueryCompiler

Class XQueryEvaluator

Class XQueryExecutable

Class XdmAnyFunctionType

Class XdmAnyItemType

Class XdmAnyNodeType

Class XdmArray

Class XdmAtomicType

Class XdmAtomicValue

Class XdmDestination

  - Class TreeProtector

Class XdmEmptySequence

Class XdmExternalObjectValue

Class XdmFunctionItem

Class XdmItem

Class XdmItemType

Class XdmMap

Class XdmNode

Class XdmNodeKind

Class XdmSequenceType

Class XdmValue

Class XmlDestination

Class Xslt30Transformer

Class XsltCompiler

Class XsltExecutable

  - Class ParameterDetails

Class XsltPackage

Class XsltTransformer

Enum RecoveryPolicy

Enum SchemaValidationMode

Enum TreeModel

Enum XdmAxis

Interface IInvalidityHandler

Interface IMessageListener

Interface IQueryResolver

Interface IResultDocumentHandler

Interface IXdmEnumerator

Interface IXmlLocation

Interface SchemaResolver

 

Saxon.Api
Class XdmItem

Direct Known Subclasses
XdmAtomicValue, XdmExternalObjectValue, XdmFunctionItem, XdmNode

public abstract class XdmItem
extends XdmValue

The class XdmItem represents an item in a sequence, as defined by the XDM data model. An item is either an atomic value or a node.

An item is a member of a sequence, but it can also be considered as a sequence (of length one) in its own right. XdmItem is a subtype of XdmValue because every Item in the XDM data model is also a value.

It cannot be assumed that every sequence of length one will be represented by an XdmItem. It is quite possible for an XdmValue that is not an XdmItem to hold a singleton sequence.


Method Summary
 bool IsAtomic()

Determine whether the item is an atomic value

 String GetStringValue()

Get the string value of the item. For a node, this gets the string value of the node. For an atomic value, it has the same effect as casting the value to a string. In all cases the result is the same as applying the XPath string() function. For atomc values, the result is the same as the result of calling toString. This is not the case for nodes, where toString returns an XML serialization of the node.

 
Method Detail

IsAtomic

public abstract bool IsAtomic()

Determine whether the item is an atomic value

Returns:
true if the item is an atomic value, false if it is a Node

GetStringValue

public String GetStringValue()

Get the string value of the item. For a node, this gets the string value of the node. For an atomic value, it has the same effect as casting the value to a string. In all cases the result is the same as applying the XPath string() function. For atomc values, the result is the same as the result of calling toString. This is not the case for nodes, where toString returns an XML serialization of the node.

Returns:
The result of converting the item to a string