Represents a reader that provides fast, noncached, forward-only access to XML data. More...
Inherits System::IDisposable.
Inherited by System::Xml::XmlNodeReader, System::Xml::XmlTextReader, and System::Xml::XmlValidatingReader.
Public Types | |
using | Ptr = SharedPtr< XmlReader > |
An alias for shared pointer to an instance of this class. More... | |
Public Types inherited from System::Object | |
typedef SmartPtr< Object > | ptr |
Alias for smart pointer type. More... | |
Public Member Functions | |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlReaderSettings > | get_Settings () |
virtual ASPOSECPP_SHARED_API XmlNodeType | get_NodeType ()=0 |
virtual ASPOSECPP_SHARED_API String | get_Name () |
virtual ASPOSECPP_SHARED_API String | get_LocalName ()=0 |
virtual ASPOSECPP_SHARED_API String | get_NamespaceURI ()=0 |
virtual ASPOSECPP_SHARED_API String | get_Prefix ()=0 |
virtual ASPOSECPP_SHARED_API bool | get_HasValue () |
virtual ASPOSECPP_SHARED_API String | get_Value ()=0 |
virtual ASPOSECPP_SHARED_API int32_t | get_Depth ()=0 |
virtual ASPOSECPP_SHARED_API String | get_BaseURI ()=0 |
virtual ASPOSECPP_SHARED_API bool | get_IsEmptyElement ()=0 |
virtual ASPOSECPP_SHARED_API bool | get_IsDefault () |
virtual ASPOSECPP_SHARED_API char16_t | get_QuoteChar () |
virtual ASPOSECPP_SHARED_API System::Xml::XmlSpace | get_XmlSpace () |
virtual ASPOSECPP_SHARED_API String | get_XmlLang () |
virtual ASPOSECPP_SHARED_API SharedPtr< Schema::IXmlSchemaInfo > | get_SchemaInfo () |
virtual ASPOSECPP_SHARED_API TypeInfo | get_ValueType () |
virtual ASPOSECPP_SHARED_API int32_t | get_AttributeCount ()=0 |
virtual ASPOSECPP_SHARED_API bool | get_EOF ()=0 |
virtual ASPOSECPP_SHARED_API System::Xml::ReadState | get_ReadState ()=0 |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNameTable > | get_NameTable ()=0 |
virtual ASPOSECPP_SHARED_API bool | get_CanResolveEntity () |
virtual ASPOSECPP_SHARED_API bool | get_CanReadBinaryContent () |
virtual ASPOSECPP_SHARED_API bool | get_CanReadValueChunk () |
virtual ASPOSECPP_SHARED_API bool | get_HasAttributes () |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadContentAsObject () |
virtual ASPOSECPP_SHARED_API bool | ReadContentAsBoolean () |
virtual ASPOSECPP_SHARED_API DateTime | ReadContentAsDateTime () |
virtual ASPOSECPP_SHARED_API DateTimeOffset | ReadContentAsDateTimeOffset () |
virtual ASPOSECPP_SHARED_API double | ReadContentAsDouble () |
virtual ASPOSECPP_SHARED_API float | ReadContentAsFloat () |
virtual ASPOSECPP_SHARED_API Decimal | ReadContentAsDecimal () |
virtual ASPOSECPP_SHARED_API int32_t | ReadContentAsInt () |
virtual ASPOSECPP_SHARED_API int64_t | ReadContentAsLong () |
virtual ASPOSECPP_SHARED_API String | ReadContentAsString () |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadContentAs (const TypeInfo &returnType, SharedPtr< IXmlNamespaceResolver > namespaceResolver) |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadElementContentAsObject () |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadElementContentAsObject (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API bool | ReadElementContentAsBoolean () |
virtual ASPOSECPP_SHARED_API bool | ReadElementContentAsBoolean (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API DateTime | ReadElementContentAsDateTime () |
virtual ASPOSECPP_SHARED_API DateTime | ReadElementContentAsDateTime (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API double | ReadElementContentAsDouble () |
virtual ASPOSECPP_SHARED_API double | ReadElementContentAsDouble (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API float | ReadElementContentAsFloat () |
virtual ASPOSECPP_SHARED_API float | ReadElementContentAsFloat (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API Decimal | ReadElementContentAsDecimal () |
virtual ASPOSECPP_SHARED_API Decimal | ReadElementContentAsDecimal (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API int32_t | ReadElementContentAsInt () |
virtual ASPOSECPP_SHARED_API int32_t | ReadElementContentAsInt (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API int64_t | ReadElementContentAsLong () |
virtual ASPOSECPP_SHARED_API int64_t | ReadElementContentAsLong (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API String | ReadElementContentAsString () |
virtual ASPOSECPP_SHARED_API String | ReadElementContentAsString (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadElementContentAs (const TypeInfo &returnType, SharedPtr< IXmlNamespaceResolver > namespaceResolver) |
virtual ASPOSECPP_SHARED_API SharedPtr< Object > | ReadElementContentAs (const TypeInfo &returnType, SharedPtr< IXmlNamespaceResolver > namespaceResolver, String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API String | GetAttribute (String name)=0 |
virtual ASPOSECPP_SHARED_API String | GetAttribute (String name, String namespaceURI)=0 |
virtual ASPOSECPP_SHARED_API String | GetAttribute (int32_t i)=0 |
virtual ASPOSECPP_SHARED_API String | idx_get (int32_t i) |
virtual ASPOSECPP_SHARED_API String | idx_get (String name) |
virtual ASPOSECPP_SHARED_API String | idx_get (String name, String namespaceURI) |
virtual ASPOSECPP_SHARED_API bool | MoveToAttribute (String name)=0 |
virtual ASPOSECPP_SHARED_API bool | MoveToAttribute (String name, String ns)=0 |
virtual ASPOSECPP_SHARED_API void | MoveToAttribute (int32_t i) |
virtual ASPOSECPP_SHARED_API bool | MoveToFirstAttribute ()=0 |
virtual ASPOSECPP_SHARED_API bool | MoveToNextAttribute ()=0 |
virtual ASPOSECPP_SHARED_API bool | MoveToElement ()=0 |
virtual ASPOSECPP_SHARED_API bool | ReadAttributeValue ()=0 |
virtual ASPOSECPP_SHARED_API bool | Read ()=0 |
virtual ASPOSECPP_SHARED_API void | Close () |
When overridden in a derived class, changes the XmlReader::get_ReadState to ReadState::Closed. More... | |
virtual ASPOSECPP_SHARED_API void | Skip () |
Skips the children of the current node. More... | |
virtual ASPOSECPP_SHARED_API String | LookupNamespace (const String &prefix)=0 |
virtual ASPOSECPP_SHARED_API void | ResolveEntity ()=0 |
virtual ASPOSECPP_SHARED_API int32_t | ReadContentAsBase64 (ArrayPtr< uint8_t > buffer, int32_t index, int32_t count) |
virtual ASPOSECPP_SHARED_API int32_t | ReadElementContentAsBase64 (ArrayPtr< uint8_t > buffer, int32_t index, int32_t count) |
virtual ASPOSECPP_SHARED_API int32_t | ReadContentAsBinHex (ArrayPtr< uint8_t > buffer, int32_t index, int32_t count) |
virtual ASPOSECPP_SHARED_API int32_t | ReadElementContentAsBinHex (ArrayPtr< uint8_t > buffer, int32_t index, int32_t count) |
virtual ASPOSECPP_SHARED_API int32_t | ReadValueChunk (ArrayPtr< char16_t > buffer, int32_t index, int32_t count) |
virtual ASPOSECPP_SHARED_API String | ReadString () |
virtual ASPOSECPP_SHARED_API XmlNodeType | MoveToContent () |
virtual ASPOSECPP_SHARED_API void | ReadStartElement () |
virtual ASPOSECPP_SHARED_API void | ReadStartElement (String name) |
virtual ASPOSECPP_SHARED_API void | ReadStartElement (String localname, String ns) |
virtual ASPOSECPP_SHARED_API String | ReadElementString () |
virtual ASPOSECPP_SHARED_API String | ReadElementString (String name) |
virtual ASPOSECPP_SHARED_API String | ReadElementString (String localname, String ns) |
virtual ASPOSECPP_SHARED_API void | ReadEndElement () |
virtual ASPOSECPP_SHARED_API bool | IsStartElement () |
virtual ASPOSECPP_SHARED_API bool | IsStartElement (String name) |
virtual ASPOSECPP_SHARED_API bool | IsStartElement (String localname, String ns) |
virtual ASPOSECPP_SHARED_API bool | ReadToFollowing (String name) |
virtual ASPOSECPP_SHARED_API bool | ReadToFollowing (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API bool | ReadToDescendant (String name) |
virtual ASPOSECPP_SHARED_API bool | ReadToDescendant (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API bool | ReadToNextSibling (String name) |
virtual ASPOSECPP_SHARED_API bool | ReadToNextSibling (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API String | ReadInnerXml () |
virtual ASPOSECPP_SHARED_API String | ReadOuterXml () |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlReader > | ReadSubtree () |
ASPOSECPP_SHARED_API void | Dispose () override |
Releases all resources used by the current instance of the XmlReader class. More... | |
Public Member Functions inherited from System::Object | |
ASPOSECPP_SHARED_API | Object () |
Creates object. Initializes all internal data structures. More... | |
virtual ASPOSECPP_SHARED_API | ~Object () |
Destroys object. Frees all internal data structures. More... | |
ASPOSECPP_SHARED_API | Object (Object const &x) |
Copy constructor. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More... | |
Object & | operator= (Object const &x) |
Assignment operator. Doesn't copy anything, really, just initializes new object and enables copy constructing subclasses. More... | |
Object * | SharedRefAdded () |
Increments shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
int | SharedRefRemovedSafe () |
Decrements and returns shared reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
int | RemovedSharedRefs (int count) |
Decreases shared reference count by specified value. More... | |
Detail::SmartPtrCounter * | WeakRefAdded () |
Increments weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
void | WeakRefRemoved () |
Decrements weak reference count. Shouldn't be called directly; instead, use smart pointers or ThisProtector. More... | |
Detail::SmartPtrCounter * | GetCounter () |
Gets reference counter data structure associated with the object. More... | |
int | SharedCount () const |
Gets current value of shared reference counter. More... | |
ASPOSECPP_SHARED_API void | Lock () |
Implements C# lock() statement locking. Call directly or use LockContext sentry object. More... | |
ASPOSECPP_SHARED_API void | Unlock () |
Implements C# lock() statement unlocking. Call directly or use LockContext sentry object. More... | |
virtual ASPOSECPP_SHARED_API bool | Equals (ptr obj) |
Compares objects using C# Object.Equals semantics. More... | |
virtual ASPOSECPP_SHARED_API int32_t | GetHashCode () const |
Analog of C# Object.GetHashCode() method. Enables hashing of custom objects. More... | |
virtual ASPOSECPP_SHARED_API String | ToString () const |
Analog of C# Object.ToString() method. Enables converting custom objects to string. More... | |
virtual ASPOSECPP_SHARED_API ptr | MemberwiseClone () const |
Analog of C# Object.MemberwiseClone() method. Enables cloning custom types. More... | |
virtual ASPOSECPP_SHARED_API const TypeInfo & | GetType () const |
Gets actual type of object. Analog of C# System.Object.GetType() call. More... | |
virtual ASPOSECPP_SHARED_API bool | Is (const TypeInfo &targetType) const |
Check if object represents an instance of type described by targetType. Analog of C# 'is' operator. More... | |
virtual ASPOSECPP_SHARED_API void | SetTemplateWeakPtr (uint32_t argument) |
Set n'th template argument a weak pointer (rather than shared). Allows switching pointers in containers to weak mode. More... | |
virtual ASPOSECPP_SHARED_API bool | FastCast (const Details::FastRttiBase &helper, void **out_ptr) const |
For internal purposes only. More... | |
template<> | |
bool | Equals (float const &objA, float const &objB) |
template<> | |
bool | Equals (double const &objA, double const &objB) |
template<> | |
bool | ReferenceEquals (String const &str, std::nullptr_t) |
template<> | |
bool | ReferenceEquals (String const &str1, String const &str2) |
Static Public Member Functions | |
static ASPOSECPP_SHARED_API bool | IsName (const String &str) |
static ASPOSECPP_SHARED_API bool | IsNameToken (const String &str) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const String &inputUri) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const String &inputUri, const SharedPtr< XmlReaderSettings > &settings) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const String &inputUri, SharedPtr< XmlReaderSettings > settings, const SharedPtr< XmlParserContext > &inputContext) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::Stream > &input) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::Stream > &input, const SharedPtr< XmlReaderSettings > &settings) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::Stream > &input, SharedPtr< XmlReaderSettings > settings, const String &baseUri) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::Stream > &input, SharedPtr< XmlReaderSettings > settings, const SharedPtr< XmlParserContext > &inputContext) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::TextReader > &input) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::TextReader > &input, const SharedPtr< XmlReaderSettings > &settings) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::TextReader > &input, SharedPtr< XmlReaderSettings > settings, const String &baseUri) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< IO::TextReader > &input, SharedPtr< XmlReaderSettings > settings, const SharedPtr< XmlParserContext > &inputContext) |
static ASPOSECPP_SHARED_API SharedPtr< XmlReader > | Create (const SharedPtr< XmlReader > &reader, SharedPtr< XmlReaderSettings > settings) |
Static Public Member Functions inherited from System::Object | |
static bool | ReferenceEquals (ptr const &objA, ptr const &objB) |
Compares objects by reference. More... | |
template<typename T > | |
static std::enable_if<!IsSmartPtr< T >::value, bool >::type | ReferenceEquals (T const &objA, T const &objB) |
Compares objects by reference. More... | |
template<typename T > | |
static std::enable_if<!IsSmartPtr< T >::value, bool >::type | ReferenceEquals (T const &objA, std::nullptr_t) |
Reference-compares value type object with nullptr. More... | |
template<typename T1 , typename T2 > | |
static std::enable_if< IsSmartPtr< T1 >::value &&IsSmartPtr< T2 >::value, bool >::type | Equals (T1 const &objA, T2 const &objB) |
Compares reference type objects in C# style. More... | |
template<typename T1 , typename T2 > | |
static std::enable_if<!IsSmartPtr< T1 >::value &&!IsSmartPtr< T2 >::value, bool >::type | Equals (T1 const &objA, T2 const &objB) |
Compares value type objects in C# style. More... | |
static const TypeInfo & | Type () |
Implements C# typeof(System.Object) construct. More... | |
Represents a reader that provides fast, noncached, forward-only access to XML data.
An alias for shared pointer to an instance of this class.
|
virtual |
When overridden in a derived class, changes the XmlReader::get_ReadState to ReadState::Closed.
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
static |
Creates a new XmlReader instance with specified URI.
inputUri | The URI for the file that contains the XML data. The XmlUrlResolver class is used to convert the path to a canonical data representation. |
ArgumentNullException | The inputUri value is nullptr . |
SecurityException | The XmlReader does not have sufficient permissions to access the location of the XML data. |
FileNotFoundException | The file identified by the URI does not exist. |
UriFormatException | The URI format is not correct. |
|
static |
Creates a new XmlReader instance by using the specified URI and settings.
inputUri | The URI for the file containing the XML data. The XmlResolver object on the XmlReaderSettings object is used to convert the path to a canonical data representation. If XmlReaderSettings::get_XmlResolver value is nullptr , a new XmlUrlResolver object is used. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
ArgumentNullException | The inputUri value is nullptr . |
FileNotFoundException | The file specified by the URI cannot be found. |
UriFormatException | The URI format is not correct. |
|
static |
Creates a new XmlReader instance by using the specified URI, settings, and context information for parsing.
inputUri | The URI for the file containing the XML data. The XmlResolver object on the XmlReaderSettings object is used to convert the path to a canonical data representation. If XmlReaderSettings::get_XmlResolver value is nullptr , a new XmlUrlResolver object is used. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
inputContext | The context information required to parse the XML fragment. The context information can include the XmlNameTable to use, encoding, namespace scope, the current xml:lang and xml:space scope, base URI, and document type definition. This value can be nullptr . |
ArgumentNullException | The inputUri value is nullptr . |
SecurityException | The XmlReader does not have sufficient permissions to access the location of the XML data. |
ArgumentException | The XmlReaderSettings::get_NameTable and XmlParserContext::get_NameTable both are non-nullptr values. (Only one of these NameTable values can be set and used). |
FileNotFoundException | The file specified by the URI cannot be found. |
UriFormatException | The URI format is not correct. |
|
static |
Creates a new XmlReader instance using the specified stream with default settings.
input | The stream that contains the XML data. The XmlReader scans the first bytes of the stream looking for a byte order mark or other sign of encoding. When encoding is determined, the encoding is used to continue reading the stream, and processing continues parsing the input as a stream of (Unicode) characters. |
ArgumentNullException | The input value is nullptr . |
SecurityException | The XmlReader does not have sufficient permissions to access the location of the XML data. |
|
static |
Creates a new XmlReader instance with the specified stream and settings.
input | The stream that contains the XML data. The XmlReader scans the first bytes of the stream looking for a byte order mark or other sign of encoding. When encoding is determined, the encoding is used to continue reading the stream, and processing continues parsing the input as a stream of (Unicode) characters. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance using the specified stream, base URI, and settings.
input | The stream that contains the XML data. The XmlReader scans the first bytes of the stream looking for a byte order mark or other sign of encoding. When encoding is determined, the encoding is used to continue reading the stream, and processing continues parsing the input as a stream of (Unicode) characters. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
baseUri | The base URI for the entity or document being read. This value can be nullptr . Security Note The base URI is used to resolve the relative URI of the XML document. Do not use a base URI from an untrusted source. |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance using the specified stream, settings, and context information for parsing.
input | The stream that contains the XML data. The XmlReader scans the first bytes of the stream looking for a byte order mark or other sign of encoding. When encoding is determined, the encoding is used to continue reading the stream, and processing continues parsing the input as a stream of (Unicode) characters. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
inputContext | The context information required to parse the XML fragment. The context information can include the XmlNameTable to use, encoding, namespace scope, the current xml:lang and xml:space scope, base URI, and document type definition. This value can be nullptr . |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance by using the specified text reader.
input | The text reader from which to read the XML data. A text reader returns a stream of Unicode characters, so the encoding specified in the XML declaration is not used by the XML reader to decode the data stream. |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance by using the specified text reader and settings.
input | The text reader from which to read the XML data. A text reader returns a stream of Unicode characters, so the encoding specified in the XML declaration isn't used by the XML reader to decode the data stream. |
settings | The settings for the new XmlReader. This value can be nullptr . |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance by using the specified text reader, settings, and base URI.
input | The text reader from which to read the XML data. A text reader returns a stream of Unicode characters, so the encoding specified in the XML declaration isn't used by the XmlReader to decode the data stream. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
baseUri | The base URI for the entity or document being read. This value can be nullptr . Security Note The base URI is used to resolve the relative URI of the XML document. Do not use a base URI from an untrusted source. |
ArgumentNullException | The input value is nullptr . |
|
static |
Creates a new XmlReader instance by using the specified text reader, settings, and context information for parsing.
input | The text reader from which to read the XML data. A text reader returns a stream of Unicode characters, so the encoding specified in the XML declaration isn't used by the XML reader to decode the data stream. |
settings | The settings for the new XmlReader instance. This value can be nullptr . |
inputContext | The context information required to parse the XML fragment. The context information can include the XmlNameTable to use, encoding, namespace scope, the current xml:lang and xml:space scope, base URI, and document type definition. This value can be nullptr . |
ArgumentNullException | The input value is nullptr . |
ArgumentException | The XmlReaderSettings::get_NameTable and XmlParserContext::get_NameTable both are non-nullptr values. (Only one of these NameTable values can be set and used). |
|
static |
Creates a new XmlReader instance by using the specified XML reader and settings.
reader | The object that you want to use as the underlying XML reader. |
settings | The settings for the new XmlReader instance. The conformance level of the XmlReaderSettings object must either match the conformance level of the underlying reader, or it must be set to ConformanceLevel::Auto. |
ArgumentNullException | The reader value is nullptr . |
InvalidOperationException | If the XmlReaderSettings object specifies a conformance level that is not consistent with conformance level of the underlying reader. The underlying XmlReader is in an ReadState::Error or ReadState::Closed state. |
|
overridevirtual |
Releases all resources used by the current instance of the XmlReader class.
Reimplemented from System::IDisposable.
|
pure virtual |
When overridden in a derived class, gets the number of attributes on the current node.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the base URI of the current node.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Returns a value indicating whether the XmlReader implements the binary content read methods.
true
if the binary content read methods are implemented; otherwise false
. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Returns a value indicating whether the XmlReader implements the XmlReader::ReadValueChunk method.
true
if the XmlReader implements the XmlReader::ReadValueChunk method; otherwise false
. Reimplemented in System::Xml::XmlTextReader.
|
virtual |
Returns a value indicating whether this reader can parse and resolve entities.
true
if the reader can parse and resolve entities; otherwise, false
. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the depth of the current node in the XML document.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets a value indicating whether the reader is positioned at the end of the stream.
true
if the reader is positioned at the end of the stream; otherwise, false
. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Returns a value indicating whether the current node has any attributes.
true
if the current node has attributes; otherwise, false
. Reimplemented in System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets a value indicating whether the current node can have a XmlReader::get_Value value.
true
if the node on which the reader is currently positioned can have a Value
; otherwise, false
. If false
, the node has a value of String::Empty. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets a value indicating whether the current node is an attribute that was generated from the default value defined in the DTD or schema.
true
if the current node is an attribute whose value was generated from the default value defined in the DTD or schema; false
if the attribute value was explicitly set. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets a value indicating whether the current node is an empty element (for example, <MyElement/>
).
true
if the current node is an element (XmlReader::get_NodeType equals XmlNodeType::Element) that ends with />
; otherwise, false
. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the local name of the current node.
LocalName
is book
for the element <bk:book>
. For node types that do not have a name (like Text
, Comment
, and so on), this method returns String::Empty. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets the qualified name of the current node.
Name
is bk:book
for the element <bk:book>
.The name returned is dependent on the XmlReader::get_NodeType value of the node. The following node types return the listed values. All other node types return an empty string.
Node type | Name |
---|---|
Attribute | The name of the attribute. |
DocumentType | The document type name. |
Element | The tag name. |
EntityReference | The name of the entity referenced. |
ProcessingInstruction | The target of the processing instruction. |
XmlDeclaration | The literal string xml . |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the namespace URI (as defined in the W3C Namespace specification) of the node on which the reader is positioned.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the XmlNameTable associated with this implementation.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the type of the current node.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the namespace prefix associated with the current node.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets the quotation mark character used to enclose the value of an attribute node.
Reimplemented in System::Xml::XmlTextReader, and System::Xml::XmlValidatingReader.
|
pure virtual |
When overridden in a derived class, gets the state of the reader.
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Returns the schema information that has been assigned to the current node as a result of schema validation.
nullptr
. If this method is called from an XmlTextReader or an XmlValidatingReader object, this method always returns nullptr
. These XmlReader implementations do not expose schema information through the get_SchemaInfo method. Reimplemented in System::Xml::XmlNodeReader.
|
virtual |
Returns the XmlReaderSettings object used to create this XmlReader instance.
nullptr
.
|
pure virtual |
When overridden in a derived class, gets the text value of the current node.
The following table lists node types that have a value to return. All other node types return String::Empty.
Node type | Value |
---|---|
Attribute | The value of the attribute. |
CDATA | The content of the CDATA section. |
Comment | The content of the comment. |
DocumentType | The internal subset. |
ProcessingInstruction | The entire content, excluding the target. |
SignificantWhitespace | The white space between markup in a mixed content model. |
Text | The content of the text node. |
Whitespace | The white space between markup. |
XmlDeclaration | The content of the declaration. |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Returns The type for the current node.
|
virtual |
When overridden in a derived class, gets the current xml:lang
scope.
xml:lang
scope. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets the current xml:space
scope.
xml:space
scope exists, this value defaults to XmlSpace::None. Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the value of the attribute with the specified XmlReader::get_Name value.
name | The qualified name of the attribute. |
nullptr
is returned. ArgumentNullException | name is nullptr . |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the value of the attribute with the specified XmlReader::get_LocalName and XmlReader::get_NamespaceURI values.
name | The local name of the attribute. |
namespaceURI | The namespace URI of the attribute. |
nullptr
is returned. This method does not move the reader. ArgumentNullException | name is nullptr . |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, gets the value of the attribute with the specified index.
i | The index of the attribute. The index is zero-based. (The first attribute has index 0.) |
ArgumentOutOfRangeException | i is out of range. It must be non-negative and less than the size of the attribute collection. |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, gets the value of the attribute with the specified index.
i | The index of the attribute. |
When overridden in a derived class, gets the value of the attribute with the specified XmlReader::get_Name value.
name | The qualified name of the attribute. |
nullptr
is returned.
|
virtual |
When overridden in a derived class, gets the value of the attribute with the specified XmlReader::get_LocalName and XmlReader::get_NamespaceURI values.
name | The local name of the attribute. |
namespaceURI | The namespace URI of the attribute. |
nullptr
is returned.
|
static |
Returns a value indicating whether the string argument is a valid XML name.
str | The name to validate. |
true
if the name is valid; otherwise, false
. ArgumentNullException | The str value is nullptr . |
|
static |
Returns a value indicating whether or not the string argument is a valid XML name token.
str | The name token to validate. |
true
if it is a valid name token; otherwise false
. ArgumentNullException | The str value is nullptr . |
|
virtual |
Calls XmlReader::MoveToContent and tests if the current content node is a start tag or empty element tag.
true
if XmlReader::MoveToContent finds a start tag or empty element tag; false
if a node type other than XmlNodeType::Element was found. XmlException | Incorrect XML is encountered in the input stream. |
|
virtual |
Calls XmlReader::MoveToContent and tests if the current content node is a start tag or empty element tag and if the XmlReader::get_Name value of the element found matches the given argument.
name | The string matched against the Name value of the element found. |
true
if the resulting node is an element and the Name
value matches the specified string. false
if a node type other than XmlNodeType::Element was found or if the element Name
value does not match the specified string. XmlException | Incorrect XML is encountered in the input stream. |
|
virtual |
Calls XmlReader::MoveToContent and tests if the current content node is a start tag or empty element tag and if the XmlReader::get_LocalName and XmlReader::get_NamespaceURI values of the element found match the given strings.
localname | The string to match against the LocalName value of the element found. |
ns | The string to match against the NamespaceURI value of the element found. |
true
if the resulting node is an element. false
if a node type other than XmlNodeType::Element was found or if the LocalName
and NamespaceURI
values of the element do not match the specified strings. XmlException | Incorrect XML is encountered in the input stream. |
|
pure virtual |
When overridden in a derived class, resolves a namespace prefix in the current element's scope.
prefix | The prefix whose namespace URI you want to resolve. To match the default namespace, pass an empty string. |
nullptr
if no matching prefix is found. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, moves to the attribute with the specified XmlReader::get_Name value.
name | The qualified name of the attribute. |
true
if the attribute is found; otherwise, false
. If false
, the reader's position does not change. ArgumentException | The parameter is an empty string. |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, moves to the attribute with the specified XmlReader::get_LocalName and XmlReader::get_NamespaceURI values.
name | The local name of the attribute. |
ns | The namespace URI of the attribute. |
true
if the attribute is found; otherwise, false
. If false
, the reader's position does not change. ArgumentNullException | Both parameter values are nullptr . |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
When overridden in a derived class, moves to the attribute with the specified index.
i | The index of the attribute. |
ArgumentOutOfRangeException | The parameter has a negative value. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Checks whether the current node is a content (non-white space text, CDATA
, Element
, EndElement
, EntityReference
, or EndEntity
) node. If the node is not a content node, the reader skips ahead to the next content node or end of file. It skips over nodes of the following type: ProcessingInstruction
, DocumentType
, Comment
, Whitespace
, or SignificantWhitespace
.
XmlException | Incorrect XML encountered in the input stream. |
|
pure virtual |
When overridden in a derived class, moves to the element that contains the current attribute node.
true
if the reader is positioned on an attribute (the reader moves to the element that owns the attribute); false
if the reader is not positioned on an attribute (the position of the reader does not change). Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, moves to the first attribute.
true
if an attribute exists (the reader moves to the first attribute); otherwise, false
(the position of the reader does not change). Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, moves to the next attribute.
true
if there is a next attribute; false
if there are no more attributes. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, reads the next node from the stream.
true
if the next node was read successfully; otherwise, false
. XmlException | An error occurred while parsing the XML. |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
pure virtual |
When overridden in a derived class, parses the attribute value into one or more Text
, EntityReference
, or EndEntity
nodes.
true
if there are nodes to return. false
if the reader is not positioned on an attribute node when the initial call is made or if all the attribute values have been read. An empty attribute, such as, misc=""
, returns true
with a single node with a value of String::Empty. Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Reads the content as an object of the type specified.
returnType | The type of the value to be returned. |
namespaceResolver | An IXmlNamespaceResolver object that is used to resolve any namespace prefixes related to type conversion. For example, this can be used when converting an XmlQualifiedName object to an xs:string . This value can be nullptr . |
FormatException | The content is not in the correct format for the target type. |
InvalidCastException | The attempted cast is not valid. |
ArgumentNullException | The returnType value is nullptr . |
InvalidOperationException | The current node is not a supported node type. |
OverflowException | Read Decimal::MaxValue. |
|
virtual |
Reads the content and returns the Base64 decoded binary bytes.
buffer | The buffer into which to copy the resulting text. This value cannot be nullptr . |
index | The offset into the buffer where to start copying the result. |
count | The maximum number of bytes to copy into the buffer. The actual number of bytes copied is returned from this method. |
ArgumentNullException | The buffer value is nullptr . |
InvalidOperationException | The call is not supported on the current node. |
ArgumentOutOfRangeException | The index into the buffer or index + count is larger than the allocated buffer size. |
NotSupportedException | The XmlReader implementation does not support this method. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Reads the content and returns the BinHex
decoded binary bytes.
buffer | The buffer into which to copy the resulting text. This value cannot be nullptr . |
index | The offset into the buffer where to start copying the result. |
count | The maximum number of bytes to copy into the buffer. The actual number of bytes copied is returned from this method. |
ArgumentNullException | The buffer value is nullptr . |
InvalidOperationException | The call is not supported on the current node. |
ArgumentOutOfRangeException | The index into the buffer or index + count is larger than the allocated buffer size. |
NotSupportedException | The XmlReader implementation does not support this method. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
|
virtual |
|
virtual |
Reads the text content at the current position as a DateTimeOffset object.
|
virtual |
|
virtual |
Reads the text content at the current position as a double-precision floating-point number.
InvalidCastException | The attempted cast is not valid. |
FormatException | The string format is not valid. |
|
virtual |
Reads the text content at the current position as a single-precision floating point number.
InvalidCastException | The attempted cast is not valid. |
FormatException | The string format is not valid. |
|
virtual |
Reads the text content at the current position as a 32-bit signed integer.
InvalidCastException | The attempted cast is not valid. |
FormatException | The string format is not valid. |
|
virtual |
Reads the text content at the current position as a 64-bit signed integer.
InvalidCastException | The attempted cast is not valid. |
FormatException | The string format is not valid. |
|
virtual |
Reads the text content at the current position as an Object.
InvalidCastException | The attempted cast is not valid. |
FormatException | The string format is not valid. |
|
virtual |
|
virtual |
Reads the element content as the requested type.
returnType | The type of the value to be returned. |
namespaceResolver | An IXmlNamespaceResolver object that is used to resolve any namespace prefixes related to type conversion. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
OverflowException | Read Decimal::MaxValue. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the element content as the requested type.
returnType | The type of the value to be returned. |
namespaceResolver | An IXmlNamespaceResolver object that is used to resolve any namespace prefixes related to type conversion. |
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
OverflowException | Read Decimal::MaxValue. |
|
virtual |
Reads the element and decodes the Base64
content.
buffer | The buffer into which to copy the resulting text. This value cannot be nullptr . |
index | The offset into the buffer where to start copying the result. |
count | The maximum number of bytes to copy into the buffer. The actual number of bytes copied is returned from this method. |
ArgumentNullException | The buffer value is nullptr . |
InvalidOperationException | The current node is not an element node. |
ArgumentOutOfRangeException | The index into the buffer or index + count is larger than the allocated buffer size. |
NotSupportedException | The XmlReader implementation does not support this method. |
XmlException | The element contains mixed-content. |
FormatException | The content cannot be converted to the requested type. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Reads the element and decodes the BinHex
content.
buffer | The buffer into which to copy the resulting text. This value cannot be nullptr . |
index | The offset into the buffer where to start copying the result. |
count | The maximum number of bytes to copy into the buffer. The actual number of bytes copied is returned from this method. |
ArgumentNullException | The buffer value is nullptr . |
InvalidOperationException | The current node is not an element node. |
ArgumentOutOfRangeException | The index into the buffer or index + count is larger than the allocated buffer size. |
NotSupportedException | The XmlReader implementation does not support this method. |
XmlException | The element contains mixed-content. |
FormatException | The content cannot be converted to the requested type. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a Boolean object.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a DateTime object.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a Decimal object.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a Decimal. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads the current element and returns the contents as a double-precision floating-point number.
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a double-precision floating-point number. |
ArgumentNullException | The method is called with nullptr arguments. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a double-precision floating-point number.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads the current element and returns the contents as single-precision floating-point number.
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a single-precision floating-point number. |
ArgumentNullException | The method is called with nullptr arguments. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a single-precision floating-point number.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a single-precision floating-point number. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads the current element and returns the contents as a 32-bit signed integer.
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a 32-bit signed integer. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a 32-bit signed integer.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a 32-bit signed integer. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads the current element and returns the contents as a 64-bit signed integer.
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a 64-bit signed integer. |
ArgumentNullException | The method is called with nullptr arguments. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a 64-bit signed integer.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a 64-bit signed integer. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads the current element and returns the contents as an Object.
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type |
ArgumentNullException | The method is called with nullptr arguments. |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as an Object.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to the requested type. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
|
virtual |
Checks that the specified local name and namespace URI matches that of the current element, then reads the current element and returns the contents as a String object.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
InvalidOperationException | The XmlReader is not positioned on an element. |
XmlException | The current element contains child elements. The element content cannot be converted to a String object. |
ArgumentNullException | The method is called with nullptr arguments. |
ArgumentException | The specified local name and namespace URI do not match that of the current element being read. |
|
virtual |
Reads a text-only element. However, it is recommended to use the XmlReader::ReadElementContentAsString method instead, because it provides a more straightforward way to handle this operation.
XmlException | The next content node is not a start tag; or the element found does not contain a simple text value. |
|
virtual |
Checks that the XmlReader::get_Name value of the element found matches the given string before reading a text-only element. However, it is recommended to use the XmlReader::ReadElementContentAsString method instead, because it provides a more straightforward way to handle this operation.
name | The name to check. |
XmlException | If the next content node is not a start tag; if the element Name does not match the given argument; or if the element found does not contain a simple text value. |
|
virtual |
Checks that the XmlReader::get_LocalName and XmlReader::get_NamespaceURI values of the element found matches the given strings before reading a text-only element. However, it is recommended to use the XmlReader::ReadElementContentAsString method instead, because it provides a more straightforward way to handle this operation.
localname | The local name to check. |
ns | The namespace URI to check. |
XmlException | If the next content node is not a start tag; if the element LocalName or NamespaceURI values do not match the given arguments; or if the element found does not contain a simple text value. |
|
virtual |
Checks that the current content node is an end tag and advances the reader to the next node.
XmlException | The current node is not an end tag or if incorrect XML is encountered in the input stream. |
|
virtual |
When overridden in a derived class, reads all the content, including markup, as a string.
XmlException | The XML was not well-formed, or an error occurred while parsing the XML. |
|
virtual |
When overridden in a derived class, reads the content, including markup, representing this node and all its children.
XmlException | The XML was not well-formed, or an error occurred while parsing the XML. |
|
virtual |
Checks that the current node is an element and advances the reader to the next node.
XmlException | Incorrect XML was encountered in the input stream. |
|
virtual |
Checks that the current content node is an element with the given XmlReader::get_Name value and advances the reader to the next node.
name | The qualified name of the element. |
XmlException | Incorrect XML was encountered in the input stream. The XmlReader::get_Name of the element does not match the given name . |
|
virtual |
Checks that the current content node is an element with the given XmlReader::get_LocalName and XmlReader::get_NamespaceURI values and advances the reader to the next node.
localname | The local name of the element. |
ns | The namespace URI of the element. |
XmlException | Incorrect XML was encountered in the input stream. The XmlReader::get_LocalName and XmlReader::get_NamespaceURI values of the element found do not match the given arguments. |
|
virtual |
When overridden in a derived class, reads the contents of an element or text node as a string. However, it is recommended to use the XmlReader::ReadElementContentAsString method instead, because it provides a more straightforward way to handle this operation.
XmlException | An error occurred while parsing the XML. |
Reimplemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
Returns a new XmlReader instance that can be used to read the current node, and all its descendants.
InvalidOperationException | The XML reader isn't positioned on an element when this method is called. |
|
virtual |
Advances the XmlReader to the next descendant element with the specified qualified name.
name | The qualified name of the element you wish to move to. |
true
if a matching descendant element is found; otherwise false
. If a matching child element is not found, the XmlReader is positioned on the end tag (XmlReader::get_NodeType value is XmlNodeType::EndElement) of the element. If the XmlReader is not positioned on an element when XmlReader::ReadToDescendant(String) was called, this method returns false
and the position of the XmlReader is not changed. ArgumentException | The parameter is an empty string. |
|
virtual |
Advances the XmlReader to the next descendant element with the specified local name and namespace URI.
localName | The local name of the element you wish to move to. |
namespaceURI | The namespace URI of the element you wish to move to. |
true
if a matching descendant element is found; otherwise false
. If a matching child element is not found, the XmlReader is positioned on the end tag (XmlReader::get_NodeType value is XmlNodeType::EndElement) of the element. If the XmlReader is not positioned on an element when XmlReader::ReadToDescendant(String,String) was called, this method returns false
and the position of the XmlReader is not changed. ArgumentNullException | Both parameter values are nullptr . |
|
virtual |
Reads until an element with the specified qualified name is found.
name | The qualified name of the element. |
true
if a matching element is found; otherwise false
and the XmlReader is in an end of file state. ArgumentException | The parameter is an empty string. |
|
virtual |
Reads until an element with the specified local name and namespace URI is found.
localName | The local name of the element. |
namespaceURI | The namespace URI of the element. |
true
if a matching element is found; otherwise false
and the XmlReader is in an end of file state. ArgumentNullException | Both parameter values are nullptr . |
|
virtual |
Advances the XmlReader to the next sibling element with the specified qualified name.
name | The qualified name of the sibling element you wish to move to. |
true
if a matching sibling element is found; otherwise false
. If a matching sibling element is not found, the XmlReader is positioned on the end tag (XmlReader::get_NodeType value is XmlNodeType::EndElement) of the parent element. ArgumentException | The parameter is an empty string. |
|
virtual |
Advances the XmlReader to the next sibling element with the specified local name and namespace URI.
localName | The local name of the sibling element you wish to move to. |
namespaceURI | The namespace URI of the sibling element you wish to move to. |
true
if a matching sibling element is found; otherwise, false
. If a matching sibling element is not found, the XmlReader is positioned on the end tag (XmlReader::get_NodeType value is XmlNodeType::EndElement) of the parent element. ArgumentNullException | Both parameter values are nullptr . |
|
virtual |
Reads large streams of text embedded in an XML document.
buffer | The array of characters that serves as the buffer to which the text contents are written. This value cannot be nullptr . |
index | The offset within the buffer where the XmlReader can start to copy the results. |
count | The maximum number of characters to copy into the buffer. The actual number of characters copied is returned from this method. |
InvalidOperationException | The current node does not have a value (XmlReader::get_HasValue is false ). |
ArgumentNullException | The buffer value is nullptr . |
ArgumentOutOfRangeException | The index into the buffer, or index + count is larger than the allocated buffer size. |
NotSupportedException | The XmlReader implementation does not support this method. |
XmlException | The XML data is not well-formed. |
|
pure virtual |
When overridden in a derived class, resolves the entity reference for EntityReference
nodes.
InvalidOperationException | The reader is not positioned on an EntityReference node; this implementation of the reader cannot resolve entities (XmlReader::get_CanResolveEntity returns false ). |
Implemented in System::Xml::XmlTextReader, System::Xml::XmlValidatingReader, and System::Xml::XmlNodeReader.
|
virtual |
Skips the children of the current node.
Reimplemented in System::Xml::XmlTextReader, and System::Xml::XmlNodeReader.