PLCnext API Documentation  22.9.0.33
ConfigHeader.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/IXmlSerializable.hpp"
10 
11 namespace Arp { namespace System { namespace Commons { namespace Xml
12 {
13 
15 class ConfigHeader: public IXmlSerializable, Loggable<ConfigHeader>
16 {
17 public: // typedefs
18  typedef std::map<String, String> DecriptionList;
19 
20 public: // construction/destruction
22  ConfigHeader(void) = default;
24  ConfigHeader(const ConfigHeader& arg) = delete;
26  ConfigHeader& operator=(const ConfigHeader& arg) = delete;
28  virtual ~ConfigHeader(void) = default;
29 
30 public: // operators
31 
32 public: // static operations
33 
34 public: // setter/getter operations
35 
36 public: // operations
38  void ReadXml(XmlReader& reader, XmlSerializationContext& context) override;
40  void WriteXml(XmlWriter& writer, XmlSerializationContext& context) override;
41 
42 protected: // operations
43 
44 private: // static methods
45 
46 private: // methods
47 
48 private: // fields
49  String name;
50  String version;
51  DecriptionList decriptionList;
52 
53 private: // static fields
54 };
55 
56 }}}} // end of namespace Arp::System::Commons::Xml
Internal class to parse the header common for all configuration files
Definition: ConfigHeader.hpp:16
ConfigHeader(void)=default
Constructs an IXmlSerializable instance.
virtual ~ConfigHeader(void)=default
Destructs this instance and frees all resources.
void ReadXml(XmlReader &reader, XmlSerializationContext &context) override
Implements ReadXml from IXmlSerializable
ConfigHeader & operator=(const ConfigHeader &arg)=delete
Assignment operator.
ConfigHeader(const ConfigHeader &arg)=delete
Copy constructor.
Interface for all classes which should be serializable for xml
Definition: IXmlSerializable.hpp:18
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