From 8bb2da063f59e7586c61f88c1fb2d268e6191e5c Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 3 Nov 2008 18:24:00 +0100 Subject: tag: added function tag_has_type() tag_has_type() checks whether the tag contains one or more items with the specified type. --- src/tag.h | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/tag.h') diff --git a/src/tag.h b/src/tag.h index 10801d9e..899768e2 100644 --- a/src/tag.h +++ b/src/tag.h @@ -23,6 +23,7 @@ #include #include +#include #include enum tag_type { @@ -88,6 +89,12 @@ static inline void tag_add_item(struct tag *tag, enum tag_type itemType, struct tag *tag_dup(const struct tag *tag); +/** + * Checks whether the tag contains one or more items with + * the specified type. + */ +bool tag_has_type(const struct tag *tag, enum tag_type type); + int tag_equal(const struct tag *tag1, const struct tag *tag2); #endif -- cgit v1.2.3