diff options
author | Max Kellermann <max@duempel.org> | 2014-04-24 18:29:11 +0200 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2014-04-24 18:32:23 +0200 |
commit | ecc12c9ba15809c918be5577cc90eba108569cbd (patch) | |
tree | e1139d9ea6c32d667b1acd396b6254378a3b8406 /src/tag/Set.hxx | |
parent | 9e50993c130ee7d3138150d4ebfef985d6ddc810 (diff) | |
download | mpd-ecc12c9ba15809c918be5577cc90eba108569cbd.tar.gz mpd-ecc12c9ba15809c918be5577cc90eba108569cbd.tar.xz mpd-ecc12c9ba15809c918be5577cc90eba108569cbd.zip |
db/Helpers: move code to tag/Set.cxx
Diffstat (limited to '')
-rw-r--r-- | src/tag/Set.hxx | 15 |
1 files changed, 14 insertions, 1 deletions
diff --git a/src/tag/Set.hxx b/src/tag/Set.hxx index 3b9654807..b5acfcb36 100644 --- a/src/tag/Set.hxx +++ b/src/tag/Set.hxx @@ -26,6 +26,7 @@ #include <set> #include <string.h> +#include <stdint.h> /** * Helper class for #TagSet which compares two #Tag objects. @@ -55,6 +56,18 @@ struct TagLess { /** * A set of #Tag objects. */ -typedef std::set<Tag, TagLess> TagSet; +class TagSet : public std::set<Tag, TagLess> { +public: + void InsertUnique(const Tag &tag, + TagType type, uint32_t group_mask); + +private: + void InsertUnique(const Tag &src, TagType type, const char *value, + uint32_t group_mask); + + bool CheckUnique(TagType dest_type, + const Tag &tag, TagType src_type, + uint32_t group_mask); +}; #endif |