aboutsummaryrefslogtreecommitdiff
path: root/libid3tag/file.c
diff options
context:
space:
mode:
Diffstat (limited to 'libid3tag/file.c')
-rw-r--r--libid3tag/file.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/libid3tag/file.c b/libid3tag/file.c
index 1feb504..7c483ef 100644
--- a/libid3tag/file.c
+++ b/libid3tag/file.c
@@ -885,3 +885,30 @@ id3_file_update(struct id3_file *file)
return result;
}
+
+unsigned int
+id3_file_struct_ntags(struct id3_file *file)
+{
+ assert(file);
+ return file->ntags;
+}
+
+int
+id3_file_struct_iterate(struct id3_file *file,
+ id3_file_struct_iterator_t fun,
+ void *data)
+{
+ int i;
+ int rc = 0;
+
+ assert(file);
+
+ for (i = 0; i < file->ntags; i++) {
+ struct filetag *tag = file->tags + i;
+
+ rc = fun(tag->tag, tag->location, tag->length, data);
+ if (rc)
+ break;
+ }
+ return 0;
+}

Return to:

Send suggestions and report system problems to the System administrator.