]> icculus.org git repositories - icculus/xz.git/blob - src/liblzma/api/lzma/alone.h
Update the code to mostly match the new simpler file format
[icculus/xz.git] / src / liblzma / api / lzma / alone.h
1 /**
2  * \file        lzma/alone.h
3  * \brief       Handling of the legacy LZMA_Alone format
4  *
5  * \author      Copyright (C) 1999-2006 Igor Pavlov
6  * \author      Copyright (C) 2007 Lasse Collin
7  *
8  * This library is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU Lesser General Public
10  * License as published by the Free Software Foundation; either
11  * version 2.1 of the License, or (at your option) any later version.
12  *
13  * This library is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  * Lesser General Public License for more details.
17  */
18
19 #ifndef LZMA_H_INTERNAL
20 #       error Never include this file directly. Use <lzma.h> instead.
21 #endif
22
23
24 /**
25  * \brief       Initializes LZMA_Alone encoder
26  *
27  * LZMA_Alone files have the suffix .lzma like the .lzma Stream files.
28  * LZMA_Alone format supports only one filter, the LZMA filter. There is
29  * no support for integrity checks like CRC32.
30  *
31  * Use this format if and only if you need to create files readable by
32  * legacy LZMA tools.
33  *
34  * LZMA_Alone encoder doesn't support LZMA_SYNC_FLUSH or LZMA_FULL_FLUSH.
35  *
36  * \return      - LZMA_OK
37  *              - LZMA_MEM_ERROR
38  *              - LZMA_PROG_ERROR
39  */
40 extern lzma_ret lzma_alone_encoder(
41                 lzma_stream *strm, const lzma_options_lzma *options);
42
43
44 /**
45  * \brief       Initializes decoder for LZMA_Alone file
46  *
47  * The LZMA_Alone decoder supports LZMA_SYNC_FLUSH.
48  *
49  * \return      - LZMA_OK
50  *              - LZMA_MEM_ERROR
51  */
52 extern lzma_ret lzma_alone_decoder(lzma_stream *strm);