summaryrefslogtreecommitdiff
path: root/libarchive/archive_read_disk_private.h
diff options
context:
space:
mode:
authorMichihiro NAKAJIMA <ggcueroad@gmail.com>2011-12-31 03:48:59 -0500
committerMichihiro NAKAJIMA <ggcueroad@gmail.com>2011-12-31 03:48:59 -0500
commit27b627f20cac4e7d74e46876a7bd157c2105e18a (patch)
tree8a4837bc6f6751f33c3780dc58c88c1a404f458d /libarchive/archive_read_disk_private.h
parentb8399c672c418fcfffa6c91022501d232e730647 (diff)
downloadlibarchive-27b627f20cac4e7d74e46876a7bd157c2105e18a.tar.gz
Introduce archive_read_disk_set_name_filter_callback and archive_read_disk_set_time_filter_callback.
That is used for directory traversals to improve performance. A name filter callback set by archive_read_disk_set_name_filter_callback will be called just after the file is selected as next an entry; only pathname is set in the archive_entry object. A time filter callback set by archive_read_disk_set_time_filter_callback will be called just after the meta data such as mtime or ctime is set in the archive_entry object. In the time filter callback, you can use archive_read_disk_can_descend and archive_read_disk_descend. SVN-Revision: 4049
Diffstat (limited to 'libarchive/archive_read_disk_private.h')
-rw-r--r--libarchive/archive_read_disk_private.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/libarchive/archive_read_disk_private.h b/libarchive/archive_read_disk_private.h
index 4446474e..14038d88 100644
--- a/libarchive/archive_read_disk_private.h
+++ b/libarchive/archive_read_disk_private.h
@@ -34,6 +34,7 @@
#define ARCHIVE_READ_DISK_PRIVATE_H_INCLUDED
struct tree;
+struct archive_entry;
struct archive_read_disk {
struct archive archive;
@@ -66,6 +67,14 @@ struct archive_read_disk {
const char * (*lookup_uname)(void *private, int64_t uid);
void (*cleanup_uname)(void *private);
void *lookup_uname_data;
+
+ int (*name_filter_func)(struct archive *,
+ void *, struct archive_entry *);
+ void *name_filter_data;
+ int (*time_filter_func)(struct archive *,
+ void *, struct archive_entry *);
+ void *time_filter_data;
+
};
#endif