Package com.e1c.g5.v8.fastzip
Interface IFzipWriter
-
- All Superinterfaces:
AutoCloseable
,Closeable
public interface IFzipWriter extends Closeable
FastZIP archive writer.All methods are synchronous and can be called in any order any number of times.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
setProgressListener(IProgressListener progressListener)
Sets a progress listener.void
write(IFzipEntry[] entries)
Writes entries to the archive.
-
-
-
Method Detail
-
setProgressListener
void setProgressListener(IProgressListener progressListener)
Sets a progress listener. The listener is used to track progress ofwrite(IFzipEntry[])
operation.- Parameters:
progressListener
- the progress listener, ornull
to remove a previously set listener
-
write
void write(IFzipEntry[] entries) throws IOException
Writes entries to the archive. The entries must belong to the registry of this writer. Reports the progress to a progress listener if it was set.If the operation fails the writer might end up in a closed state and no guarantees on the contents and consistency of the archive are provided.
- Parameters:
entries
- the entries, cannot benull
, cannot containnull
values- Throws:
FzipException
- if the writer failed to compress the entries for any reasonIOException
- if an IO error occurs
-
-