1ARCHIVE_ENTRY(3)         BSD Library Functions Manual         ARCHIVE_ENTRY(3)
2

NAME

4     archive_entry_clear, archive_entry_clone, archive_entry_free,
5     archive_entry_new, — functions for managing archive entry descriptions
6

LIBRARY

8     Streaming Archive Library (libarchive, -larchive)
9

SYNOPSIS

11     #include <archive_entry.h>
12
13     struct archive_entry *
14     archive_entry_clear(struct archive_entry *);
15
16     struct archive_entry *
17     archive_entry_clone(struct archive_entry *);
18
19     void
20     archive_entry_free(struct archive_entry *);
21
22     struct archive_entry *
23     archive_entry_new(void);
24

DESCRIPTION

26     These functions create and manipulate data objects that represent entries
27     within an archive.  You can think of a struct archive_entry as a heavy-
28     duty version of struct stat: it includes everything from struct stat plus
29     associated pathname, textual group and user names, etc.  These objects
30     are used by libarchive(3) to represent the metadata associated with a
31     particular entry in an archive.
32
33   Create and Destroy
34     There are functions to allocate, destroy, clear, and copy archive_entry
35     objects:
36     archive_entry_clear()
37             Erases the object, resetting all internal fields to the same
38             state as a newly-created object.  This is provided to allow you
39             to quickly recycle objects without thrashing the heap.
40     archive_entry_clone()
41             A deep copy operation; all text fields are duplicated.
42     archive_entry_free()
43             Releases the struct archive_entry object.
44     archive_entry_new()
45             Allocate and return a blank struct archive_entry object.
46
47   Function groups
48     Due to high number of functions, the accessor functions can be found in
49     man pages grouped by the purpose.
50
51     archive_entry_acl(3)    Access Control List manipulation
52
53     archive_entry_paths(3)  Path name manipulation
54
55     archive_entry_perms(3)  User, group and mode manipulation
56
57     archive_entry_stat(3)   Functions not in the other groups and copying
58                             to/from struct stat.
59
60     archive_entry_time(3)   Time field manipulation
61
62     Most of the functions set or read entries in an object.  Such functions
63     have one of the following forms:
64     archive_entry_set_XXXX()
65             Stores the provided data in the object.  In particular, for
66             strings, the pointer is stored, not the referenced string.
67     archive_entry_copy_XXXX()
68             As above, except that the referenced data is copied into the
69             object.
70     archive_entry_XXXX()
71             Returns the specified data.  In the case of strings, a const-
72             qualified pointer to the string is returned.
73     String data can be set or accessed as wide character strings or normal
74     char strings.  The functions that use wide character strings are suffixed
75     with _w.  Note that these are different representations of the same data:
76     For example, if you store a narrow string and read the corresponding wide
77     string, the object will transparently convert formats using the current
78     locale.  Similarly, if you store a wide string and then store a narrow
79     string for the same data, the previously-set wide string will be dis‐
80     carded in favor of the new data.
81

SEE ALSO

83     archive(3), archive_entry_acl(3), archive_entry_paths(3),
84     archive_entry_perms(3), archive_entry_time(3)
85

HISTORY

87     The libarchive library first appeared in FreeBSD 5.3.
88

AUTHORS

90     The libarchive library was written by Tim Kientzle <kientzle@acm.org>.
91
92BSD                            Feburary 2, 2012                            BSD
Impressum