ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/src/vendor/libarchive/3.1.2/doc/html/archive_read_extract.3.html
Revision: 7246
Committed: Fri Aug 14 02:20:55 2015 UTC (8 years, 8 months ago) by laffer1
Content type: text/html
File size: 4747 byte(s)
Log Message:
tag 3.1.2

File Contents

# Content
1 <!-- Creator : groff version 1.21 -->
2 <!-- CreationDate: Sat Feb 9 12:24:04 2013 -->
3 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"
4 "http://www.w3.org/TR/html4/loose.dtd">
5 <html>
6 <head>
7 <meta name="generator" content="groff -Thtml, see www.gnu.org">
8 <meta http-equiv="Content-Type" content="text/html; charset=US-ASCII">
9 <meta name="Content-Style" content="text/css">
10 <style type="text/css">
11 p { margin-top: 0; margin-bottom: 0; vertical-align: top }
12 pre { margin-top: 0; margin-bottom: 0; vertical-align: top }
13 table { margin-top: 0; margin-bottom: 0; vertical-align: top }
14 h1 { text-align: center }
15 </style>
16 <title></title>
17 </head>
18 <body>
19
20 <hr>
21
22
23 <p>ARCHIVE_READ_EXTRACT(3) BSD Library Functions Manual
24 ARCHIVE_READ_EXTRACT(3)</p>
25
26 <p style="margin-top: 1em"><b>NAME</b></p>
27
28 <p style="margin-left:6%;"><b>archive_read_extract</b>,
29 <b>archive_read_extract2</b>,
30 <b>archive_read_extract_set_progress_callback</b> &mdash;
31 functions for reading streaming archives</p>
32
33 <p style="margin-top: 1em"><b>LIBRARY</b></p>
34
35 <p style="margin-left:6%;">Streaming Archive Library
36 (libarchive, -larchive)</p>
37
38 <p style="margin-top: 1em"><b>SYNOPSIS</b></p>
39
40 <p style="margin-left:6%;"><b>#include
41 &lt;archive.h&gt;</b></p>
42
43 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
44
45
46 <p><b>archive_read_extract</b>(<i>struct&nbsp;archive&nbsp;*</i>,
47 <i>struct&nbsp;archive_entry&nbsp;*</i>,
48 <i>int&nbsp;flags</i>);</p>
49
50 <p style="margin-left:6%; margin-top: 1em"><i>int</i></p>
51
52
53 <p><b>archive_read_extract2</b>(<i>struct&nbsp;archive&nbsp;*src</i>,
54 <i>struct&nbsp;archive_entry&nbsp;*</i>,
55 <i>struct&nbsp;archive&nbsp;*dest</i>);</p>
56
57 <p style="margin-left:6%; margin-top: 1em"><i>void</i></p>
58
59
60 <p><b>archive_read_extract_set_progress_callback</b>(<i>struct&nbsp;archive&nbsp;*</i>,
61 <i>void&nbsp;(*func)(void&nbsp;*)</i>,
62 <i>void&nbsp;*user_data</i>);</p>
63
64 <p style="margin-top: 1em"><b>DESCRIPTION <br>
65 archive_read_extract</b>(),
66 <b>archive_read_extract_set_skip_file</b>()</p>
67
68 <p style="margin-left:17%;">A convenience function that
69 wraps the corresponding archive_write_disk(3) interfaces.
70 The first call to <b>archive_read_extract</b>() creates a
71 restore object using archive_write_disk_new(3) and
72 archive_write_disk_set_standard_lookup(3), then
73 transparently invokes archive_write_disk_set_options(3),
74 archive_write_header(3), archive_write_data(3), and
75 archive_write_finish_entry(3) to create the entry on disk
76 and copy data into it. The <i>flags</i> argument is passed
77 unmodified to archive_write_disk_set_options(3).</p>
78
79 <p><b>archive_read_extract2</b>()</p>
80
81 <p style="margin-left:17%;">This is another version of
82 <b>archive_read_extract</b>() that allows you to provide
83 your own restore object. In particular, this allows you to
84 override the standard lookup functions using
85 archive_write_disk_set_group_lookup(3), and
86 archive_write_disk_set_user_lookup(3). Note that
87 <b>archive_read_extract2</b>() does not accept a
88 <i>flags</i> argument; you should use
89 <b>archive_write_disk_set_options</b>() to set the restore
90 options yourself.</p>
91
92 <p><b>archive_read_extract_set_progress_callback</b>()</p>
93
94 <p style="margin-left:17%;">Sets a pointer to a
95 user-defined callback that can be used for updating progress
96 displays during extraction. The progress function will be
97 invoked during the extraction of large regular files. The
98 progress function will be invoked with the pointer provided
99 to this call. Generally, the data pointed to should include
100 a reference to the archive object and the archive_entry
101 object so that various statistics can be retrieved for the
102 progress display.</p>
103
104 <p style="margin-top: 1em"><b>RETURN VALUES</b></p>
105
106 <p style="margin-left:6%;">Most functions return zero on
107 success, non-zero on error. The possible return codes
108 include: <b>ARCHIVE_OK</b> (the operation succeeded),
109 <b>ARCHIVE_WARN</b> (the operation succeeded but a
110 non-critical error was encountered), <b>ARCHIVE_EOF</b>
111 (end-of-archive was encountered), <b>ARCHIVE_RETRY</b> (the
112 operation failed but can be retried), and
113 <b>ARCHIVE_FATAL</b> (there was a fatal error; the archive
114 should be closed immediately).</p>
115
116 <p style="margin-top: 1em"><b>ERRORS</b></p>
117
118 <p style="margin-left:6%;">Detailed error codes and textual
119 descriptions are available from the <b>archive_errno</b>()
120 and <b>archive_error_string</b>() functions.</p>
121
122 <p style="margin-top: 1em"><b>SEE ALSO</b></p>
123
124 <p style="margin-left:6%;">tar(1), libarchive(3),
125 archive_read(3), archive_read_data(3),
126 archive_read_filter(3), archive_read_format(3),
127 archive_read_open(3), archive_read_set_options(3),
128 archive_util(3), tar(5)</p>
129
130 <p style="margin-left:6%; margin-top: 1em">BSD
131 February&nbsp;2, 2012 BSD</p>
132 <hr>
133 </body>
134 </html>