Saxon API for .NET

QName Members

QName overview

Public Static Fields

XDT_UNTYPED_ATOMICQName constant for the name xs:untypedAtomic (for backwards compatibility)
XS_ANYURIQName constant for the name xs:anyURI
XS_BOOLEANQName constant for the name xs:boolean
XS_DECIMALQName constant for the name xs:decimal
XS_DOUBLEQName constant for the name xs:double
XS_FLOATQName constant for the name xs:float
XS_INTEGERQName constant for the name xs:integer
XS_QNAMEQName constant for the name xs:QName
XS_STRINGQName constant for the name xs:string
XS_UNTYPED_ATOMICQName constant for the name xs:untypedAtomic

Public Static Methods

FromClarkName Factory method to construct a QName from a string containing the expanded QName in Clark notation, that is, {uri}local

Public Instance Constructors

QNameOverloaded. Initializes a new instance of the QName class.

Public Instance Properties

ClarkNameThe expanded name, as a string using the notation devised by James Clark. If the name is in a namespace, the resulting string takes the form {uri}local. Otherwise, the value is the local part of the name.
LocalNameThe local part of the QName
PrefixThe prefix of the QName. This plays no role in operations such as comparison of QNames for equality, but is retained (as specified in XPath) so that a string representation can be reconstructed.
UriThe namespace URI of the QName. Returns "" (the zero-length string) if the QName is not in a namespace.

Public Instance Methods

Equals Test whether two QNames are equal. This supports the semantics of equality, which considers only the namespace URI and local name, and not the prefix.
GetHashCode Get a hash code for the QName, to support equality matching. This supports the semantics of equality, which considers only the namespace URI and local name, and not the prefix.
GetType (inherited from Object)Gets the Type of the current instance.
IsValid Validate the QName against the XML 1.0 or XML 1.1 rules for valid names.
Register Register a QName with the Processor. This makes comparison faster when the QName is compared with others that are also registered with the Processor.
ToString Convert the value to a string. The resulting string is the lexical form of the QName, using the original prefix if there was one.
ToXmlQualifiedName Convert the value to an XmlQualifiedName (as defined in the System.Xml package)

Protected Instance Methods

Finalize (inherited from Object)Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
MemberwiseClone (inherited from Object)Creates a shallow copy of the current Object.

See Also

QName Class | Saxon.Api Namespace