Main Page   Alphabetical List   Data Structures   File List   Data Fields   Globals  

archive_io.h File Reference

Archive I/O Functions. More...

#include <libcomprex/archive.h>

Go to the source code of this file.

Functions

CxArchivecxOpenArchive (const char *path)
 Opens an archive for reading or writing.

CxArchivecxOpenArchiveFromHandle (CxFile *file, CxAccessMode mode)
 Opens an archive from an existing file handle (CxFile structure).

CxArchivecxOpenArchiveStream (FILE *fp)
 Opens an archive from an existing file stream for reading or writing.

CxArchivecxOpenArchiveBuffer (char *buffer, size_t size)
 Opens an archive from a buffer for reading or writing.

void cxCloseArchive (CxArchive *archive)
 Closes an archive.

CxStatus cxSaveArchive (CxArchive *archive, const char *filename)
 Saves an archive.

CxStatus cxExtractArchive (CxArchive *archive)
 Extracts the specified archive's files to directories off of the current directory.


Detailed Description

Archive I/O Functions.

Copyright:
(C) 2001-2003 The GNUpdate Project.
This library is free software; you can redistribute it and/or modify it under the terms of the GNU Library General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public License for more details.

You should have received a copy of the GNU Library General Public License along with this library; if not, write to the Free Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.


Function Documentation

void cxCloseArchive CxArchive   archive
 

Closes an archive.

If changes were made to this archive, they will not be saved. To save them, use cxSaveArchive().

Parameters:
archive The archive structure.
See also:
cxOpenArchive()

cxOpenArchiveBuffer()

cxOpenArchiveStream()

cxSaveArchive()

CxStatus cxExtractArchive CxArchive   archive
 

Extracts the specified archive's files to directories off of the current directory.

Parameters:
archive The archive to extract.
Returns:
The status of the operation.

CxArchive* cxOpenArchive const char *    path
 

Opens an archive for reading or writing.

Parameters:
path The path to the archive.
Returns:
The archive structure, or NULL if the file couldn't be opened.
See also:
cxCloseArchive()

cxOpenArchiveBuffer()

cxOpenArchiveStream()

cxSaveArchive()

CxArchive* cxOpenArchiveBuffer char *    buffer,
size_t    size
 

Opens an archive from a buffer for reading or writing.

Parameters:
buffer The buffer to read from or write to.
size The size of the buffer.
Returns:
The archive structure, or NULL if an archive could not be found.
See also:
cxCloseArchive()

cxOpenArchive()

cxOpenArchiveStream()

cxSaveArchive()

CxArchive* cxOpenArchiveFromHandle CxFile   file,
CxAccessMode    mode
 

Opens an archive from an existing file handle (CxFile structure).

Parameters:
file The file handle.
mode The access mode.
Returns:
The archive, or NULL if it's unable to open.
See also:
cxOpenBuffer()

cxOpenFile()

cxOpenStream()

cxClose()

CxArchive* cxOpenArchiveStream FILE *    fp
 

Opens an archive from an existing file stream for reading or writing.

Parameters:
fp The existing file pointer stream.
Returns:
The archive structure, or NULL if an archive could not be found.
See also:
cxCloseArchive()

cxOpenArchive()

cxOpenArchiveBuffer()

cxSaveArchive()

CxStatus cxSaveArchive CxArchive   archive,
const char *    filename
 

Saves an archive.

This will not close the archive. To close the archive, use cxCloseArchive().

Parameters:
archive The archive structure.
filename The destination filename.
Returns:
The status of the operation.
See also:
cxCloseArchive()

cxOpenArchive()

cxOpenArchiveBuffer()

cxOpenArchiveStream()


Generated on Wed Mar 5 20:47:43 2003 for libcomprex by doxygen1.2.18-20021020