EggArchive

Inheritance: java.lang.Object

All Implemented Interfaces: com.aspose.zip.IArchive, java.lang.AutoCloseable

public class EggArchive implements IArchive, AutoCloseable

This class represents an EGG archive file. Use it to extract EGG archives.

Constructors

ConstructorDescription
EggArchive(InputStream stream)Initializes an EGG archive from a stream.
EggArchive(InputStream stream, EggArchiveLoadOptions loadOptions)Initializes an EGG archive from a stream.
EggArchive(String path)Initializes an EGG archive from a file path.
EggArchive(String path, EggArchiveLoadOptions loadOptions)Initializes an EGG archive from a file path.

Methods

MethodDescription
close()Releases all resources used by this archive.
extractToDirectory(String destinationDirectory)Extracts archived files to the provided directory.
getComment()Gets the comment for the whole archive.
getEntries()Gets the list of files in the archive.
getFileEntries()Gets entries of IArchiveFileEntry type constituting the archive.
getFormat()Gets the archive format.

EggArchive(InputStream stream)

public EggArchive(InputStream stream)

Initializes an EGG archive from a stream.

Parameters:

ParameterTypeDescription
streamjava.io.InputStreamEGG archive stream; it must support reading and seeking.

EggArchive(InputStream stream, EggArchiveLoadOptions loadOptions)

public EggArchive(InputStream stream, EggArchiveLoadOptions loadOptions)

Initializes an EGG archive from a stream.

Parameters:

ParameterTypeDescription
streamjava.io.InputStreamEGG archive stream; it must support reading and seeking.
loadOptionsEggArchiveLoadOptionsoptions to load the archive with.

EggArchive(String path)

public EggArchive(String path)

Initializes an EGG archive from a file path.

Parameters:

ParameterTypeDescription
pathjava.lang.Stringpath to the EGG archive file.

EggArchive(String path, EggArchiveLoadOptions loadOptions)

public EggArchive(String path, EggArchiveLoadOptions loadOptions)

Initializes an EGG archive from a file path.

Parameters:

ParameterTypeDescription
pathjava.lang.Stringpath to the EGG archive file.
loadOptionsEggArchiveLoadOptionsoptions to load the archive with.

close()

public final void close()

Releases all resources used by this archive.

extractToDirectory(String destinationDirectory)

public final void extractToDirectory(String destinationDirectory)

Extracts archived files to the provided directory.

Parameters:

ParameterTypeDescription
destinationDirectoryjava.lang.Stringpath to the directory in which to place the extracted files.

getComment()

public final String getComment()

Gets the comment for the whole archive.

Returns: java.lang.String - comment for the whole archive.

getEntries()

public final List<EggEntry> getEntries()

Gets the list of files in the archive.

Returns: java.util.List<com.aspose.zip.EggEntry> - immutable list of files in the archive.

getFileEntries()

public final Iterable<IArchiveFileEntry> getFileEntries()

Gets entries of IArchiveFileEntry type constituting the archive.

Returns: java.lang.Iterable<com.aspose.zip.IArchiveFileEntry> - entries of IArchiveFileEntry type constituting the archive.

getFormat()

public final ArchiveFormat getFormat()

Gets the archive format.

Returns: ArchiveFormat - ArchiveFormat.Egg.