PLCnext API Documentation  22.9.0.33
IXmlSerializable.hpp
1 //
3 // Copyright PHOENIX CONTACT Electronics GmbH
4 //
6 
7 #pragma once
8 #include "Arp/System/Core/Arp.h"
9 #include "Arp/System/Commons/Xml/XmlReader.hpp"
10 #include "Arp/System/Commons/Xml/XmlWriter.hpp"
11 #include "Arp/System/Commons/Xml/XmlSerializationContext.hpp"
12 
13 namespace Arp { namespace System { namespace Commons { namespace Xml
14 {
15 
18 {
19 public: // typedefs
20 
21 public: // construction/destruction
23  IXmlSerializable(void) = default;
25  //IXmlSerializable(const IXmlSerializable& arg) = delete;
27  //IXmlSerializable& operator=(const IXmlSerializable& arg) = delete;
29  virtual ~IXmlSerializable(void) = default;
30 
31 public: // operators
32 
33 public: // static operations
34 
35 public: // setter/getter operations
36 
37 public: // operations
41  virtual void ReadXml(XmlReader& reader, XmlSerializationContext& context) = 0;
42 
46  virtual void WriteXml(XmlWriter& writer, XmlSerializationContext& context) = 0;
47 
48 protected: // operations
49 
50 private: // static methods
51 
52 private: // methods
53 
54 private: // fields
55 
56 private: // static fields
57 
58 };
59 
60 }}}} // end of namespace Arp::System::Commons::Xml
Interface for all classes which should be serializable for xml
Definition: IXmlSerializable.hpp:18
virtual void ReadXml(XmlReader &reader, XmlSerializationContext &context)=0
ReadXML must be implemented by all classes which should read its context from xml files
IXmlSerializable(void)=default
Constructs an IXmlSerializable instance.
virtual ~IXmlSerializable(void)=default
Copy constructor.
Class to read an XML File. Non buffered reader, can only read forward
Definition: XmlReader.hpp:25
XML context used during XML reading and writing to hold the context information
Definition: XmlSerializationContext.hpp:26
Class to write an XML File
Definition: XmlWriter.hpp:21
@ System
System components used by the System, Device, Plc or Io domains.
Root namespace for the PLCnext API