Class DocumentBuilder
Class DomDestination
Class DynamicError
Class NullDestination
Class Processor
Class QName
Class SchemaManager
Class SchemaValidator
Class SequenceEnumerator
Class Serializer
Class StaticError
Class TextWriterDestination
Class XPathCompiler
Class XPathExecutable
Class XPathSelector
Class XQueryCompiler
Class XQueryEvaluator
Class XQueryExecutable
Class XdmAtomicValue
Class XdmDestination
Class XdmEmptySequence
Class XdmItem
Class XdmNode
Class XdmValue
Class XmlDestination
Class XsltCompiler
Class XsltExecutable
Class XsltTransformer
Enum RecoveryPolicy
Enum SchemaValidationMode
Enum TreeModel
Enum WhitespacePolicy
Enum XdmAxis
Interface IMessageListener
Interface IQueryResolver
Interface IResultDocumentHandler
Interface IXmlLocation
Interface SchemaResolver
public class XdmAtomicValue
The class XdmAtomicValue
represents an item in an XPath 2.0 sequence
that is an atomic value. The value may belong to any of the 19 primitive types
defined in XML Schema, or to a type derived from these primitive types, or to
the XPath 2.0 type xdt:untypedAtomic
Constructor Summary | |
---|---|
XdmAtomicValue(long i)
Construct an atomic value of type |
|
XdmAtomicValue(decimal d)
Construct an atomic value of type |
|
XdmAtomicValue(float f)
Construct an atomic value of type |
|
XdmAtomicValue(double d)
Construct an atomic value of type |
|
XdmAtomicValue(bool b)
Construct an atomic value of type |
|
XdmAtomicValue(System.Uri u)
Construct an atomic value of type |
|
XdmAtomicValue(QName q)
Construct an atomic value of type |
|
XdmAtomicValue(string lexicalForm, QName type, Processor processor) Construct an atomic value of a given built-in or user-defined type |
|
XdmAtomicValue() |
Property Summary | |
---|---|
Object |
Value Get the value as a CLI object of the nearest equivalent type. |
Method Summary | |
---|---|
bool |
IsAtomic() Determine whether the item is an atomic value |
static XdmAtomicValue |
wrapExternalObject(object external)
Create an atomic value that wraps an external object. Such values can be used
in conjunction with extension functions. (Synonym of |
static XdmAtomicValue |
WrapExternalObject(object external) Create an atomic value that wraps an external object. Such values can be used in conjunction with extension functions. |
String |
ToString() Convert the atomic value to a string |
QName |
GetTypeName(Processor processor) Get the name of the value's XDM type |
QName |
GetPrimitiveTypeName() Get the name of the primitive type of the value |
Constructor Detail |
---|
public XdmAtomicValue(long i)
Construct an atomic value of type xs:integer
i
-
public XdmAtomicValue(decimal d)
Construct an atomic value of type xs:decimal
d
-
public XdmAtomicValue(float f)
Construct an atomic value of type xs:float
f
-
public XdmAtomicValue(double d)
Construct an atomic value of type xs:double
d
-
public XdmAtomicValue(bool b)
Construct an atomic value of type xs:boolean
b
-
public XdmAtomicValue(System.Uri u)
Construct an atomic value of type xs:anyURI
u
-
public XdmAtomicValue(QName q)
Construct an atomic value of type xs:QName
q
-
public XdmAtomicValue(string lexicalForm, QName type, Processor processor)
Construct an atomic value of a given built-in or user-defined type
Parameters:lexicalForm
-
type
-
SchemaManager
.
processor
-
Processor
object. This is needed for looking up user-defined
types, and also because some conversions are context-sensitive, for example they depend on the
implicit timezone or the choice of XML 1.0 versus XML 1.1 for validating names.
public XdmAtomicValue()
Property Detail |
---|
public Object Value {get; }
Get the value as a CLI object of the nearest equivalent type.
The return type is as follows:
xs:string - String
xs:integer - Long
xs:decimal - Decimal
xs:double - Double
xs:float - Float
xs:boolean - Bool
xs:QName - QName
xs:anyURI - Uri
xdt:untypedAtomic - String
Other types - currently String, but this may change in the future
Method Detail |
---|
public bool IsAtomic()
Determine whether the item is an atomic value
public XdmAtomicValue wrapExternalObject(object external)
Create an atomic value that wraps an external object. Such values can be used
in conjunction with extension functions. (Synonym of WrapExternalObject
,
retained for backwards compatibility.)
external
-
public XdmAtomicValue WrapExternalObject(object external)
Create an atomic value that wraps an external object. Such values can be used in conjunction with extension functions.
Parameters:external
-
public String ToString()
Convert the atomic value to a string
public QName GetTypeName(Processor processor)
Get the name of the value's XDM type
Parameters:processor
-
Processor
object.
This is needed for access to the NamePool,
which maps the internal form of type names to their external form.
public QName GetPrimitiveTypeName()
Get the name of the primitive type of the value
xdt:untypedAtomic
. For the purposes of this method, xs:integer
is considered
to be a primitive type.