150 lines
3.7 KiB
HTML
150 lines
3.7 KiB
HTML
|
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<HTML><HEAD><TITLE>Man page of Dpkg::Compression::Process</TITLE>
|
|
</HEAD><BODY>
|
|
<H1>Dpkg::Compression::Process</H1>
|
|
Section: libdpkg-perl (3perl)<BR>Updated: 2020-03-23<BR><A HREF="#index">Index</A>
|
|
<A HREF="/cgi-bin/man/man2html">Return to Main Contents</A><HR>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
<A NAME="lbAB"> </A>
|
|
<H2>NAME</H2>
|
|
|
|
Dpkg::Compression::Process - run compression/decompression processes
|
|
<A NAME="lbAC"> </A>
|
|
<H2>DESCRIPTION</H2>
|
|
|
|
|
|
|
|
This module provides an object oriented interface to run and manage
|
|
compression/decompression processes.
|
|
<A NAME="lbAD"> </A>
|
|
<H2>METHODS</H2>
|
|
|
|
|
|
|
|
<DL COMPACT>
|
|
<DT id="1">$proc = Dpkg::Compression::Process->new(%opts)<DD>
|
|
|
|
|
|
|
|
|
|
Create a new instance of the object. Supported options are ``compression''
|
|
and ``compression_level'' (see corresponding set_* functions).
|
|
<DT id="2">$proc->set_compression($comp)<DD>
|
|
|
|
|
|
|
|
|
|
Select the compression method to use. It errors out if the method is not
|
|
supported according to <TT>"compression_is_supported"</TT> (of
|
|
<B>Dpkg::Compression</B>).
|
|
<DT id="3">$proc->set_compression_level($level)<DD>
|
|
|
|
|
|
|
|
|
|
Select the compression level to use. It errors out if the level is not
|
|
valid according to <TT>"compression_is_valid_level"</TT> (of
|
|
<B>Dpkg::Compression</B>).
|
|
<DT id="4">@exec = $proc-><B>get_compress_cmdline()</B><DD>
|
|
|
|
|
|
|
|
|
|
|
|
<DT id="5">@exec = $proc-><B>get_uncompress_cmdline()</B><DD>
|
|
|
|
|
|
|
|
|
|
|
|
Returns a list ready to be passed to <TT>"exec"</TT>, its first element is the
|
|
program name (either for compression or decompression) and the following
|
|
elements are parameters for the program.
|
|
|
|
|
|
<P>
|
|
|
|
|
|
When executed the program acts as a filter between its standard input
|
|
and its standard output.
|
|
<DT id="6">$proc->compress(%opts)<DD>
|
|
|
|
|
|
|
|
|
|
Starts a compressor program. You must indicate where it will read its
|
|
uncompressed data from and where it will write its compressed data to.
|
|
This is accomplished by passing one parameter <TT>"to_*"</TT> and one parameter
|
|
<TT>"from_*"</TT> as accepted by <B>Dpkg::IPC::spawn</B>.
|
|
|
|
|
|
<P>
|
|
|
|
|
|
You must call <TT>"wait_end_process"</TT> after having called this method to
|
|
properly close the sub-process (and verify that it exited without error).
|
|
<DT id="7">$proc->uncompress(%opts)<DD>
|
|
|
|
|
|
|
|
|
|
Starts a decompressor program. You must indicate where it will read its
|
|
compressed data from and where it will write its uncompressed data to.
|
|
This is accomplished by passing one parameter <TT>"to_*"</TT> and one parameter
|
|
<TT>"from_*"</TT> as accepted by <B>Dpkg::IPC::spawn</B>.
|
|
|
|
|
|
<P>
|
|
|
|
|
|
You must call <TT>"wait_end_process"</TT> after having called this method to
|
|
properly close the sub-process (and verify that it exited without error).
|
|
<DT id="8">$proc->wait_end_process(%opts)<DD>
|
|
|
|
|
|
|
|
|
|
Call <B>Dpkg::IPC::wait_child</B> to wait until the sub-process has exited
|
|
and verify its return code. Any given option will be forwarded to
|
|
the <TT>"wait_child"</TT> function. Most notably you can use the ``nocheck'' option
|
|
to verify the return code yourself instead of letting <TT>"wait_child"</TT> do
|
|
it for you.
|
|
</DL>
|
|
<A NAME="lbAE"> </A>
|
|
<H2>CHANGES</H2>
|
|
|
|
|
|
|
|
<A NAME="lbAF"> </A>
|
|
<H3>Version 1.00 (dpkg 1.15.6)</H3>
|
|
|
|
|
|
|
|
Mark the module as public.
|
|
<P>
|
|
|
|
<HR>
|
|
<A NAME="index"> </A><H2>Index</H2>
|
|
<DL>
|
|
<DT id="9"><A HREF="#lbAB">NAME</A><DD>
|
|
<DT id="10"><A HREF="#lbAC">DESCRIPTION</A><DD>
|
|
<DT id="11"><A HREF="#lbAD">METHODS</A><DD>
|
|
<DT id="12"><A HREF="#lbAE">CHANGES</A><DD>
|
|
<DL>
|
|
<DT id="13"><A HREF="#lbAF">Version 1.00 (dpkg 1.15.6)</A><DD>
|
|
</DL>
|
|
</DL>
|
|
<HR>
|
|
This document was created by
|
|
<A HREF="/cgi-bin/man/man2html">man2html</A>,
|
|
using the manual pages.<BR>
|
|
Time: 00:05:38 GMT, March 31, 2021
|
|
</BODY>
|
|
</HTML>
|