Inherits System::Xml::XmlNode.
Public Types | |
using | Ptr = SharedPtr< XmlDocument > |
An alias for shared pointer to an instance of this class. More... | |
Public Types inherited from System::Xml::XmlNode | |
using | Ptr = SharedPtr< XmlNode > |
An alias for shared pointer to an instance of this class. More... | |
Public Types inherited from System::Collections::Generic::IEnumerable< SharedPtr< System::Xml::XmlNode > > | |
typedef IEnumerator< SharedPtr< System::Xml::XmlNode > > | IEnumeratorType |
Enumerator type. More... | |
using | ValueType = SharedPtr< System::Xml::XmlNode > |
using | iterator = System::Details::VirtualizedIterator< SharedPtr< System::Xml::XmlNode > > |
Iterator type. More... | |
using | const_iterator = System::Details::VirtualizedConstIterator< SharedPtr< System::Xml::XmlNode > > |
Const iterator type. More... | |
using | virtualized_iterator = System::Details::VirtualizedIteratorBase< SharedPtr< System::Xml::XmlNode > > |
Inner iterator base type. More... | |
using | virtualized_iterator_element = SharedPtr< System::Xml::XmlNode > |
Inner iterator element type. More... | |
Public Types inherited from System::Object | |
typedef SmartPtr< Object > | ptr |
Alias for smart pointer type. More... | |
Public Member Functions | |
ASPOSECPP_SHARED_API XmlNodeType | get_NodeType () override |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlDocumentType > | get_DocumentType () |
ASPOSECPP_SHARED_API SharedPtr< XmlImplementation > | get_Implementation () |
ASPOSECPP_SHARED_API String | get_Name () override |
ASPOSECPP_SHARED_API String | get_LocalName () override |
ASPOSECPP_SHARED_API SharedPtr< XmlElement > | get_DocumentElement () |
ASPOSECPP_SHARED_API SharedPtr< XmlDocument > | get_OwnerDocument () override |
ASPOSECPP_SHARED_API SharedPtr< Schema::XmlSchemaSet > | get_Schemas () |
ASPOSECPP_SHARED_API void | set_Schemas (const SharedPtr< Schema::XmlSchemaSet > &value) |
virtual ASPOSECPP_SHARED_API void | set_XmlResolver (SharedPtr< System::Xml::XmlResolver > value) |
ASPOSECPP_SHARED_API SharedPtr< XmlNameTable > | get_NameTable () |
ASPOSECPP_SHARED_API bool | get_PreserveWhitespace () |
ASPOSECPP_SHARED_API void | set_PreserveWhitespace (bool value) |
ASPOSECPP_SHARED_API bool | get_IsReadOnly () override |
ASPOSECPP_SHARED_API void | set_InnerText (String value) override |
ASPOSECPP_SHARED_API String | get_InnerXml () override |
ASPOSECPP_SHARED_API void | set_InnerXml (String value) override |
ASPOSECPP_SHARED_API SharedPtr< Schema::IXmlSchemaInfo > | get_SchemaInfo () override |
ASPOSECPP_SHARED_API String | get_BaseURI () override |
ASPOSECPP_SHARED_API | XmlDocument () |
Initializes a new instance of the XmlDocument class. More... | |
ASPOSECPP_SHARED_API | XmlDocument (const SharedPtr< XmlNameTable > &nt) |
ASPOSECPP_SHARED_API SharedPtr< XmlNode > | CloneNode (bool deep) override |
ASPOSECPP_SHARED_API SharedPtr< XmlAttribute > | CreateAttribute (const String &name) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlCDataSection > | CreateCDataSection (const String &data) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlComment > | CreateComment (const String &data) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlDocumentType > | CreateDocumentType (const String &name, const String &publicId, const String &systemId, const String &internalSubset) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlDocumentFragment > | CreateDocumentFragment () |
ASPOSECPP_SHARED_API SharedPtr< XmlElement > | CreateElement (const String &name) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlEntityReference > | CreateEntityReference (const String &name) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlProcessingInstruction > | CreateProcessingInstruction (const String &target, const String &data) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlDeclaration > | CreateXmlDeclaration (const String &version, const String &encoding, const String &standalone) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlText > | CreateTextNode (const String &text) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlSignificantWhitespace > | CreateSignificantWhitespace (const String &text) |
ASPOSECPP_SHARED_API SharedPtr< XPath::XPathNavigator > | CreateNavigator () override |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlWhitespace > | CreateWhitespace (const String &text) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNodeList > | GetElementsByTagName (String name) |
ASPOSECPP_SHARED_API SharedPtr< XmlAttribute > | CreateAttribute (const String &qualifiedName, const String &namespaceURI) |
ASPOSECPP_SHARED_API SharedPtr< XmlElement > | CreateElement (const String &qualifiedName, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNodeList > | GetElementsByTagName (String localName, String namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlElement > | GetElementById (String elementId) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | ImportNode (SharedPtr< XmlNode > node, bool deep) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlAttribute > | CreateAttribute (const String &prefix, const String &localName, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlElement > | CreateElement (const String &prefix, const String &localName, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | CreateNode (XmlNodeType type, const String &prefix, const String &name, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | CreateNode (const String &nodeTypeString, const String &name, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | CreateNode (XmlNodeType type, const String &name, const String &namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | ReadNode (SharedPtr< XmlReader > reader) |
virtual ASPOSECPP_SHARED_API void | Load (String filename) |
virtual ASPOSECPP_SHARED_API void | Load (SharedPtr< IO::Stream > inStream) |
virtual ASPOSECPP_SHARED_API void | Load (SharedPtr< IO::TextReader > txtReader) |
virtual ASPOSECPP_SHARED_API void | Load (SharedPtr< XmlReader > reader) |
virtual ASPOSECPP_SHARED_API void | LoadXml (String xml) |
virtual ASPOSECPP_SHARED_API void | Save (String filename) |
virtual ASPOSECPP_SHARED_API void | Save (SharedPtr< IO::Stream > outStream) |
virtual ASPOSECPP_SHARED_API void | Save (SharedPtr< IO::TextWriter > writer) |
virtual ASPOSECPP_SHARED_API void | Save (SharedPtr< XmlWriter > w) |
ASPOSECPP_SHARED_API void | WriteTo (const SharedPtr< XmlWriter > &w) override |
ASPOSECPP_SHARED_API void | WriteContentTo (const SharedPtr< XmlWriter > &xw) override |
ASPOSECPP_SHARED_API void | Validate (Schema::ValidationEventHandler validationEventHandler) |
ASPOSECPP_SHARED_API void | Validate (Schema::ValidationEventHandler validationEventHandler, const SharedPtr< XmlNode > &nodeToValidate) |
Public Member Functions inherited from System::Xml::XmlNode | |
virtual ASPOSECPP_SHARED_API String | get_Value () |
virtual ASPOSECPP_SHARED_API void | set_Value (String value) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_ParentNode () final |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNodeList > | get_ChildNodes () |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_PreviousSibling () final |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_NextSibling () final |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlAttributeCollection > | get_Attributes () final |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_FirstChild () final |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_LastChild () final |
virtual ASPOSECPP_SHARED_API bool | get_HasChildNodes () |
virtual ASPOSECPP_SHARED_API String | get_NamespaceURI () |
virtual ASPOSECPP_SHARED_API String | get_Prefix () |
virtual ASPOSECPP_SHARED_API void | set_Prefix (String value) |
virtual ASPOSECPP_SHARED_API String | get_InnerText () |
virtual ASPOSECPP_SHARED_API String | get_OuterXml () |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | get_PreviousText () |
ASPOSECPP_SHARED_API SharedPtr< XPath::XPathNavigator > | CreateNavigator () override |
ASPOSECPP_SHARED_API SharedPtr< XmlNode > | SelectSingleNode (const String &xpath) |
ASPOSECPP_SHARED_API SharedPtr< XmlNode > | SelectSingleNode (const String &xpath, const SharedPtr< XmlNamespaceManager > &nsmgr) |
ASPOSECPP_SHARED_API SharedPtr< XmlNodeList > | SelectNodes (const String &xpath) |
ASPOSECPP_SHARED_API SharedPtr< XmlNodeList > | SelectNodes (const String &xpath, const SharedPtr< XmlNamespaceManager > &nsmgr) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | InsertBefore (SharedPtr< XmlNode > newChild, SharedPtr< XmlNode > refChild) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | InsertAfter (SharedPtr< XmlNode > newChild, SharedPtr< XmlNode > refChild) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | ReplaceChild (SharedPtr< XmlNode > newChild, SharedPtr< XmlNode > oldChild) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | RemoveChild (SharedPtr< XmlNode > oldChild) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | PrependChild (SharedPtr< XmlNode > newChild) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | AppendChild (SharedPtr< XmlNode > newChild) |
virtual ASPOSECPP_SHARED_API void | Normalize () |
virtual ASPOSECPP_SHARED_API bool | Supports (String feature, String version) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlNode > | Clone () |
ASPOSECPP_SHARED_API SharedPtr< Collections::Generic::IEnumerator< SharedPtr< XmlNode > > > | GetEnumerator () override |
virtual ASPOSECPP_SHARED_API void | RemoveAll () |
Removes all the child nodes and/or attributes of the current node. More... | |
virtual ASPOSECPP_SHARED_API String | GetNamespaceOfPrefix (String prefix) |
virtual ASPOSECPP_SHARED_API String | GetPrefixOfNamespace (String namespaceURI) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlElement > | idx_get (String name) |
virtual ASPOSECPP_SHARED_API SharedPtr< XmlElement > | idx_get (String localname, String ns) |
Public Member Functions inherited from System::Collections::Generic::IEnumerable< SharedPtr< System::Xml::XmlNode > > | |
SharedPtr< System::Xml::XmlNode > | LINQ_ElementAt (int index) |
SharedPtr< System::Xml::XmlNode > | LINQ_First () |
SharedPtr< System::Xml::XmlNode > | LINQ_First (const Func< SharedPtr< System::Xml::XmlNode >, bool > &predicate) |
SharedPtr< System::Xml::XmlNode > | LINQ_FirstOrDefault () |
SharedPtr< System::Xml::XmlNode > | LINQ_FirstOrDefault (std::function< bool(SharedPtr< System::Xml::XmlNode >)> predicate) |
SharedPtr< System::Xml::XmlNode > | LINQ_Last () |
SharedPtr< System::Xml::XmlNode > | LINQ_LastOrDefault () |
SharedPtr< List< SharedPtr< System::Xml::XmlNode > > > | LINQ_ToList () |
int | LINQ_Count () |
int | LINQ_Count (const Func< SharedPtr< System::Xml::XmlNode >, bool > &predicate) |
System::ArrayPtr< SharedPtr< System::Xml::XmlNode > > | LINQ_ToArray () |
bool | LINQ_All (std::function< bool(SharedPtr< System::Xml::XmlNode >)> predicate) |
bool | LINQ_Any () |
bool | LINQ_Any (std::function< bool(SharedPtr< System::Xml::XmlNode >)> predicate) |
SharedPtr< IEnumerable< SharedPtr< System::Xml::XmlNode > > > | LINQ_Where (std::function< bool(SharedPtr< System::Xml::XmlNode >)> predicate) |
bool | LINQ_Contains (SharedPtr< System::Xml::XmlNode > value) |
SharedPtr< IEnumerable< ResultType > > | LINQ_Cast () |
SharedPtr< IEnumerable< Result > > | LINQ_Cast () |
SharedPtr< IEnumerable< SharedPtr< System::Xml::XmlNode > > > | LINQ_OrderBy (const Func< SharedPtr< System::Xml::XmlNode >, Key > &keySelector) |
SharedPtr< IEnumerable< Source > > | LINQ_OrderBy (const Func< Source, Key > &keySelector) |
SharedPtr< IEnumerable< SharedPtr< System::Xml::XmlNode > > > | LINQ_OrderByDescending (const Func< SharedPtr< System::Xml::XmlNode >, Key > &keySelector) |
SharedPtr< IEnumerable< Source > > | LINQ_OrderByDescending (const Func< Source, Key > &keySelector) |
SharedPtr< IEnumerable< ResultType > > | LINQ_OfType () |
SharedPtr< IEnumerable< Result > > | LINQ_OfType () |
SharedPtr< IEnumerable< ResultType > > | LINQ_Select (const Func< SharedPtr< System::Xml::XmlNode >, ResultType > &selector) |
SharedPtr< IEnumerable< ResultType > > | LINQ_Select (const Func< SharedPtr< System::Xml::XmlNode >, int32_t, ResultType > &selector) |
SharedPtr< IEnumerable< Result > > | LINQ_Select (const Func< Source, Result > &selector) |
SharedPtr< IEnumerable< Result > > | LINQ_Select (const Func< Source, int32_t, Result > &selector) |
SharedPtr< IEnumerable< SharedPtr< System::Xml::XmlNode > > > | LINQ_Concat (SharedPtr< IEnumerable< SharedPtr< System::Xml::XmlNode > >> sequence) |
System::SharedPtr< IEnumerable< System::SharedPtr< System::Linq::IGrouping< Key, SharedPtr< System::Xml::XmlNode > > > > > | LINQ_GroupBy (System::Func< SharedPtr< System::Xml::XmlNode >, Key > keyPredicate) |
SharedPtr< IEnumerable< SharedPtr< System::Linq::IGrouping< Key, Source > > > > | LINQ_GroupBy (System::Func< Source, Key > keyPredicate) |
SharedPtr< IEnumerable< ResultType > > | LINQ_SelectMany (const Func< SharedPtr< System::Xml::XmlNode >, SharedPtr< IEnumerable< ResultType >>> &selector) |
SharedPtr< IEnumerable< Result > > | LINQ_SelectMany (const Func< Source, SharedPtr< IEnumerable< Result >>> &selector) |
iterator | begin () |
const_iterator | begin () const |
iterator | end () |
const_iterator | end () const |
const_iterator | cbegin () const |
const_iterator | cend () const |
virtual virtualized_iterator * | virtualizeBeginIterator () |
virtual virtualized_iterator * | virtualizeEndIterator () |
virtual virtualized_iterator * | virtualizeBeginConstIterator () const |
virtual virtualized_iterator * | virtualizeEndConstIterator () const |
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) |
Public Attributes | |
XmlNodeChangedEventHandler | NodeInserting |
Occurs when a node belonging to this document is about to be inserted into another node. More... | |
XmlNodeChangedEventHandler | NodeInserted |
Occurs when a node belonging to this document has been inserted into another node. More... | |
XmlNodeChangedEventHandler | NodeRemoving |
Occurs when a node belonging to this document is about to be removed from the document. More... | |
XmlNodeChangedEventHandler | NodeRemoved |
Occurs when a node belonging to this document has been removed from its parent. More... | |
XmlNodeChangedEventHandler | NodeChanging |
Occurs when the XmlNode::get_Value of a node belonging to this document is about to be changed. More... | |
XmlNodeChangedEventHandler | NodeChanged |
Occurs when the XmlNode::get_Value of a node belonging to this document has been changed. More... | |
Additional Inherited Members | |
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 an XML document. You can use this class to load, validate, edit, add, and position XML in a document.
An alias for shared pointer to an instance of this class.
ASPOSECPP_SHARED_API System::Xml::XmlDocument::XmlDocument | ( | ) |
Initializes a new instance of the XmlDocument class.
ASPOSECPP_SHARED_API System::Xml::XmlDocument::XmlDocument | ( | const SharedPtr< XmlNameTable > & | nt | ) |
Initializes a new instance of the XmlDocument class with the specified XmlNameTable.
nt | The XmlNameTable to use. |
|
overridevirtual |
Creates a duplicate of this node.
deep | true to recursively clone the subtree under the specified node; false to clone only the node itself. |
Implements System::Xml::XmlNode.
ASPOSECPP_SHARED_API SharedPtr<XmlAttribute> System::Xml::XmlDocument::CreateAttribute | ( | const String & | name | ) |
Creates an XmlAttribute with the specified name.
name | The qualified name of the attribute. If the name contains a colon, the XmlNode::get_Prefix value reflects the part of the name preceding the first colon and the XmlDocument::get_LocalName value reflects the part of the name following the first colon. The XmlNode::get_NamespaceURI remains empty unless the prefix is a recognized built-in prefix such as xmlns . In this case get_NamespaceURI has a value of http://www.w3.org/2000/xmlns/. |
ASPOSECPP_SHARED_API SharedPtr<XmlAttribute> System::Xml::XmlDocument::CreateAttribute | ( | const String & | qualifiedName, |
const String & | namespaceURI | ||
) |
Creates an XmlAttribute with the specified qualified name and XmlNode::get_NamespaceURI.
qualifiedName | The qualified name of the attribute. If the name contains a colon then the XmlNode::get_Prefix value will reflect the part of the name preceding the colon and the XmlDocument::get_LocalName value will reflect the part of the name after the colon. |
namespaceURI | The namespaceURI of the attribute. If the qualified name includes a prefix of xmlns , then this parameter must be http://www.w3.org/2000/xmlns/. |
|
virtual |
Creates an XmlAttribute with the specified XmlNode::get_Prefix, XmlDocument::get_LocalName, and XmlNode::get_NamespaceURI.
prefix | The prefix of the attribute (if any). String::Empty and nullptr are equivalent. |
localName | The local name of the attribute. |
namespaceURI | The namespace URI of the attribute (if any). String::Empty and nullptr are equivalent. If prefix is xmlns , then this parameter must be http://www.w3.org/2000/xmlns/; otherwise an exception is thrown. |
|
virtual |
Creates an XmlCDataSection containing the specified data.
data | The content of the new XmlCDataSection. |
|
virtual |
Creates an XmlComment containing the specified data.
data | The content of the new XmlComment. |
|
virtual |
Creates an XmlDocumentFragment.
|
virtual |
Returns a new XmlDocumentType object.
name | Name of the document type. |
publicId | The public identifier of the document type or nullptr . You can specify a public URI and also a system identifier to identify the location of the external DTD subset. |
systemId | The system identifier of the document type or nullptr . Specifies the URL of the file location for the external DTD subset. |
internalSubset | The DTD internal subset of the document type or nullptr . |
ASPOSECPP_SHARED_API SharedPtr<XmlElement> System::Xml::XmlDocument::CreateElement | ( | const String & | name | ) |
Creates an element with the specified name.
name | The qualified name of the element. If the name contains a colon then the XmlNode::get_Prefix value reflects the part of the name preceding the colon and the XmlDocument::get_LocalName value reflects the part of the name after the colon. The qualified name cannot include a prefix of xmlns . |
ASPOSECPP_SHARED_API SharedPtr<XmlElement> System::Xml::XmlDocument::CreateElement | ( | const String & | qualifiedName, |
const String & | namespaceURI | ||
) |
Creates an XmlElement with the qualified name and XmlNode::get_NamespaceURI.
qualifiedName | The qualified name of the element. If the name contains a colon then the XmlNode::get_Prefix value will reflect the part of the name preceding the colon and the XmlDocument::get_LocalName value will reflect the part of the name after the colon. The qualified name cannot include a prefix of xmlns . |
namespaceURI | The namespace URI of the element. |
|
virtual |
Creates an element with the specified XmlNode::get_Prefix, XmlDocument::get_LocalName, and XmlNode::get_NamespaceURI.
prefix | The prefix of the new element (if any). String::Empty and nullptr are equivalent. |
localName | The local name of the new element. |
namespaceURI | The namespace URI of the new element (if any). String::Empty and nullptr are equivalent. |
|
virtual |
Creates an XmlEntityReference with the specified name.
name | The name of the entity reference. |
ArgumentException | The name is invalid (for example, names starting with '#' are invalid.) |
|
overridevirtual |
Creates a new XPathNavigator object for navigating this document.
Implements System::Xml::XPath::IXPathNavigable.
|
virtual |
Creates a XmlNode with the specified XmlNodeType, XmlNode::get_Prefix, XmlDocument::get_Name, and XmlNode::get_NamespaceURI.
type | The XmlNodeType of the new node. |
prefix | The prefix of the new node. |
name | The local name of the new node. |
namespaceURI | The namespace URI of the new node. |
ArgumentException | The name was not provided and the XmlNodeType requires a name. |
|
virtual |
Creates an XmlNode with the specified node type, XmlDocument::get_Name, and XmlNode::get_NamespaceURI.
nodeTypeString | String version of the XmlNodeType of the new node. This parameter must be one of the values listed in the table below. |
name | The qualified name of the new node. If the name contains a colon, it is parsed into XmlNode::get_Prefix and XmlDocument::get_LocalName components. |
namespaceURI | The namespace URI of the new node. |
ArgumentException | The name was not provided and the XmlNodeType requires a name; or nodeTypeString is not one of the strings listed below. |
The nodeTypeString
parameter is case sensitive and must be one of the values in the following table:
nodeTypeString | XmlNodeType |
---|---|
attribute | Attribute |
cdatasection | CDATA |
comment | Comment |
document | Document |
documentfragment | DocumentFragment |
documenttype | DocumentType |
element | Element |
entityreference | EntityReference |
processinginstruction | ProcessingInstruction |
significantwhitespace | SignificantWhitespace |
text | Text |
whitespace | Whitespace |
|
virtual |
Creates an XmlNode with the specified XmlNodeType, XmlDocument::get_Name, and XmlNode::get_NamespaceURI.
type | The XmlNodeType of the new node. |
name | The qualified name of the new node. If the name contains a colon then it is parsed into XmlNode::get_Prefix and XmlDocument::get_LocalName components. |
namespaceURI | The namespace URI of the new node. |
ArgumentException | The name was not provided and the XmlNodeType requires a name. |
|
virtual |
Creates an XmlProcessingInstruction with the specified name and data.
target | The name of the processing instruction. |
data | The data for the processing instruction. |
|
virtual |
Creates an XmlSignificantWhitespace node.
text | The string must contain only the following characters '\x20' , '\x0d' , '\x0a' , '\x09' . |
|
virtual |
Creates an XmlWhitespace node.
text | The string must contain only the following characters '\x20' , '\x0d' , '\x0a' , '\x09' . |
|
virtual |
Creates an XmlDeclaration node with the specified values.
version | The version must be "1.0". |
encoding | The value of the encoding attribute. This is the encoding that is used when you save the XmlDocument to a file or a stream; therefore, it must be set to a string supported by the Text::Encoding class, otherwise "XmlDocument::Save(String)" fails. If this is nullptr or String::Empty, the XmlDocument::Save method does not write an encoding attribute on the XML declaration and therefore the default encoding, UTF-8, is used. |
Note: If the XmlDocument is saved to either a TextWriter or an XmlTextWriter, this encoding value is discarded. Instead, the encoding of the TextWriter or the XmlTextWriter is used. This ensures that the XML written out can be read back using the correct encoding.
standalone | The value must be either "yes" or "no". If this is nullptr or String::Empty, the XmlDocument::Save method does not write a standalone attribute on the XML declaration. |
ArgumentException | The values of version or standalone are something other than the ones specified above. |
|
overridevirtual |
Returns the base URI of the current node.
Reimplemented from System::Xml::XmlNode.
ASPOSECPP_SHARED_API SharedPtr<XmlElement> System::Xml::XmlDocument::get_DocumentElement | ( | ) |
Returns the root XmlElement for the document.
nullptr
is returned.
|
virtual |
Returns the node containing the DOCTYPE declaration.
ASPOSECPP_SHARED_API SharedPtr<XmlImplementation> System::Xml::XmlDocument::get_Implementation | ( | ) |
Returns the XmlImplementation object for the current document.
|
overridevirtual |
Returns the markup representing the children of the current node.
Reimplemented from System::Xml::XmlNode.
|
overridevirtual |
Returns a value indicating whether the current node is read-only.
true
if the current node is read-only; otherwise false
. XmlDocument nodes always return false
. Reimplemented from System::Xml::XmlNode.
|
overridevirtual |
Returns the local name of the node.
Implements System::Xml::XmlNode.
|
overridevirtual |
Returns the qualified name of the node.
Implements System::Xml::XmlNode.
ASPOSECPP_SHARED_API SharedPtr<XmlNameTable> System::Xml::XmlDocument::get_NameTable | ( | ) |
Returns the XmlNameTable associated with this implementation.
|
overridevirtual |
Returns the type of the current node.
Implements System::Xml::XmlNode.
|
overridevirtual |
Returns the XmlDocument to which the current node belongs.
nullptr
. Reimplemented from System::Xml::XmlNode.
ASPOSECPP_SHARED_API bool System::Xml::XmlDocument::get_PreserveWhitespace | ( | ) |
Returns a value indicating whether to preserve white space in element content.
true
to preserve white space; otherwise false
. The default is false
.
|
overridevirtual |
Returns the Post-Schema-Validation-Infoset (PSVI) of the node.
Reimplemented from System::Xml::XmlNode.
ASPOSECPP_SHARED_API SharedPtr<Schema::XmlSchemaSet> System::Xml::XmlDocument::get_Schemas | ( | ) |
Returns the XmlSchemaSet object associated with this XmlDocument.
|
virtual |
Returns the XmlElement with the specified ID.
elementId | The attribute ID to match. |
nullptr
if no matching element is found.
|
virtual |
Returns an XmlNodeList containing a list of all descendant elements that match the specified name.
name | The qualified name to match. It is matched against the get_Name value of the matching node. The special value "*" matches all tags. |
name
, the returned collection will be empty.
|
virtual |
Returns an XmlNodeList containing a list of all descendant elements that match the specified XmlDocument::get_LocalName and XmlNode::get_NamespaceURI.
localName | The LocalName to match. The special value "*" matches all tags. |
namespaceURI | NamespaceURI to match. |
localName
and namespaceURI
, the returned collection will be empty.
|
virtual |
Imports a node from another document to the current document.
node | The node being imported. |
deep | true to perform a deep clone; otherwise, false . |
InvalidOperationException | Calling this method on a node type which cannot be imported. |
|
virtual |
Loads the XML document from the specified URL.
filename | URL for the file containing the XML document to load. The URL can be either a local file or an HTTP URL (a Web address). |
XmlException | There is a load or parse error in the XML. In this case, a FileNotFoundException is raised. |
ArgumentException | filename is a zero-length string, contains only white space, or contains one or more invalid characters as defined by System::IO::Path::GetInvalidPathChars. |
ArgumentNullException | filename is nullptr . |
PathTooLongException | The specified path, file name, or both exceed the system-defined maximum length. |
DirectoryNotFoundException | The specified path is invalid (for example, it is on an unmapped drive). |
IOException | An I/O error occurred while opening the file. |
UnauthorizedAccessException | filename specified a file that is read-only. This operation is not supported on the current platform. filename specified a directory. The caller does not have the required permission. |
FileNotFoundException | The file specified in filename was not found. |
NotSupportedException | filename is in an invalid format. |
SecurityException | The caller does not have the required permission. |
|
virtual |
Loads the XML document from the specified stream.
inStream | The stream containing the XML document to load. |
XmlException | There is a load or parse error in the XML. In this case, a FileNotFoundException is raised. |
|
virtual |
Loads the XML document from the specified TextReader.
txtReader | The TextReader used to feed the XML data into the document. |
XmlException | There is a load or parse error in the XML. In this case, the document remains empty. |
|
virtual |
Loads the XML document from the specified string.
xml | String containing the XML document to load. |
XmlException | There is a load or parse error in the XML. In this case, the document remains empty. |
|
virtual |
Creates an XmlNode object based on the information in the XmlReader. The reader must be positioned on a node or attribute.
reader | The XML source. |
nullptr
if no more nodes exist. NullReferenceException | The reader is positioned on a node type that does not translate to a valid DOM node (for example, EndElement or EndEntity). |
|
virtual |
Saves the XML document to the specified file. If the specified file exists, this method overwrites it.
filename | The location of the file where you want to save the document. |
XmlException | The operation would not result in a well formed XML document (for example, no document element or duplicate XML declarations). |
|
virtual |
Saves the XML document to the specified stream.
outStream | The stream to which you want to save. |
XmlException | The operation would not result in a well formed XML document (for example, no document element or duplicate XML declarations). |
|
virtual |
Saves the XML document to the specified TextWriter.
writer | The TextWriter to which you want to save. |
XmlException | The operation would not result in a well formed XML document (for example, no document element or duplicate XML declarations). |
|
overridevirtual |
Throws an InvalidOperationException in all cases.
value | The value to set. |
InvalidOperationException | In all cases. |
Reimplemented from System::Xml::XmlNode.
|
overridevirtual |
Sets the markup representing the children of the current node.
value | The value to set. |
XmlException | The XML specified when setting this value is not well-formed. |
Reimplemented from System::Xml::XmlNode.
ASPOSECPP_SHARED_API void System::Xml::XmlDocument::set_PreserveWhitespace | ( | bool | value | ) |
Sets a value indicating whether to preserve white space in element content.
value | The value to set. |
ASPOSECPP_SHARED_API void System::Xml::XmlDocument::set_Schemas | ( | const SharedPtr< Schema::XmlSchemaSet > & | value | ) |
Sets the XmlSchemaSet object associated with this XmlDocument.
value | The value to set. |
|
virtual |
Sets the XmlResolver to use for resolving external resources.
value | The value to set. |
XmlException | This value is set to nullptr and an external DTD or entity is encountered. |
ASPOSECPP_SHARED_API void System::Xml::XmlDocument::Validate | ( | Schema::ValidationEventHandler | validationEventHandler | ) |
Validates the XmlDocument against the XML Schema Definition Language (XSD) schemas contained in the XmlDocument::get_Schemas list.
validationEventHandler | The Schema::ValidationEventHandler object that receives information about schema validation warnings and errors. |
XmlSchemaValidationException | A schema validation event occurred and no Schema::ValidationEventHandler object was specified. |
ASPOSECPP_SHARED_API void System::Xml::XmlDocument::Validate | ( | Schema::ValidationEventHandler | validationEventHandler, |
const SharedPtr< XmlNode > & | nodeToValidate | ||
) |
Validates the XmlNode object specified against the XML Schema Definition Language (XSD) schemas in the XmlDocument::get_Schemas list.
validationEventHandler | The Schema::ValidationEventHandler object that receives information about schema validation warnings and errors. |
nodeToValidate | The XmlNode object created from an XmlDocument to validate. |
ArgumentException | The XmlNode object parameter was not created from an XmlDocument. |
InvalidOperationException | The XmlNode object parameter is not an element, attribute, document fragment, or the root node. |
XmlSchemaValidationException | A schema validation event occurred and no Schema::ValidationEventHandler object was specified. |
|
overridevirtual |
Saves all the children of the XmlDocument node to the specified XmlWriter.
xw | The XmlWriter to which you want to save. |
Implements System::Xml::XmlNode.
|
overridevirtual |
Saves the XmlDocument node to the specified XmlWriter.
w | The XmlWriter to which you want to save. |
Implements System::Xml::XmlNode.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeChanged |
Occurs when the XmlNode::get_Value of a node belonging to this document has been changed.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeChanging |
Occurs when the XmlNode::get_Value of a node belonging to this document is about to be changed.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeInserted |
Occurs when a node belonging to this document has been inserted into another node.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeInserting |
Occurs when a node belonging to this document is about to be inserted into another node.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeRemoved |
Occurs when a node belonging to this document has been removed from its parent.
XmlNodeChangedEventHandler System::Xml::XmlDocument::NodeRemoving |
Occurs when a node belonging to this document is about to be removed from the document.