diff options
Diffstat (limited to 'src/tag.hpp')
-rw-r--r-- | src/tag.hpp | 41 |
1 files changed, 19 insertions, 22 deletions
diff --git a/src/tag.hpp b/src/tag.hpp index 469c4fd..75e5f59 100644 --- a/src/tag.hpp +++ b/src/tag.hpp @@ -4,39 +4,36 @@ #include "attribute.hpp" -class XiftTags { -public: - class Item: public XiftAttributes { - friend class XiftTags; - - Item(); - ~Item(); +struct XiftTag: public XiftAttributes { + XiftTag(); + ~XiftTag(); - bool MatchesForm(const Item & form) const; + bool MatchesForm(const XiftTag & form) const; - char *name; - int len; - int size; - }; + char *name; + int len; + int size; +}; +class XiftTags { +public: XiftTags(); ~XiftTags(); - Item &Tag(const char *name); - void Remove(const char *name); + XiftTag &Tag(const char *name); + void Remove(const char *name); -protected: - Item *Top(); - void Pop(); - Item *PopToBeDeleted(); - Item &New(); + XiftTag *Top(); + void Pop(); + XiftTag *PopToBeDeleted(); + XiftTag &New(); - bool ContainsMatchedForm(const Item &tag) const; + bool ContainsMatchedForm(const XiftTag &tag) const; private: struct Stack { - Stack *next; - Item *item; + Stack *next; + XiftTag *item; } *stack; }; |