Early Preview

This is currently very much a preview. Please feel free to try things out, but don't be upset if anything is not yet working. Feedback is welcome over on our GitHub Dicussions page.

class System.​Xml.​Schema.​XmlSchemaDatatype

Assembly: System.Xml.ReaderWriter

Inheritance: object → XmlSchemaDatatype

The <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> class is an abstract class for mapping XML Schema definition language (XSD) types to Common Language Runtime (CLR) types.

Properties

TokenizedType
When overridden in a derived class, gets the type for the <see langword="string" /> as specified in the World Wide Web Consortium (W3C) XML 1.0 specification.
public XmlTypeCode
TypeCode
Gets the <see cref="T:System.Xml.Schema.XmlTypeCode" /> value for the simple type.
public Type
ValueType
When overridden in a derived class, gets the Common Language Runtime (CLR) type of the item.
Variety
Gets the <see cref="T:System.Xml.Schema.XmlSchemaDatatypeVariety" /> value for the simple type.

Methods

public object
ChangeType​(object value, Type targetType)
Converts the value specified, whose type is one of the valid Common Language Runtime (CLR) representations of the XML schema type represented by the <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> , to the CLR type specified.
Returns The converted input value.
value The input value to convert to the specified type.
targetType The target type to convert the input value to.
public object
ChangeType​(object value, Type targetType, IXmlNamespaceResolver namespaceResolver)
Converts the value specified, whose type is one of the valid Common Language Runtime (CLR) representations of the XML schema type represented by the <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> , to the CLR type specified using the <see cref="T:System.Xml.IXmlNamespaceResolver" /> if the <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> represents the xs:QName type or a type derived from it.
Returns The converted input value.
value The input value to convert to the specified type.
targetType The target type to convert the input value to.
namespaceResolver An <see cref="T:System.Xml.IXmlNamespaceResolver" /> used for resolving namespace prefixes. This is only of use if the <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> represents the xs:QName type or a type derived from it.
public bool
IsDerivedFrom​(XmlSchemaDatatype datatype)
The <see cref="M:System.Xml.Schema.XmlSchemaDatatype.IsDerivedFrom(System.Xml.Schema.XmlSchemaDatatype)" /> method always returns <see langword="false" /> .
Returns Always returns <see langword="false" /> .
datatype The <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> .
public object
ParseValue​(string s, XmlNameTable? nameTable, IXmlNamespaceResolver? nsmgr)
When overridden in a derived class, validates the <see langword="string" /> specified against a built-in or user-defined simple type.
Returns An <see cref="T:System.Object" /> that can be cast safely to the type returned by the <see cref="P:System.Xml.Schema.XmlSchemaDatatype.ValueType" /> property.
s The <see langword="string" /> to validate against the simple type.
nameTable The <see cref="T:System.Xml.XmlNameTable" /> to use for atomization while parsing the <see langword="string" /> if this <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> object represents the xs:NCName type.
nsmgr The <see cref="T:System.Xml.IXmlNamespaceResolver" /> object to use while parsing the <see langword="string" /> if this <see cref="T:System.Xml.Schema.XmlSchemaDatatype" /> object represents the xs:QName type.
public bool
Equals​(object obj)
Inherited from object
protected void
Finalize​()
Inherited from object
public int
GetHashCode​()
Inherited from object
public Type
GetType​()
Inherited from object
protected object
MemberwiseClone​()
Inherited from object
public string
ToString​()
Inherited from object