CodePorting.Translator Cs2Cpp
CodePorting.Translator.Cs2Cpp.Framework
xml_processing_instruction.h
1
2
3#pragma once
4
5#include <xml/xml_node_type.h>
6#include <xml/xml_linked_node.h>
7#include <system/string.h>
8
9
11namespace System
12{
13namespace Xml
14{
15class XmlDocument;
16class XmlLoader;
17class XmlNode;
18class XmlWriter;
19namespace XPath
20{
21enum class XPathNodeType;
22} // namespace XPath
23} // namespace Xml
24} // namespace System
26
27namespace System {
28
29namespace Xml {
30
35class ASPOSECPP_SHARED_CLASS XmlProcessingInstruction : public XmlLinkedNode
36{
38 typedef XmlLinkedNode BaseType;
39
40 typedef ::System::BaseTypesInfo<BaseType> ThisTypeBaseTypesInfo;
41 ASPOSECPP_SHARED_RTTI_INFO_DECL();
42
43public:
44
47
48private:
50 friend class XmlDocument;
51 friend class XmlLoader;
53
54public:
55
58 ASPOSECPP_SHARED_API String get_Name() override;
61 ASPOSECPP_SHARED_API String get_LocalName() override;
64 ASPOSECPP_SHARED_API String get_Value() override;
68 ASPOSECPP_SHARED_API void set_Value(String value) override;
71 ASPOSECPP_SHARED_API String get_Target();
74 ASPOSECPP_SHARED_API String get_Data();
77 ASPOSECPP_SHARED_API void set_Data(const String& value);
80 ASPOSECPP_SHARED_API String get_InnerText() override;
83 ASPOSECPP_SHARED_API void set_InnerText(String value) override;
86 ASPOSECPP_SHARED_API XmlNodeType get_NodeType() override;
87
92 ASPOSECPP_SHARED_API SharedPtr<XmlNode> CloneNode(bool deep) override;
95 ASPOSECPP_SHARED_API void WriteTo(const SharedPtr<XmlWriter>& w) override;
99 ASPOSECPP_SHARED_API void WriteContentTo(const SharedPtr<XmlWriter>& w) override;
100
101protected:
102
104 ASPOSECPP_SHARED_API String get_XPLocalName() override;
105 ASPOSECPP_SHARED_API XPath::XPathNodeType get_XPNodeType() override;
107
112 ASPOSECPP_SHARED_API XmlProcessingInstruction(const String& target, const String& data, const SharedPtr<XmlDocument>& doc);
114
115 virtual ASPOSECPP_SHARED_API ~XmlProcessingInstruction();
116
117private:
118
119 String _target;
120 String _data;
121
122};
123
124} // namespace Xml
125} // namespace System
126
127
Pointer class to wrap types being allocated on heap. Use it to manage memory for classes inheriting O...
Definition: smart_ptr.h:180
String class used across the library. Is a substitute for C# System.String when translating code....
Definition: string.h:122
Represents an XML document. You can use this class to load, validate, edit, add, and position XML in ...
Definition: xml_document.h:100
Returns the node immediately preceding or following this node.
Definition: xml_linked_node.h:32
Represents a single node in the XML document.
Definition: xml_node.h:75
Represents a processing instruction, which XML defines to keep processor-specific information in the ...
Definition: xml_processing_instruction.h:36
void WriteTo(const SharedPtr< XmlWriter > &w) override
Saves the node to the specified XmlWriter.
void WriteContentTo(const SharedPtr< XmlWriter > &w) override
Saves all the children of the node to the specified XmlWriter. Because ProcessingInstruction nodes do...
String get_Target()
Returns the target of the processing instruction.
String get_Name() override
Returns the qualified name of the node.
void set_Value(String value) override
Sets the value of the node.
String get_LocalName() override
Returns the local name of the node.
MEMBER_FUNCTION_MAKE_OBJECT_DECLARATION(XmlProcessingInstruction, CODEPORTING_ARGS(String target, String data, SharedPtr< XmlDocument > doc))
void set_InnerText(String value) override
Sets the concatenated values of the node and all its children.
String get_Data()
Returns the content of the processing instruction, excluding the target.
void set_Data(const String &value)
Sets the content of the processing instruction, excluding the target.
String get_InnerText() override
Returns the concatenated values of the node and all its children.
SharedPtr< XmlNode > CloneNode(bool deep) override
Creates a duplicate of this node.
XmlProcessingInstruction(const String &target, const String &data, const SharedPtr< XmlDocument > &doc)
Initializes a new instance of the XmlProcessingInstruction class.
String get_Value() override
Returns the value of the node.
XmlNodeType get_NodeType() override
Returns the type of the current node.
XPathNodeType
Defines the XPath node types that can be returned from the XPathNavigator class.
Definition: xpath_node_type.h:17
@ Xml
Serialize according to the XML 1.0 rules.
XmlNodeType
Specifies the type of node.
Definition: xml_node_type.h:15
Definition: db_command.h:9