AppleArchiveEntry.Extract

Extract(string)

Extracts the entry to the filesystem by the path provided.

public FileInfo Extract(string path)
ParameterTypeDescription
pathStringThe path to destination file. If the file already exists, it will be overwritten.

Exceptions

exceptioncondition
InvalidDataExceptionThe checksum or digest stored for the entry does not match the extracted data.
InvalidOperationExceptionThe entry belongs to an archive prepared for composition, or the entry data cannot be opened from a non-seekable archive stream.
NotSupportedExceptionThe entry belongs to a solid Apple Archive or uses an unsupported compression method.
ObjectDisposedExceptionThe source stream has been disposed.
IOExceptionAn I/O error occurs.

See Also


Extract(Stream)

Extracts the entry to the stream provided.

public void Extract(Stream destination)
ParameterTypeDescription
destinationStreamDestination stream. Must be writable.

Exceptions

exceptioncondition
ArgumentNullExceptiondestination is null.
ArgumentExceptiondestination does not support writing.
InvalidDataExceptionThe checksum or digest stored for the entry does not match the extracted data.
InvalidOperationExceptionThe entry belongs to an archive prepared for composition, or the entry data cannot be opened from a non-seekable archive stream.
NotSupportedExceptionThe entry belongs to a solid Apple Archive or uses an unsupported compression method.
ObjectDisposedExceptionThe source stream has been disposed.
IOExceptionAn I/O error occurs.

See Also