org.kde.koala
public class KTar extends KArchive
UNKNOWN: A class for reading / writing (optionally compressed) tar archives.
Constructor Summary | |
---|---|
protected | KTar(Class dummy) |
KTar(String filename, String mimetype)
Creates an instance that operates on the given filename
using the compression filter associated to given mimetype. | |
KTar(String filename) | |
KTar(QIODeviceInterface dev)
Creates an instance that operates on the given device.
|
Method Summary | |
---|---|
protected boolean | closeArchive() |
void | dispose() Delete the wrapped C++ instance ahead of finalize() |
boolean | doneWriting(int size) |
String | fileName()
The name of the tar file, as passed to the constructor
Null if you used the QIODevice constructor. |
protected void | finalize() Deletes the wrapped C++ instance |
boolean | isDisposed() Has the wrapped C++ instance been deleted? |
protected boolean | openArchive(int mode)
Opens the archive for reading.
|
boolean | prepareWriting(String name, String user, String group, int size) |
boolean | prepareWriting(String name, String user, String group, int size, long perm, int atime, int mtime, int ctime) |
protected boolean | prepareWriting_impl(String name, String user, String group, int size, long perm, int atime, int mtime, int ctime) |
void | setOrigFileName(String fileName)
Special function for setting the "original file name" in the gzip header,
when writing a tar.gz file. |
boolean | writeDir(String name, String user, String group) |
boolean | writeDir(String name, String user, String group, long perm, int atime, int mtime, int ctime) |
protected boolean | writeDir_impl(String name, String user, String group, long perm, int atime, int mtime, int ctime) |
boolean | writeSymLink(String name, String target, String user, String group, long perm, int atime, int mtime, int ctime) |
protected boolean | writeSymLink_impl(String name, String target, String user, String group, long perm, int atime, int mtime, int ctime) |
Parameters: filename is a local path (e.g. "/home/weis/myfile.tgz") mimetype "application/x-gzip" or "application/x-bzip2" Do not use application/x-tgz or similar - you only need to specify the compression layer ! If the mimetype is omitted, it will be determined from the filename.
UNKNOWN: Creates an instance that operates on the given filename using the compression filter associated to given mimetype.
Parameters: dev the device to read from. If the source is compressed, the QIODevice must take care of decompression
UNKNOWN: Do not assume that giving a QFile here will decompress the file, in case it's compressed! Creates an instance that operates on the given device.
Returns: the name of the file, or null if unknown
UNKNOWN: The name of the tar file, as passed to the constructor Null if you used the QIODevice constructor.
Parameters: mode the mode of the file
UNKNOWN: Opens the archive for reading.
Parameters: fileName the original file name
UNKNOWN: Special function for setting the "original file name" in the gzip header, when writing a tar.