CArchiveTag.h
Go to the documentation of this file.
1 #ifndef iser_CArchiveTag_included
2 #define iser_CArchiveTag_included
3 
4 
5 // Qt includes
6 #include <QtCore/QByteArray>
7 
8 
9 namespace iser
10 {
11 
12 
13 class IArchive;
14 
15 
22 {
23 public:
27  enum TagType
28  {
53  };
54 
55  CArchiveTag();
62  CArchiveTag(const QByteArray& id,
63  const QByteArray& comment,
64  TagType tagType = TT_UNKNOWN,
65  const CArchiveTag* parentPtr = NULL,
66  bool isTagSkippingUsed = false);
67 
71  const QByteArray& GetId() const;
72 
76  quint32 GetBinaryId() const;
77 
82  const QByteArray& GetComment() const;
83 
87  TagType GetTagType() const;
88 
92  const CArchiveTag* GetParentTag() const;
93 
97  bool IsTagSkippingUsed() const;
98 
99 private:
100  QByteArray m_id;
101  quint32 m_binaryId;
102 
103  QByteArray m_comment;
104 
105  TagType m_tagType;
106  const CArchiveTag* m_parentPtr;
107 
108  bool m_isTagSkippingUsed;
109 };
110 
111 
112 // inline methods
113 
115 {
116  return m_isTagSkippingUsed;
117 }
118 
119 
120 } // namespace iser
121 
122 
123 #endif // !iser_CArchiveTag_included
124 
125 
quint32 GetBinaryId() const
Get automatic generated binary ID.
Unknown type of tag.
Definition: CArchiveTag.h:32
Weak group tag, if possible it will be not outputted.
Definition: CArchiveTag.h:52
TagType GetTagType() const
Get type of this tag.
Multiple tag containing variable number of child tags.
Definition: CArchiveTag.h:42
Normal tag used for grouping of tags or processed elements.
Definition: CArchiveTag.h:37
Leaf tag, it can contain only one primitive element.
Definition: CArchiveTag.h:48
bool IsTagSkippingUsed() const
Check if it is needed to support tag skipping for this tag.
Definition: CArchiveTag.h:114
#define NULL
Definition: istd.h:64
const CArchiveTag * GetParentTag() const
Get tag beeing parent of this.
const QByteArray & GetId() const
Get ID of this tag.
Process tag used to group data in archive stream.
Definition: CArchiveTag.h:21
const QByteArray & GetComment() const
Get comment of this tag.
TagType
Describe type of tag.
Definition: CArchiveTag.h:27

© 2007-2017 Witold Gantzke and Kirill Lepskiy