DeflaterOutputStream Members

SharpZip Compression Library

SharpZip Compression Library

DeflaterOutputStream Members

DeflaterOutputStream overview

Public Instance Constructors

DeflaterOutputStream Overloaded. Initializes a new instance of the DeflaterOutputStream class.

Public Instance Properties

CanPatchEntries Allows client to determine if an entry can be patched after its added
CanRead Gets value indicating stream can be read from
CanSeek Gets a value indicating if seeking is supported for this stream This property always returns false
CanWrite Get value indicating if this stream supports writing
IsStreamOwner Get/set flag indicating ownership of underlying stream. When the flag is true Close will close the underlying stream also.
Length Get current length of stream
Password Get/set the password used for encryption. When null no encryption is performed
Position The current position within the stream. Always throws a NotSupportedExceptionNotSupportedException

Public Instance Methods

BeginRead Asynchronous reads are not supported a NotSupportedException is always thrown
BeginWrite Asynchronous writes arent supported, a NotSupportedException is always thrown
Close Calls finish() and closes the underlying stream when IsStreamOwner is true.
CreateObjRef (inherited from MarshalByRefObject) Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object.
EndRead (inherited from Stream) Waits for the pending asynchronous read to complete.
EndWrite (inherited from Stream) Ends an asynchronous write operation.
Equals (inherited from Object) Determines whether the specified Object is equal to the current Object.
Finish Finishes the stream by calling finish() on the deflater.
Flush Flushes the stream by calling flush() on the deflater and then on the underlying stream. This ensures that all bytes are flushed.
GetHashCode (inherited from Object) Serves as a hash function for a particular type, suitable for use in hashing algorithms and data structures like a hash table.
GetLifetimeService (inherited from MarshalByRefObject) Retrieves the current lifetime service object that controls the lifetime policy for this instance.
GetType (inherited from Object) Gets the Type of the current instance.
InitializeLifetimeService (inherited from MarshalByRefObject) Obtains a lifetime service object to control the lifetime policy for this instance.
Read Read a block of bytes from stream
ReadByte Read a byte from stream advancing position by one
Seek Sets the current position of this stream to the given value. Not supported by this class!
SetLength Sets the length of this stream to the given value. Not supported by this class!
ToString (inherited from Object) Returns a String that represents the current Object.
Write Writes bytes from an array to the compressed stream.
WriteByte Writes a single byte to the compressed output stream.

Protected Instance Fields

baseOutputStream Base stream the deflater depends on.
buf This buffer is used temporarily to retrieve the bytes from the deflater and write them to the underlying output stream.
def The deflater which is used to deflate the stream.

Protected Instance Methods

CreateWaitHandle (inherited from Stream) Allocates a WaitHandle object.
Deflate Deflates everything in the input buffers. This will call
def.deflate()
until all bytes from the input buffers are processed.
EncryptBlock Encrypt a block of data
EncryptByte Encrypt a single byte
Finalize (inherited from Object) Allows an Object to attempt to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection.
InitializePassword Initializes encryption keys based on given password
MemberwiseClone (inherited from Object) Creates a shallow copy of the current Object.
UpdateKeys Update encryption keys

See Also

DeflaterOutputStream Class | ICSharpCode.SharpZipLib.Zip.Compression.Streams Namespace