SharpZip Compression LibraryCompress Compress instream sending result to outputstream Decompress...

Preview:

Citation preview

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionSharpZipBaseException SharpZipBaseExceptionisthe

baseexceptionclassfortheSharpZipLibrary.Alllibraryexceptionsarederivedfromthis.

ICSharpCode.SharpZipLibNamespace

SharpZipCompressionLibrary

SharpZipBaseExceptionisthebaseexceptionclassfortheSharpZipLibrary.Alllibraryexceptionsarederivedfromthis.

Foralistofallmembersofthistype,seeSharpZipBaseExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.BZip2.BZip2ExceptionICSharpCode.SharpZipLib.GZip.GZipExceptionICSharpCode.SharpZipLib.Tar.TarExceptionICSharpCode.SharpZipLib.Zip.ZipException

publicclassSharpZipBaseException:

ApplicationException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLibAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoSharpZipBaseExceptionMembers|ICSharpCode.SharpZipLibNamespace

SharpZipBaseExceptionClass

SharpZipCompressionLibrary

SharpZipBaseExceptionoverview

PublicInstanceConstructorsSharpZipBaseException Overloaded.Initializesanew

instanceoftheSharpZipBaseExceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

SharpZipBaseExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoSharpZipBaseExceptionClass|ICSharpCode.SharpZipLibNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheSharpZipLibraryExceptionclass.

OverloadListInitializesanewinstanceoftheSharpZipLibraryExceptionclass.

publicSharpZipBaseException();

InitializesanewinstanceoftheSharpZipLibraryExceptionclasswithaspecifiederrormessage.

publicSharpZipBaseException(string);

InitializesanewinstanceoftheSharpZipLibraryExceptionclasswithaspecifiederrormessageandareferencetotheinnerexceptionthatisthecauseofthisexception.

publicSharpZipBaseException(string,Exception);

SeeAlsoSharpZipBaseExceptionClass|ICSharpCode.SharpZipLibNamespace

SharpZipBaseExceptionConstructor

SharpZipCompressionLibrary

InitializesanewinstanceoftheSharpZipLibraryExceptionclass.

publicSharpZipBaseException();

SeeAlsoSharpZipBaseExceptionClass|ICSharpCode.SharpZipLibNamespace|SharpZipBaseExceptionConstructorOverloadList

SharpZipBaseExceptionConstructor()

SharpZipCompressionLibrary

InitializesanewinstanceoftheSharpZipLibraryExceptionclasswithaspecifiederrormessage.

publicSharpZipBaseException(

stringmsg

);

SeeAlsoSharpZipBaseExceptionClass|ICSharpCode.SharpZipLibNamespace|SharpZipBaseExceptionConstructorOverloadList

SharpZipBaseExceptionConstructor(String)

SharpZipCompressionLibrary

InitializesanewinstanceoftheSharpZipLibraryExceptionclasswithaspecifiederrormessageandareferencetotheinnerexceptionthatisthecauseofthisexception.

publicSharpZipBaseException(

stringmessage,

ExceptioninnerException

);

Parametersmessage

Errormessagestring

innerExceptionTheinnerexception

SeeAlsoSharpZipBaseExceptionClass|ICSharpCode.SharpZipLibNamespace|SharpZipBaseExceptionConstructorOverloadList

SharpZipBaseExceptionConstructor(String,Exception)

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionBZip2 Doesallthecompressand

decompresspre-operationstuff.Setsupthestreamsandfileheadercharacters.Usesmultiplyoverloadedmethodstocallforthecompress/decompress.

BZip2Constants Definesinternalvaluesforbothcompressionanddecompression

BZip2Exception BZip2ExceptionrepresentsexceptionsspecifictoBzip2algorithm

BZip2InputStream AninputstreamthatdecompressesfilesintheBZip2format

BZip2OutputStream AnoutputstreamthatcompressesintotheBZip2formatincludingfileheadercharsintoanotherstream.

ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

Doesallthecompressanddecompresspre-operationstuff.Setsupthestreamsandfileheadercharacters.Usesmultiplyoverloadedmethodstocallforthecompress/decompress.

Foralistofallmembersofthistype,seeBZip2Members.

System.ObjectICSharpCode.SharpZipLib.BZip2.BZip2

publicsealedclassBZip2

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.BZip2Assembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoBZip2Members|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Class

SharpZipCompressionLibrary

BZip2overview

PublicStaticMethodsCompress Compressinstreamsending

resulttooutputstream

Decompress Decompressinstreamwritingdecompresseddatatooutstream

PublicInstanceConstructorsBZip2Constructor Initializesanewinstanceofthe

BZip2class.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

SeeAlsoBZip2Class|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Members

SharpZipCompressionLibrary

InitializesanewinstanceoftheBZip2class.

publicBZip2();

SeeAlsoBZip2Class|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constructor

SharpZipCompressionLibrary

ThemethodsoftheBZip2classarelistedbelow.ForacompletelistofBZip2classmembers,seetheBZip2Memberstopic.

PublicStaticMethodsCompress Compressinstreamsending

resulttooutputstream

Decompress Decompressinstreamwritingdecompresseddatatooutstream

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

SeeAlsoBZip2Class|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Methods

SharpZipCompressionLibrary

Compressinstreamsendingresulttooutputstream

publicstaticvoidCompress(

Streaminstream,

Streamoutstream,

intblockSize

);

SeeAlsoBZip2Class|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2.CompressMethod

SharpZipCompressionLibrary

Decompressinstreamwritingdecompresseddatatooutstream

publicstaticvoidDecompress(

Streaminstream,

Streamoutstream

);

SeeAlsoBZip2Class|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2.DecompressMethod

SharpZipCompressionLibrary

Definesinternalvaluesforbothcompressionanddecompression

Foralistofallmembersofthistype,seeBZip2ConstantsMembers.

System.ObjectICSharpCode.SharpZipLib.BZip2.BZip2Constants

publicsealedclassBZip2Constants

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.BZip2Assembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoBZip2ConstantsMembers|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2ConstantsClass

SharpZipCompressionLibrary

BZip2Constantsoverview

PublicStaticFieldsbaseBlockSize Whenmultipliedby

compressionparameter(1-9)givestheblocksizeforcompression9givesthebestcompresssionbutusesthemostmemory.

G_SIZE Backendconstant

MAX_ALPHA_SIZE Backendconstant

MAX_CODE_LEN Backendconstant

MAX_SELECTORS Backendconstant

N_GROUPS Backendconstant

N_ITERS Backendconstant

NUM_OVERSHOOT_BYTESBackendconstant

rNums Randomnumbersusedtorandomiserepetitiveblocks

RUNA Backendconstant

RUNB Backendconstant

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

BZip2ConstantsMembers

SharpZipCompressionLibrary

ThefieldsoftheBZip2Constantsclassarelistedbelow.ForacompletelistofBZip2Constantsclassmembers,seetheBZip2ConstantsMemberstopic.

PublicStaticFieldsbaseBlockSize Whenmultipliedby

compressionparameter(1-9)givestheblocksizeforcompression9givesthebestcompresssionbutusesthemostmemory.

G_SIZE Backendconstant

MAX_ALPHA_SIZE Backendconstant

MAX_CODE_LEN Backendconstant

MAX_SELECTORS Backendconstant

N_GROUPS Backendconstant

N_ITERS Backendconstant

NUM_OVERSHOOT_BYTESBackendconstant

rNums Randomnumbersusedtorandomiserepetitiveblocks

RUNA Backendconstant

RUNB Backendconstant

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2ConstantsFields

SharpZipCompressionLibrary

Whenmultipliedbycompressionparameter(1-9)givestheblocksizeforcompression9givesthebestcompresssionbutusesthemostmemory.

publicstaticreadonlyintbaseBlockSize;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.baseBlockSizeField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintG_SIZE;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.G_SIZEField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintMAX_ALPHA_SIZE;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.MAX_ALPHA_SIZEField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintMAX_CODE_LEN;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.MAX_CODE_LENField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintMAX_SELECTORS;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.MAX_SELECTORSField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintN_GROUPS;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.N_GROUPSField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintN_ITERS;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.N_ITERSField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintNUM_OVERSHOOT_BYTES;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.NUM_OVERSHOOT_BYTESField

SharpZipCompressionLibrary

Randomnumbersusedtorandomiserepetitiveblocks

publicstaticreadonlyint[]rNums;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.rNumsField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintRUNA;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.RUNAField

SharpZipCompressionLibrary

Backendconstant

publicstaticreadonlyintRUNB;

SeeAlsoBZip2ConstantsClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2Constants.RUNBField

SharpZipCompressionLibrary

BZip2ExceptionrepresentsexceptionsspecifictoBzip2algorithm

Foralistofallmembersofthistype,seeBZip2ExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.BZip2.BZip2Exception

publicclassBZip2Exception:

SharpZipBaseException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.BZip2Assembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoBZip2ExceptionMembers|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2ExceptionClass

SharpZipCompressionLibrary

BZip2Exceptionoverview

PublicInstanceConstructorsBZip2Exception Overloaded.Initializesanew

instanceoftheBZip2Exceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

BZip2ExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoBZip2ExceptionClass|ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

InitialiseanewinstanceofBZip2Exception.

OverloadListInitialiseanewinstanceofBZip2Exception.

publicBZip2Exception();

InitialiseanewinstanceofBZip2Exceptionwithitsmessagesettomessage.

publicBZip2Exception(string);

SeeAlsoBZip2ExceptionClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2ExceptionConstructor

SharpZipCompressionLibrary

InitialiseanewinstanceofBZip2Exception.

publicBZip2Exception();

SeeAlsoBZip2ExceptionClass|ICSharpCode.SharpZipLib.BZip2Namespace|BZip2ExceptionConstructorOverloadList

BZip2ExceptionConstructor()

SharpZipCompressionLibrary

InitialiseanewinstanceofBZip2Exceptionwithitsmessagesettomessage.

publicBZip2Exception(

stringmessage

);

Parametersmessage

Themessagedescribingtheerror.

SeeAlsoBZip2ExceptionClass|ICSharpCode.SharpZipLib.BZip2Namespace|BZip2ExceptionConstructorOverloadList

BZip2ExceptionConstructor(String)

SharpZipCompressionLibrary

AninputstreamthatdecompressesfilesintheBZip2format

Foralistofallmembersofthistype,seeBZip2InputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.BZip2.BZip2InputStream

publicclassBZip2InputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.BZip2Assembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoBZip2InputStreamMembers|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStreamClass

SharpZipCompressionLibrary

BZip2InputStreamoverview

PublicInstanceConstructorsBZip2InputStream

ConstructorConstructinstanceforreadingfromstream

PublicInstancePropertiesCanRead Getsavalueindicatingifthe

streamsupportsreading

CanSeek Getsavalueindicatingwhetherthecurrentstreamsupportsseeking.

CanWrite Getsavalueindicatingwhetherthecurrentstreamsupportswriting.Thispropertyalwaysreturnsfalse

Length Getsthelengthinbytesofthestream.

Position Getsorsetsthestreamsposition.SettingthepositionisnotsupportedandwillthrowaNotSupportException

PublicInstanceMethodsBeginRead(inherited

fromStream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Closesthestream,releasinganyassociatedresources.

CreateObjRef(inheritedfrom

Createsanobjectthatcontainsalltherelevantinformationrequiredto

BZip2InputStreamMembers

MarshalByRefObject) generateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject)

DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushesthestream.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readasequenceofbytesandadvancesthereadpositionbyonebyte.

ReadByte Readabytefromstreamadvancingposition

Seek Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

SetLength Setsthelengthofthisstreamtothegivenvalue.ThisoperationisnotsupportedandwillthrowaNotSupportedExceptionortedException

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

WriteByte Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

Constructinstanceforreadingfromstream

publicBZip2InputStream(

Streamstream

);

Parametersstream

Datasource

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStreamConstructor

SharpZipCompressionLibrary

ThepropertiesoftheBZip2InputStreamclassarelistedbelow.ForacompletelistofBZip2InputStreamclassmembers,seetheBZip2InputStreamMemberstopic.

PublicInstancePropertiesCanRead Getsavalueindicatingifthe

streamsupportsreading

CanSeek Getsavalueindicatingwhetherthecurrentstreamsupportsseeking.

CanWrite Getsavalueindicatingwhetherthecurrentstreamsupportswriting.Thispropertyalwaysreturnsfalse

Length Getsthelengthinbytesofthestream.

Position Getsorsetsthestreamsposition.SettingthepositionisnotsupportedandwillthrowaNotSupportException

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStreamProperties

SharpZipCompressionLibrary

Getsavalueindicatingifthestreamsupportsreading

publicoverrideboolCanRead{get;}

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.CanReadProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportsseeking.

publicoverrideboolCanSeek{get;}

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.CanSeekProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportswriting.Thispropertyalwaysreturnsfalse

publicoverrideboolCanWrite{get;}

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.CanWriteProperty

SharpZipCompressionLibrary

Getsthelengthinbytesofthestream.

publicoverridelongLength{get;}

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.LengthProperty

SharpZipCompressionLibrary

Getsorsetsthestreamsposition.SettingthepositionisnotsupportedandwillthrowaNotSupportException

publicoverridelongPosition{get;set;}

ExceptionsExceptionType ConditionNotSupportedException Anyattempttosettheposition

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheBZip2InputStreamclassarelistedbelow.ForacompletelistofBZip2InputStreamclassmembers,seetheBZip2InputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inherited

fromStream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Closesthestream,releasinganyassociatedresources.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject)

DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushesthestream.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

BZip2InputStreamMethods

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readasequenceofbytesandadvancesthereadpositionbyonebyte.

ReadByte Readabytefromstreamadvancingposition

Seek Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

SetLength Setsthelengthofthisstreamtothegivenvalue.ThisoperationisnotsupportedandwillthrowaNotSupportedExceptionortedException

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

WriteByte Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

Closesthestream,releasinganyassociatedresources.

publicoverridevoidClose();

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.CloseMethod

SharpZipCompressionLibrary

Flushesthestream.

publicoverridevoidFlush();

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.FlushMethod

SharpZipCompressionLibrary

Readasequenceofbytesandadvancesthereadpositionbyonebyte.

publicoverrideintRead(

byte[]b,

intoffset,

intcount

);

Parametersb

Arrayofbytestostorevaluesin

offsetOffsetinarraytobeginstoringdata

countThemaximumnumberofbytestoread

ReturnValueThetotalnumberofbytesreadintothebuffer.Thismightbelessthanthenumberofbytesrequestedifthatnumberofbytesarenotcurrentlyavailableorzeroiftheendofthestreamisreached.

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.ReadMethod

SharpZipCompressionLibrary

Readabytefromstreamadvancingposition

publicoverrideintReadByte();

ReturnValuebytereador-1onendofstream

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.ReadByteMethod

SharpZipCompressionLibrary

Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.SeekMethod

SharpZipCompressionLibrary

Setsthelengthofthisstreamtothegivenvalue.ThisoperationisnotsupportedandwillthrowaNotSupportedExceptionortedException

publicoverridevoidSetLength(

longval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.SetLengthMethod

SharpZipCompressionLibrary

Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridevoidWrite(

byte[]array,

intoffset,

intcount

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.WriteMethod

SharpZipCompressionLibrary

Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridevoidWriteByte(

byteval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoBZip2InputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2InputStream.WriteByteMethod

SharpZipCompressionLibrary

AnoutputstreamthatcompressesintotheBZip2formatincludingfileheadercharsintoanotherstream.

Foralistofallmembersofthistype,seeBZip2OutputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.BZip2.BZip2OutputStream

publicclassBZip2OutputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.BZip2Assembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoBZip2OutputStreamMembers|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStreamClass

SharpZipCompressionLibrary

BZip2OutputStreamoverview

PublicInstanceConstructorsBZip2OutputStream Overloaded.Initializesanew

instanceoftheBZip2OutputStreamclass.

PublicInstancePropertiesCanRead Getsavalueindicatingwhether

thecurrentstreamsupportsreading

CanSeek Getsavalueindicatingwhetherthecurrentstreamsupportsseeking

CanWrite Getsavalueindicatingwhetherthecurrentstreamsupportswriting

Length Getsthelengthinbytesofthestream

Position Getsorsetsthecurrentpositionofthisstream.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Endthecurrentblockandendcompression.Closethestreamandfreeanyresources

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformation

BZip2OutputStreamMembers

requiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushoutputbuffers

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytes

ReadByte Readabytefromthestreamadvancingtheposition.

Seek Setsthecurrentpositionofthisstreamtothegivenvalue.

SetLength Setsthelengthofthisstreamtothegivenvalue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writeablockofbytestothestream

WriteByte Writeabytetothestream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize Freeanyresourcesandothercleanupbeforegarbagecollectionreclaimsmemory

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

Constructadefaultoutputstreamwithmaximumblocksize

OverloadListConstructadefaultoutputstreamwithmaximumblocksize

publicBZip2OutputStream(Stream);

InitialiseanewinstanceoftheBZip2OutputStreamforthespecifiedstream,usingthegivenblocksize.

publicBZip2OutputStream(Stream,int);

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStreamConstructor

SharpZipCompressionLibrary

Constructadefaultoutputstreamwithmaximumblocksize

publicBZip2OutputStream(

Streamstream

);

Parametersstream

ThestreamtowriteBZipdataonto.

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace|BZip2OutputStreamConstructorOverloadList

BZip2OutputStreamConstructor(Stream)

SharpZipCompressionLibrary

InitialiseanewinstanceoftheBZip2OutputStreamforthespecifiedstream,usingthegivenblocksize.

publicBZip2OutputStream(

Streamstream,

intblockSize

);

Parametersstream

Thestreamtowritecompresseddatato.

blockSizeTheblocksizetouse.

RemarksValidblocksizesareintherange1..9,with1givingthelowestcompressionand9thehighest.

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace|BZip2OutputStreamConstructorOverloadList

BZip2OutputStreamConstructor(Stream,Int32)

SharpZipCompressionLibrary

ThepropertiesoftheBZip2OutputStreamclassarelistedbelow.ForacompletelistofBZip2OutputStreamclassmembers,seetheBZip2OutputStreamMemberstopic.

PublicInstancePropertiesCanRead Getsavalueindicatingwhether

thecurrentstreamsupportsreading

CanSeek Getsavalueindicatingwhetherthecurrentstreamsupportsseeking

CanWrite Getsavalueindicatingwhetherthecurrentstreamsupportswriting

Length Getsthelengthinbytesofthestream

Position Getsorsetsthecurrentpositionofthisstream.

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStreamProperties

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

publicoverrideboolCanRead{get;}

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.CanReadProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportsseeking

publicoverrideboolCanSeek{get;}

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.CanSeekProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportswriting

publicoverrideboolCanWrite{get;}

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.CanWriteProperty

SharpZipCompressionLibrary

Getsthelengthinbytesofthestream

publicoverridelongLength{get;}

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.LengthProperty

SharpZipCompressionLibrary

Getsorsetsthecurrentpositionofthisstream.

publicoverridelongPosition{get;set;}

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheBZip2OutputStreamclassarelistedbelow.ForacompletelistofBZip2OutputStreamclassmembers,seetheBZip2OutputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Endthecurrentblockandendcompression.Closethestreamandfreeanyresources

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushoutputbuffers

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

BZip2OutputStreamMethods

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytes

ReadByte Readabytefromthestreamadvancingtheposition.

Seek Setsthecurrentpositionofthisstreamtothegivenvalue.

SetLength Setsthelengthofthisstreamtothegivenvalue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writeablockofbytestothestream

WriteByte Writeabytetothestream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize Freeanyresourcesandothercleanupbeforegarbagecollectionreclaimsmemory

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

SharpZipCompressionLibrary

Endthecurrentblockandendcompression.Closethestreamandfreeanyresources

publicoverridevoidClose();

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.CloseMethod

SharpZipCompressionLibrary

Freeanyresourcesandothercleanupbeforegarbagecollectionreclaimsmemory

protectedoverridevoidFinalize();

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.FinalizeMethod

SharpZipCompressionLibrary

Flushoutputbuffers

publicoverridevoidFlush();

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.FlushMethod

SharpZipCompressionLibrary

SharpZipCompressionLibrary

Readabytefromthestreamadvancingtheposition.

publicoverrideintReadByte();

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.ReadByteMethod

SharpZipCompressionLibrary

Setsthecurrentpositionofthisstreamtothegivenvalue.

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.SeekMethod

SharpZipCompressionLibrary

Setsthelengthofthisstreamtothegivenvalue.

publicoverridevoidSetLength(

longval

);

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.SetLengthMethod

SharpZipCompressionLibrary

SharpZipCompressionLibrary

Writeabytetothestream.

publicoverridevoidWriteByte(

bytebv

);

SeeAlsoBZip2OutputStreamClass|ICSharpCode.SharpZipLib.BZip2Namespace

BZip2OutputStream.WriteByteMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionAdler32 ComputesAdler32checksumforastreamofdata.AnAdler32checksumis

notasreliableasaCRC32checksum,butalotfastertocompute.ThespecificationforAdler32maybefoundinRFC1950.ZLIBCompressedDataFormatSpecificationversion3.3)Fromthatdocument:"ADLER32(Adler-32checksum)Thiscontainsachecksumvalueoftheuncompresseddata(excludinganydictionarydata)computedaccordingtoAdler-32algorithm.Thisalgorithmisa32-bitextensionandimprovementoftheFletcheralgorithm,usedintheITU-TX.224/ISO8073standard.Adler-32iscomposedoftwosumsaccumulatedperbyte:s1isthesumofallbytes,s2isthesumofalls1values.Bothsumsaredonemodulo65521.s1isinitializedto1,s2tozero.TheAdler-32checksumisstoredass2*65536+s1inmost-significant-bytefirst(network)order.""8.2.TheAdler-32algorithmTheAdler-32algorithmismuchfasterthantheCRC32algorithmyetstillprovidesanextremelylowprobabilityofundetectederrors.Themoduloonunsignedlongaccumulatorscanbedelayedfor5552bytes,sothemodulooperationtimeisnegligible.Ifthebytesarea,b,c,thesecondsumis3a+2b+c+3,andsoispositionandordersensitive,unlikethefirstsum,whichisjustachecksum.That65521isprimeisimportanttoavoidapossiblelargeclassoftwo-byteerrorsthatleavethecheckunchanged.(TheFletcherchecksumuses255,whichisnotprimeandwhichalsomakestheFletchercheckinsensitivetosinglebytechanges0-255.)Thesums1isinitializedto1insteadofzerotomakethelengthofthesequencepartofs2,sothatthelengthdoesnothavetobecheckedseparately.(AnysequenceofzeroeshasaFletcherchecksumofzero.)"

Crc32 Generateatableforabyte-wise32-bitCRCcalculationonthepolynomial:x^32+x^26+x^23+x^22+x^16+x^12+x^11+x^10+x^8+x^7+x^5+x^4+x^2+x+1.PolynomialsoverGF(2)arerepresentedinbinary,onebitpercoefficient,withthelowestpowersinthemostsignificantbit.Thenaddingpolynomialsisjustexclusive-or,andmultiplyingapolynomialbyxisarightshiftbyone.Ifwecalltheabovepolynomialp,andrepresentabyteasthepolynomialq,alsowiththelowestpowerinthemostsignificantbit(sothebyte0xb1isthe

ICSharpCode.SharpZipLib.ChecksumsNamespace

polynomialx^7+x^3+x+1),thentheCRCis(q*x^32)modp,whereamodbmeanstheremainderafterdividingabyb.Thiscalculationisdoneusingtheshift-registermethodofmultiplyingandtakingtheremainder.Theregisterisinitializedtozero,andforeachincomingbit,x^32isaddedmodptotheregisterifthebitisaone(wherex^32modpisp+x^32=x^26+...+1),andtheregisterismultipliedmodpbyx(whichisshiftingrightbyoneandaddingx^32modpifthebitshiftedoutisaone).Westartwiththehighestpower(leastsignificantbit)ofqandrepeatforalleightbitsofq.ThetableissimplytheCRCofallpossibleeightbitvalues.ThisisalltheinformationneededtogenerateCRC'sondataabyteatatimeforallcombinationsofCRCregistervaluesandincomingbytes.

StrangeCRC Bzip2checksumalgorithm

InterfacesInterface DescriptionIChecksum Interfacetocomputeadata

checksumusedbycheckedinput/outputstreams.Adatachecksumcanbeupdatedbyonebyteorwithabytearray.Aftereachupdatethevalueofthecurrentchecksumcanbereturnedbycalling

getValue

.Thecompletechecksumobjectcanalsoberesetsoitcanbeusedagainwithnewdata.

SharpZipCompressionLibrary

ComputesAdler32checksumforastreamofdata.AnAdler32checksumisnotasreliableasaCRC32checksum,butalotfastertocompute.ThespecificationforAdler32maybefoundinRFC1950.ZLIBCompressedDataFormatSpecificationversion3.3)Fromthatdocument:"ADLER32(Adler-32checksum)Thiscontainsachecksumvalueoftheuncompresseddata(excludinganydictionarydata)computedaccordingtoAdler-32algorithm.Thisalgorithmisa32-bitextensionandimprovementoftheFletcheralgorithm,usedintheITU-TX.224/ISO8073standard.Adler-32iscomposedoftwosumsaccumulatedperbyte:s1isthesumofallbytes,s2isthesumofalls1values.Bothsumsaredonemodulo65521.s1isinitializedto1,s2tozero.TheAdler-32checksumisstoredass2*65536+s1inmost-significant-bytefirst(network)order.""8.2.TheAdler-32algorithmTheAdler-32algorithmismuchfasterthantheCRC32algorithmyetstillprovidesanextremelylowprobabilityofundetectederrors.Themoduloonunsignedlongaccumulatorscanbedelayedfor5552bytes,sothemodulooperationtimeisnegligible.Ifthebytesarea,b,c,thesecondsumis3a+2b+c+3,andsoispositionandordersensitive,unlikethefirstsum,whichisjustachecksum.That65521isprimeisimportanttoavoidapossiblelargeclassoftwo-byteerrorsthatleavethecheckunchanged.(TheFletcherchecksumuses255,whichisnotprimeandwhichalsomakestheFletchercheckinsensitivetosinglebytechanges0-255.)Thesums1isinitializedto1insteadofzerotomakethelengthofthesequencepartofs2,sothatthelengthdoesnothavetobecheckedseparately.(AnysequenceofzeroeshasaFletcherchecksumofzero.)"

Foralistofallmembersofthistype,seeAdler32Members.

System.ObjectICSharpCode.SharpZipLib.Checksums.Adler32

publicsealedclassAdler32:IChecksum

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteed

Adler32Class

tobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ChecksumsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoAdler32Members|ICSharpCode.SharpZipLib.ChecksumsNamespace

SharpZipCompressionLibrary

Adler32overview

PublicInstanceConstructorsAdler32Constructor Createsanewinstanceofthe

Adler32class.Thechecksumstartsoffwithavalueof1.

PublicInstancePropertiesValue ReturnstheAdler32data

checksumcomputedsofar.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetstheAdler32checksumtotheinitialvalue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.Updatesthechecksumwiththebytestakenfromthearray.

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32Members

SharpZipCompressionLibrary

CreatesanewinstanceoftheAdler32class.Thechecksumstartsoffwithavalueof1.

publicAdler32();

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32Constructor

SharpZipCompressionLibrary

ThepropertiesoftheAdler32classarelistedbelow.ForacompletelistofAdler32classmembers,seetheAdler32Memberstopic.

PublicInstancePropertiesValue ReturnstheAdler32data

checksumcomputedsofar.

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32Properties

SharpZipCompressionLibrary

ReturnstheAdler32datachecksumcomputedsofar.

publiclongValue{get;}

ImplementsIChecksum.Value

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32.ValueProperty

SharpZipCompressionLibrary

ThemethodsoftheAdler32classarelistedbelow.ForacompletelistofAdler32classmembers,seetheAdler32Memberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetstheAdler32checksumtotheinitialvalue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.Updatesthechecksumwiththebytestakenfromthearray.

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32Methods

SharpZipCompressionLibrary

ResetstheAdler32checksumtotheinitialvalue.

publicvoidReset();

ImplementsIChecksum.Reset

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32.ResetMethod

SharpZipCompressionLibrary

Updatesthechecksumwithanarrayofbytes.

OverloadListUpdatesthechecksumwithanarrayofbytes.

publicvoidUpdate(byte[]);

Updatesthechecksumwiththebytestakenfromthearray.

publicvoidUpdate(byte[],int,int);

Updatesthechecksumwiththebyteb.

publicvoidUpdate(int);

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Adler32.UpdateMethod

SharpZipCompressionLibrary

Updatesthechecksumwithanarrayofbytes.

publicvoidUpdate(

byte[]buffer

);

Parametersbuffer

Thesourceofthedatatoupdatewith.

ImplementsIChecksum.Update

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Adler32.UpdateOverloadList

Adler32.UpdateMethod(Byte[])

SharpZipCompressionLibrary

Updatesthechecksumwiththebytestakenfromthearray.

publicvoidUpdate(

byte[]buf,

intoff,

intlen

);

Parametersbuf

anarrayofbytes

offthestartofthedatausedforthisupdate

lenthenumberofbytestouseforthisupdate

ImplementsIChecksum.Update

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Adler32.UpdateOverloadList

Adler32.UpdateMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Updatesthechecksumwiththebyteb.

publicvoidUpdate(

intbval

);

Parametersbval

Thedatavaluetoadd.Thehighbyteoftheintisignored.

ImplementsIChecksum.Update

SeeAlsoAdler32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Adler32.UpdateOverloadList

Adler32.UpdateMethod(Int32)

SharpZipCompressionLibrary

Generateatableforabyte-wise32-bitCRCcalculationonthepolynomial:x^32+x^26+x^23+x^22+x^16+x^12+x^11+x^10+x^8+x^7+x^5+x^4+x^2+x+1.PolynomialsoverGF(2)arerepresentedinbinary,onebitpercoefficient,withthelowestpowersinthemostsignificantbit.Thenaddingpolynomialsisjustexclusive-or,andmultiplyingapolynomialbyxisarightshiftbyone.Ifwecalltheabovepolynomialp,andrepresentabyteasthepolynomialq,alsowiththelowestpowerinthemostsignificantbit(sothebyte0xb1isthepolynomialx^7+x^3+x+1),thentheCRCis(q*x^32)modp,whereamodbmeanstheremainderafterdividingabyb.Thiscalculationisdoneusingtheshift-registermethodofmultiplyingandtakingtheremainder.Theregisterisinitializedtozero,andforeachincomingbit,x^32isaddedmodptotheregisterifthebitisaone(wherex^32modpisp+x^32=x^26+...+1),andtheregisterismultipliedmodpbyx(whichisshiftingrightbyoneandaddingx^32modpifthebitshiftedoutisaone).Westartwiththehighestpower(leastsignificantbit)ofqandrepeatforalleightbitsofq.ThetableissimplytheCRCofallpossibleeightbitvalues.ThisisalltheinformationneededtogenerateCRC'sondataabyteatatimeforallcombinationsofCRCregistervaluesandincomingbytes.

Foralistofallmembersofthistype,seeCrc32Members.

System.ObjectICSharpCode.SharpZipLib.Checksums.Crc32

publicsealedclassCrc32:IChecksum

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ChecksumsAssembly:ICSharpCode.SharpZipLib(in

Crc32Class

ICSharpCode.SharpZipLib.dll)

SeeAlsoCrc32Members|ICSharpCode.SharpZipLib.ChecksumsNamespace

SharpZipCompressionLibrary

Crc32overview

PublicInstanceConstructorsCrc32Constructor Initializesanewinstanceofthe

Crc32class.

PublicInstancePropertiesValue ReturnstheCRC32data

checksumcomputedsofar.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetstheCRC32datachecksumasifnoupdatewasevercalled.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.Addsthebytearraytothedatachecksum.

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32Members

SharpZipCompressionLibrary

InitializesanewinstanceoftheCrc32class.

publicCrc32();

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32Constructor

SharpZipCompressionLibrary

ThepropertiesoftheCrc32classarelistedbelow.ForacompletelistofCrc32classmembers,seetheCrc32Memberstopic.

PublicInstancePropertiesValue ReturnstheCRC32data

checksumcomputedsofar.

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32Properties

SharpZipCompressionLibrary

ReturnstheCRC32datachecksumcomputedsofar.

publiclongValue{get;set;}

ImplementsIChecksum.Value

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32.ValueProperty

SharpZipCompressionLibrary

ThemethodsoftheCrc32classarelistedbelow.ForacompletelistofCrc32classmembers,seetheCrc32Memberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetstheCRC32datachecksumasifnoupdatewasevercalled.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.Addsthebytearraytothedatachecksum.

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32Methods

SharpZipCompressionLibrary

ResetstheCRC32datachecksumasifnoupdatewasevercalled.

publicvoidReset();

ImplementsIChecksum.Reset

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32.ResetMethod

SharpZipCompressionLibrary

Updatesthechecksumwiththebytestakenfromthearray.

OverloadListUpdatesthechecksumwiththebytestakenfromthearray.

publicvoidUpdate(byte[]);

Addsthebytearraytothedatachecksum.

publicvoidUpdate(byte[],int,int);

Updatesthechecksumwiththeintbval.

publicvoidUpdate(int);

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace

Crc32.UpdateMethod

SharpZipCompressionLibrary

Updatesthechecksumwiththebytestakenfromthearray.

publicvoidUpdate(

byte[]buffer

);

Parametersbuffer

bufferanarrayofbytes

ImplementsIChecksum.Update

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Crc32.UpdateOverloadList

Crc32.UpdateMethod(Byte[])

SharpZipCompressionLibrary

Addsthebytearraytothedatachecksum.

publicvoidUpdate(

byte[]buf,

intoff,

intlen

);

Parametersbuf

thebufferwhichcontainsthedata

offtheoffsetinthebufferwherethedatastarts

lenthelengthofthedata

ImplementsIChecksum.Update

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Crc32.UpdateOverloadList

Crc32.UpdateMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Updatesthechecksumwiththeintbval.

publicvoidUpdate(

intbval

);

Parametersbval

thebyteistakenasthelower8bitsofbval

ImplementsIChecksum.Update

SeeAlsoCrc32Class|ICSharpCode.SharpZipLib.ChecksumsNamespace|Crc32.UpdateOverloadList

Crc32.UpdateMethod(Int32)

SharpZipCompressionLibrary

Interfacetocomputeadatachecksumusedbycheckedinput/outputstreams.Adatachecksumcanbeupdatedbyonebyteorwithabytearray.Aftereachupdatethevalueofthecurrentchecksumcanbereturnedbycalling

getValue

.Thecompletechecksumobjectcanalsoberesetsoitcanbeusedagainwithnewdata.

Foralistofallmembersofthistype,seeIChecksumMembers.

publicinterfaceIChecksum

TypesthatimplementIChecksumType DescriptionAdler32 ComputesAdler32checksumforastreamofdata.AnAdler32checksumis

notasreliableasaCRC32checksum,butalotfastertocompute.ThespecificationforAdler32maybefoundinRFC1950.ZLIBCompressedDataFormatSpecificationversion3.3)Fromthatdocument:"ADLER32(Adler-32checksum)Thiscontainsachecksumvalueoftheuncompresseddata(excludinganydictionarydata)computedaccordingtoAdler-32algorithm.Thisalgorithmisa32-bitextensionandimprovementoftheFletcheralgorithm,usedintheITU-TX.224/ISO8073standard.Adler-32iscomposedoftwosumsaccumulatedperbyte:s1isthesumofallbytes,s2isthesumofalls1values.Bothsumsaredonemodulo65521.s1isinitializedto1,s2tozero.TheAdler-32checksumisstoredass2*65536+s1inmost-significant-bytefirst(network)order.""8.2.TheAdler-32algorithmTheAdler-32algorithmismuchfasterthantheCRC32algorithmyetstillprovidesanextremelylowprobabilityofundetectederrors.Themoduloonunsignedlongaccumulatorscanbedelayedfor5552bytes,sothemodulooperationtimeisnegligible.Ifthebytesarea,b,c,thesecondsumis3a+2b+c+3,andsoispositionandordersensitive,unlikethefirstsum,whichisjustachecksum.That65521isprimeisimportanttoavoidapossiblelargeclassoftwo-byteerrorsthatleavethecheckunchanged.(TheFletcherchecksumuses255,whichisnotprimeandwhichalso

IChecksumInterface

makestheFletchercheckinsensitivetosinglebytechanges0-255.)Thesums1isinitializedto1insteadofzerotomakethelengthofthesequencepartofs2,sothatthelengthdoesnothavetobecheckedseparately.(AnysequenceofzeroeshasaFletcherchecksumofzero.)"

Crc32 Generateatableforabyte-wise32-bitCRCcalculationonthepolynomial:x^32+x^26+x^23+x^22+x^16+x^12+x^11+x^10+x^8+x^7+x^5+x^4+x^2+x+1.PolynomialsoverGF(2)arerepresentedinbinary,onebitpercoefficient,withthelowestpowersinthemostsignificantbit.Thenaddingpolynomialsisjustexclusive-or,andmultiplyingapolynomialbyxisarightshiftbyone.Ifwecalltheabovepolynomialp,andrepresentabyteasthepolynomialq,alsowiththelowestpowerinthemostsignificantbit(sothebyte0xb1isthepolynomialx^7+x^3+x+1),thentheCRCis(q*x^32)modp,whereamodbmeanstheremainderafterdividingabyb.Thiscalculationisdoneusingtheshift-registermethodofmultiplyingandtakingtheremainder.Theregisterisinitializedtozero,andforeachincomingbit,x^32isaddedmodptotheregisterifthebitisaone(wherex^32modpisp+x^32=x^26+...+1),andtheregisterismultipliedmodpbyx(whichisshiftingrightbyoneandaddingx^32modpifthebitshiftedoutisaone).Westartwiththehighestpower(leastsignificantbit)ofqandrepeatforalleightbitsofq.ThetableissimplytheCRCofallpossibleeightbitvalues.ThisisalltheinformationneededtogenerateCRC'sondataabyteatatimeforallcombinationsofCRCregistervaluesandincomingbytes.

StrangeCRC Bzip2checksumalgorithm

RequirementsNamespace:ICSharpCode.SharpZipLib.ChecksumsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoIChecksumMembers|ICSharpCode.SharpZipLib.ChecksumsNamespace

SharpZipCompressionLibrary

IChecksumoverview

PublicInstancePropertiesValue Returnsthedatachecksum

computedsofar.

PublicInstanceMethodsReset Resetsthedatachecksumasif

noupdatewasevercalled.

Update Overloaded.Addsthebytearraytothedatachecksum.

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksumMembers

SharpZipCompressionLibrary

ThepropertiesoftheIChecksuminterfacearelistedbelow.ForacompletelistofIChecksuminterfacemembers,seetheIChecksumMemberstopic.

PublicInstancePropertiesValue Returnsthedatachecksum

computedsofar.

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksumProperties

SharpZipCompressionLibrary

Returnsthedatachecksumcomputedsofar.

longValue{get;}

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksum.ValueProperty

SharpZipCompressionLibrary

ThemethodsoftheIChecksuminterfacearelistedbelow.ForacompletelistofIChecksuminterfacemembers,seetheIChecksumMemberstopic.

PublicInstanceMethodsReset Resetsthedatachecksumasif

noupdatewasevercalled.

Update Overloaded.Addsthebytearraytothedatachecksum.

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksumMethods

SharpZipCompressionLibrary

Resetsthedatachecksumasifnoupdatewasevercalled.

voidReset();

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksum.ResetMethod

SharpZipCompressionLibrary

Updatesthedatachecksumwiththebytestakenfromthearray.

OverloadListUpdatesthedatachecksumwiththebytestakenfromthearray.

voidUpdate(byte[]);

Addsthebytearraytothedatachecksum.

voidUpdate(byte[],int,int);

Addsonebytetothedatachecksum.

voidUpdate(int);

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace

IChecksum.UpdateMethod

SharpZipCompressionLibrary

Updatesthedatachecksumwiththebytestakenfromthearray.

voidUpdate(

byte[]buffer

);

Parametersbuffer

bufferanarrayofbytes

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace|IChecksum.UpdateOverloadList

IChecksum.UpdateMethod(Byte[])

SharpZipCompressionLibrary

Addsthebytearraytothedatachecksum.

voidUpdate(

byte[]buf,

intoff,

intlen

);

Parametersbuf

thebufferwhichcontainsthedata

offtheoffsetinthebufferwherethedatastarts

lenthelengthofthedata

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace|IChecksum.UpdateOverloadList

IChecksum.UpdateMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Addsonebytetothedatachecksum.

voidUpdate(

intbval

);

Parametersbval

thedatavaluetoadd.Thehighbyteoftheintisignored.

SeeAlsoIChecksumInterface|ICSharpCode.SharpZipLib.ChecksumsNamespace|IChecksum.UpdateOverloadList

IChecksum.UpdateMethod(Int32)

SharpZipCompressionLibrary

Bzip2checksumalgorithm

Foralistofallmembersofthistype,seeStrangeCRCMembers.

System.ObjectICSharpCode.SharpZipLib.Checksums.StrangeCRC

publicclassStrangeCRC:IChecksum

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ChecksumsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoStrangeCRCMembers|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRCClass

SharpZipCompressionLibrary

StrangeCRCoverview

PublicInstanceConstructorsStrangeCRCConstructor Initialiseadefaultinstanceof

StrangeCRC

PublicInstancePropertiesValue GetthecurrentCrcvalue.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetthestateofCrc.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.UpdateCrcbasedonaportionofablockofdata

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

StrangeCRCMembers

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

SharpZipCompressionLibrary

InitialiseadefaultinstanceofStrangeCRC

publicStrangeCRC();

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRCConstructor

SharpZipCompressionLibrary

ThepropertiesoftheStrangeCRCclassarelistedbelow.ForacompletelistofStrangeCRCclassmembers,seetheStrangeCRCMemberstopic.

PublicInstancePropertiesValue GetthecurrentCrcvalue.

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRCProperties

SharpZipCompressionLibrary

GetthecurrentCrcvalue.

publiclongValue{get;}

ImplementsIChecksum.Value

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRC.ValueProperty

SharpZipCompressionLibrary

ThemethodsoftheStrangeCRCclassarelistedbelow.ForacompletelistofStrangeCRCclassmembers,seetheStrangeCRCMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset ResetthestateofCrc.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Update Overloaded.UpdateCrcbasedonaportionofablockofdata

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRCMethods

SharpZipCompressionLibrary

ResetthestateofCrc.

publicvoidReset();

ImplementsIChecksum.Reset

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRC.ResetMethod

SharpZipCompressionLibrary

UpdateCrcbasedonablockofdata

OverloadListUpdateCrcbasedonablockofdata

publicvoidUpdate(byte[]);

UpdateCrcbasedonaportionofablockofdata

publicvoidUpdate(byte[],int,int);

UpdatetheCrcvalue.

publicvoidUpdate(int);

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace

StrangeCRC.UpdateMethod

SharpZipCompressionLibrary

UpdateCrcbasedonablockofdata

publicvoidUpdate(

byte[]buf

);

ImplementsIChecksum.Update

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace|StrangeCRC.UpdateOverloadList

StrangeCRC.UpdateMethod(Byte[])

SharpZipCompressionLibrary

UpdateCrcbasedonaportionofablockofdata

publicvoidUpdate(

byte[]buf,

intoff,

intlen

);

Parametersbuf

blockofdata

offindexoffirstbytetouse

lennumberofbytestouse

ImplementsIChecksum.Update

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace|StrangeCRC.UpdateOverloadList

StrangeCRC.UpdateMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

UpdatetheCrcvalue.

publicvoidUpdate(

intinCh

);

ParametersinCh

dataupdateisbasedon

ImplementsIChecksum.Update

SeeAlsoStrangeCRCClass|ICSharpCode.SharpZipLib.ChecksumsNamespace|StrangeCRC.UpdateOverloadList

StrangeCRC.UpdateMethod(Int32)

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionDirectoryEventArgs Eventargumentsfordirectories.

FileSystemScanner FileSystemScannerprovidesfacilitiesscanningoffilesanddirectories.

NameAndSizeFilter NameAnsSizeFilterfiltersbasedonnameandfilesize.

NameFilter NameFilterisastringmatchingclasswhichallowsforbothpositiveandnegativematching.AfilterisasequenceofindependantRegexregularexpressionsseparatedbysemi-colons';'Eachexpressioncanbeprefixedbyaplus'+'signoraminus'-'signtodenotetheexpressionisintendedtoincludeorexcludenames.IfneitheraplusorminussignisfoundincludeisthedefaultAgivennameistestedforinclusionbeforecheckingexclusions.Onlynamesmatchinganincludespecandnotmatchinganexcludespecaredeemedtomatchthefilter.Anemptyfiltermatchesanyname.

PathFilter PathFilterfiltersdirectoriesandfilesbyfullpathname.

ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgs Eventargumentsforscanning.

ScanFailureEventArgs Argumentspassedwhenscanfailuresaredetected.

InterfacesInterface DescriptionINameTransform INameTransformdefineshow

filesystemnamesaretransformedforusewitharchives.

IScanFilter Scanningfilterssupporttheseoperations.

DelegatesDelegate DescriptionDirectoryFailureDelegate Delegateinvokedwhena

directoryfailureisdetected.

FileFailureDelegate Delegateinvokedwhenafilefailureisdetected.

ProcessDirectoryDelegate Delegateinvokkedwhenadirectoryisprocessed.

ProcessFileDelegate Delegateinvokedwhenafileisprocessed.

SharpZipCompressionLibrary

Eventargumentsfordirectories.

Foralistofallmembersofthistype,seeDirectoryEventArgsMembers.

System.ObjectSystem.EventArgsICSharpCode.SharpZipLib.Core.ScanEventArgsICSharpCode.SharpZipLib.Core.DirectoryEventArgs

publicclassDirectoryEventArgs:

ScanEventArgs

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDirectoryEventArgsMembers|ICSharpCode.SharpZipLib.CoreNamespace

DirectoryEventArgsClass

SharpZipCompressionLibrary

DirectoryEventArgsoverview

PublicInstanceConstructorsDirectoryEventArgs

ConstructorInitializeaninstanceofDirectoryEventArgs.

PublicInstancePropertiesContinueRunning(inherited

fromScanEventArgs)Getsetavalueindicatingifscanningshouldcontinueornot.

HasMatchingFiles Getavalueindicatingifthedirectorycontainsanymatchingfilesornot.

Name(inheritedfromScanEventArgs)

Thenameforthisevent.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperform

DirectoryEventArgsMembers

othercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDirectoryEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

InitializeaninstanceofDirectoryEventArgs.

publicDirectoryEventArgs(

stringname,

boolhasMatchingFiles

);

Parametersname

Thenameforthisdirectory.

hasMatchingFilesFlagvalueindicatingifanymatchingfilesarecontainedinthisdirectory.

SeeAlsoDirectoryEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

DirectoryEventArgsConstructor

SharpZipCompressionLibrary

ThepropertiesoftheDirectoryEventArgsclassarelistedbelow.ForacompletelistofDirectoryEventArgsclassmembers,seetheDirectoryEventArgsMemberstopic.

PublicInstancePropertiesContinueRunning(inherited

fromScanEventArgs)Getsetavalueindicatingifscanningshouldcontinueornot.

HasMatchingFiles Getavalueindicatingifthedirectorycontainsanymatchingfilesornot.

Name(inheritedfromScanEventArgs)

Thenameforthisevent.

SeeAlsoDirectoryEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

DirectoryEventArgsProperties

SharpZipCompressionLibrary

Getavalueindicatingifthedirectorycontainsanymatchingfilesornot.

publicboolHasMatchingFiles{get;}

SeeAlsoDirectoryEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

DirectoryEventArgs.HasMatchingFilesProperty

SharpZipCompressionLibrary

Delegateinvokedwhenadirectoryfailureisdetected.

publicdelegatevoidDirectoryFailureDelegate(

objectsender,

ScanFailureEventArgse

);

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.CoreNamespace

DirectoryFailureDelegateDelegate

SharpZipCompressionLibrary

Delegateinvokedwhenafilefailureisdetected.

publicdelegatevoidFileFailureDelegate(

objectsender,

ScanFailureEventArgse

);

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.CoreNamespace

FileFailureDelegateDelegate

SharpZipCompressionLibrary

FileSystemScannerprovidesfacilitiesscanningoffilesanddirectories.

Foralistofallmembersofthistype,seeFileSystemScannerMembers.

System.ObjectICSharpCode.SharpZipLib.Core.FileSystemScanner

publicclassFileSystemScanner

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoFileSystemScannerMembers|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScannerClass

SharpZipCompressionLibrary

FileSystemScanneroverview

PublicInstanceConstructorsFileSystemScanner Overloaded.Initializesanew

instanceoftheFileSystemScannerclass.

PublicInstanceFieldsDirectoryFailure Delegatetoinvokewhena

directoryfailureisdetected.

FileFailure Delegatetoinvokewhenafilefailureisdetected.

ProcessDirectory Delegatetoinvokewhenadirectoryisprocessed.

ProcessFile Delegatetoinvokewhenafileisprocessed.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

OnDirectoryFailure RaisetheDirectoryFailureevent.

OnFileFailure RaisetheFileFailureevent.

OnProcessDirectory RaisetheProcessDirectory

FileSystemScannerMembers

event.

OnProcessFile RaisetheProcessFileevent.

Scan Scanadirectory.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofFileSystemScanner

OverloadListInitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(IScanFilter);

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(IScanFilter,IScanFilter);

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(string);

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(string,string);

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScannerConstructor

SharpZipCompressionLibrary

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(

stringfilter

);

Parametersfilter

Thefilefiltertoapplywhenscanning.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace|FileSystemScannerConstructorOverloadList

FileSystemScannerConstructor(String)

SharpZipCompressionLibrary

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(

stringfileFilter,

stringdirectoryFilter

);

ParametersfileFilter

ThefileNameFilterfiltertoapply.

directoryFilterThedirectoryNameFilterfiltertoapply.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace|FileSystemScannerConstructorOverloadList

FileSystemScannerConstructor(String,String)

SharpZipCompressionLibrary

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(

IScanFilterfileFilter

);

ParametersfileFilter

ThefileNameFilterfiltertoapply.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace|FileSystemScannerConstructorOverloadList

FileSystemScannerConstructor(IScanFilter)

SharpZipCompressionLibrary

InitialiseanewinstanceofFileSystemScanner

publicFileSystemScanner(

IScanFilterfileFilter,

IScanFilterdirectoryFilter

);

ParametersfileFilter

ThefileIScanFilterfiltertoapply.

directoryFilterThedirectoryIScanFilterfiltertoapply.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace|FileSystemScannerConstructorOverloadList

FileSystemScannerConstructor(IScanFilter,IScanFilter)

SharpZipCompressionLibrary

ThefieldsoftheFileSystemScannerclassarelistedbelow.ForacompletelistofFileSystemScannerclassmembers,seetheFileSystemScannerMemberstopic.

PublicInstanceFieldsDirectoryFailure Delegatetoinvokewhena

directoryfailureisdetected.

FileFailure Delegatetoinvokewhenafilefailureisdetected.

ProcessDirectory Delegatetoinvokewhenadirectoryisprocessed.

ProcessFile Delegatetoinvokewhenafileisprocessed.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScannerFields

SharpZipCompressionLibrary

Delegatetoinvokewhenadirectoryfailureisdetected.

publicDirectoryFailureDelegateDirectoryFailure;

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.DirectoryFailureField

SharpZipCompressionLibrary

Delegatetoinvokewhenafilefailureisdetected.

publicFileFailureDelegateFileFailure;

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.FileFailureField

SharpZipCompressionLibrary

Delegatetoinvokewhenadirectoryisprocessed.

publicProcessDirectoryDelegateProcessDirectory;

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.ProcessDirectoryField

SharpZipCompressionLibrary

Delegatetoinvokewhenafileisprocessed.

publicProcessFileDelegateProcessFile;

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.ProcessFileField

SharpZipCompressionLibrary

ThemethodsoftheFileSystemScannerclassarelistedbelow.ForacompletelistofFileSystemScannerclassmembers,seetheFileSystemScannerMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

OnDirectoryFailure RaisetheDirectoryFailureevent.

OnFileFailure RaisetheFileFailureevent.

OnProcessDirectory RaisetheProcessDirectoryevent.

OnProcessFile RaisetheProcessFileevent.

Scan Scanadirectory.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inherited Createsashallowcopyofthe

FileSystemScannerMethods

fromObject) currentObject.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

RaisetheDirectoryFailureevent.

publicvoidOnDirectoryFailure(

stringdirectory,

Exceptione

);

Parametersdirectory

Rhedirectoryname.

eTheexceptiondetected.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.OnDirectoryFailureMethod

SharpZipCompressionLibrary

RaisetheFileFailureevent.

publicvoidOnFileFailure(

stringfile,

Exceptione

);

Parametersfile

Thefilename.

eTheexceptiondetected.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.OnFileFailureMethod

SharpZipCompressionLibrary

RaisetheProcessDirectoryevent.

publicvoidOnProcessDirectory(

stringdirectory,

boolhasMatchingFiles

);

Parametersdirectory

Thedirectoryname.

hasMatchingFilesFlagindicatingifthedirectoryhasmatchingfiles.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.OnProcessDirectoryMethod

SharpZipCompressionLibrary

RaisetheProcessFileevent.

publicvoidOnProcessFile(

stringfile

);

Parametersfile

Thefilename.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.OnProcessFileMethod

SharpZipCompressionLibrary

Scanadirectory.

publicvoidScan(

stringdirectory,

boolrecurse

);

Parametersdirectory

Thebasedirectorytoscan.

recurseTruetorecursesubdirectories,falsetodoasingledirectory.

SeeAlsoFileSystemScannerClass|ICSharpCode.SharpZipLib.CoreNamespace

FileSystemScanner.ScanMethod

SharpZipCompressionLibrary

INameTransformdefineshowfilesystemnamesaretransformedforusewitharchives.

Foralistofallmembersofthistype,seeINameTransformMembers.

publicinterfaceINameTransform

TypesthatimplementINameTransformType DescriptionZipNameTransform ZipNameTransformtransforms

nameaspertheZipfileconvention.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoINameTransformMembers|ICSharpCode.SharpZipLib.CoreNamespace

INameTransformInterface

SharpZipCompressionLibrary

INameTransformoverview

PublicInstanceMethodsTransformDirectory Givenadirectoryname

determinethetransformedequivalent.

TransformFile Givenafilenamedeterminethetransformedequivalent.

SeeAlsoINameTransformInterface|ICSharpCode.SharpZipLib.CoreNamespace

INameTransformMembers

SharpZipCompressionLibrary

ThemethodsoftheINameTransforminterfacearelistedbelow.ForacompletelistofINameTransforminterfacemembers,seetheINameTransformMemberstopic.

PublicInstanceMethodsTransformDirectory Givenadirectoryname

determinethetransformedequivalent.

TransformFile Givenafilenamedeterminethetransformedequivalent.

SeeAlsoINameTransformInterface|ICSharpCode.SharpZipLib.CoreNamespace

INameTransformMethods

SharpZipCompressionLibrary

Givenadirectorynamedeterminethetransformedequivalent.

stringTransformDirectory(

stringname

);

Parametersname

Thenametotransform.

ReturnValueThetransformeddirectoryname

SeeAlsoINameTransformInterface|ICSharpCode.SharpZipLib.CoreNamespace

INameTransform.TransformDirectoryMethod

SharpZipCompressionLibrary

Givenafilenamedeterminethetransformedequivalent.

stringTransformFile(

stringname

);

Parametersname

Thenametotransform.

ReturnValueThetransformedname.

SeeAlsoINameTransformInterface|ICSharpCode.SharpZipLib.CoreNamespace

INameTransform.TransformFileMethod

SharpZipCompressionLibrary

Scanningfilterssupporttheseoperations.

Foralistofallmembersofthistype,seeIScanFilterMembers.

publicinterfaceIScanFilter

TypesthatimplementIScanFilterType DescriptionNameAndSizeFilter NameAnsSizeFilterfiltersbased

onnameandfilesize.

PathFilter PathFilterfiltersdirectoriesandfilesbyfullpathname.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoIScanFilterMembers|ICSharpCode.SharpZipLib.CoreNamespace

IScanFilterInterface

SharpZipCompressionLibrary

IScanFilteroverview

PublicInstanceMethodsIsMatch Testanametoseeifis

'matches'thefilter.

SeeAlsoIScanFilterInterface|ICSharpCode.SharpZipLib.CoreNamespace

IScanFilterMembers

SharpZipCompressionLibrary

ThemethodsoftheIScanFilterinterfacearelistedbelow.ForacompletelistofIScanFilterinterfacemembers,seetheIScanFilterMemberstopic.

PublicInstanceMethodsIsMatch Testanametoseeifis

'matches'thefilter.

SeeAlsoIScanFilterInterface|ICSharpCode.SharpZipLib.CoreNamespace

IScanFilterMethods

SharpZipCompressionLibrary

Testanametoseeifis'matches'thefilter.

boolIsMatch(

stringname

);

Parametersname

Thenametotest.

ReturnValueReturnstrueifthenamematchesthefilter,falseifitdoesnotmatch.

SeeAlsoIScanFilterInterface|ICSharpCode.SharpZipLib.CoreNamespace

IScanFilter.IsMatchMethod

SharpZipCompressionLibrary

NameAnsSizeFilterfiltersbasedonnameandfilesize.

Foralistofallmembersofthistype,seeNameAndSizeFilterMembers.

System.ObjectICSharpCode.SharpZipLib.Core.PathFilterICSharpCode.SharpZipLib.Core.NameAndSizeFilter

publicclassNameAndSizeFilter:

PathFilter

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoNameAndSizeFilterMembers|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilterClass

SharpZipCompressionLibrary

NameAndSizeFilteroverview

PublicInstanceConstructorsNameAndSizeFilter

ConstructorInitialiseanewinstanceofNameAndSizeFilter.

PublicInstancePropertiesMaxSize Themaximumsizeforafilethat

willmatchthisfilter.

MinSize Theminimumsizeforafilethatwillmatchthisfilter.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsMatch Testafilenametoseeifitmatchesthefilter.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedby

NameAndSizeFilterMembers

garbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofNameAndSizeFilter.

publicNameAndSizeFilter(

stringfilter,

longminSize,

longmaxSize

);

Parametersfilter

Thefiltertoapply.

minSizeTheminimumfilesizetoinclude.

maxSizeThemaximumfilesizetoinclude.

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilterConstructor

SharpZipCompressionLibrary

ThepropertiesoftheNameAndSizeFilterclassarelistedbelow.ForacompletelistofNameAndSizeFilterclassmembers,seetheNameAndSizeFilterMemberstopic.

PublicInstancePropertiesMaxSize Themaximumsizeforafilethat

willmatchthisfilter.

MinSize Theminimumsizeforafilethatwillmatchthisfilter.

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilterProperties

SharpZipCompressionLibrary

Themaximumsizeforafilethatwillmatchthisfilter.

publiclongMaxSize{get;set;}

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilter.MaxSizeProperty

SharpZipCompressionLibrary

Theminimumsizeforafilethatwillmatchthisfilter.

publiclongMinSize{get;set;}

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilter.MinSizeProperty

SharpZipCompressionLibrary

ThemethodsoftheNameAndSizeFilterclassarelistedbelow.ForacompletelistofNameAndSizeFilterclassmembers,seetheNameAndSizeFilterMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsMatch Testafilenametoseeifitmatchesthefilter.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilterMethods

SharpZipCompressionLibrary

Testafilenametoseeifitmatchesthefilter.

publicoverrideboolIsMatch(

stringfileName

);

ParametersfileName

Thefilenametotest.

ReturnValueTrueifthefiltermatches,falseotherwise.

ImplementsIScanFilter.IsMatch

SeeAlsoNameAndSizeFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameAndSizeFilter.IsMatchMethod

SharpZipCompressionLibrary

NameFilterisastringmatchingclasswhichallowsforbothpositiveandnegativematching.AfilterisasequenceofindependantRegexregularexpressionsseparatedbysemi-colons';'Eachexpressioncanbeprefixedbyaplus'+'signoraminus'-'signtodenotetheexpressionisintendedtoincludeorexcludenames.IfneitheraplusorminussignisfoundincludeisthedefaultAgivennameistestedforinclusionbeforecheckingexclusions.Onlynamesmatchinganincludespecandnotmatchinganexcludespecaredeemedtomatchthefilter.Anemptyfiltermatchesanyname.

Foralistofallmembersofthistype,seeNameFilterMembers.

System.ObjectICSharpCode.SharpZipLib.Core.NameFilter

publicclassNameFilter

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoNameFilterMembers|ICSharpCode.SharpZipLib.CoreNamespace

NameFilterClass

SharpZipCompressionLibrary

NameFilteroverview

PublicStaticMethodsIsValidExpression Testastringtoseeifitisavalid

regularexpression.

IsValidFilterExpression Testanexpressiontoseeifitisvalidasafilter.

PublicInstanceConstructorsNameFilterConstructor Constructaninstancebasedon

thefilterexpressionpassed

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsExcluded Testavaluetoseeifitisexcludedbythefilter.

IsIncluded Testavaluetoseeifitisincludedbythefilter.

IsMatch Testavaluetoseeifitmatchesthefilter.

ToString Convertthisfiltertoitsstringequivalent.

NameFilterMembers

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

Constructaninstancebasedonthefilterexpressionpassed

publicNameFilter(

stringfilter

);

Parametersfilter

Thefilterexpression.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilterConstructor

SharpZipCompressionLibrary

ThemethodsoftheNameFilterclassarelistedbelow.ForacompletelistofNameFilterclassmembers,seetheNameFilterMemberstopic.

PublicStaticMethodsIsValidExpression Testastringtoseeifitisavalid

regularexpression.

IsValidFilterExpression Testanexpressiontoseeifitisvalidasafilter.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsExcluded Testavaluetoseeifitisexcludedbythefilter.

IsIncluded Testavaluetoseeifitisincludedbythefilter.

IsMatch Testavaluetoseeifitmatchesthefilter.

ToString Convertthisfiltertoitsstringequivalent.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperform

NameFilterMethods

othercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

Testavaluetoseeifitisexcludedbythefilter.

publicboolIsExcluded(

stringtestValue

);

ParameterstestValue

Thevaluetotest.

ReturnValueTrueifthevalueisexcluded,falseotherwise.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.IsExcludedMethod

SharpZipCompressionLibrary

Testavaluetoseeifitisincludedbythefilter.

publicboolIsIncluded(

stringtestValue

);

ParameterstestValue

Thevaluetotest.

ReturnValueTrueifthevalueisincluded,falseotherwise.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.IsIncludedMethod

SharpZipCompressionLibrary

Testavaluetoseeifitmatchesthefilter.

publicboolIsMatch(

stringtestValue

);

ParameterstestValue

Thevaluetotest.

ReturnValueTrueifthevaluematches,falseotherwise.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.IsMatchMethod

SharpZipCompressionLibrary

Testastringtoseeifitisavalidregularexpression.

publicstaticboolIsValidExpression(

stringe

);

Parameterse

Theexpressiontotest.

ReturnValueTrueifexpressionisavalidRegexfalseotherwise.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.IsValidExpressionMethod

SharpZipCompressionLibrary

Testanexpressiontoseeifitisvalidasafilter.

publicstaticboolIsValidFilterExpression(

stringtoTest

);

ParameterstoTest

Thefilterexpressiontotest.

ReturnValueTrueiftheexpressionisvalid,falseotherwise.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.IsValidFilterExpressionMethod

SharpZipCompressionLibrary

Convertthisfiltertoitsstringequivalent.

publicoverridestringToString();

ReturnValueThestringequivalentforthisfilter.

SeeAlsoNameFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

NameFilter.ToStringMethod

SharpZipCompressionLibrary

PathFilterfiltersdirectoriesandfilesbyfullpathname.

Foralistofallmembersofthistype,seePathFilterMembers.

System.ObjectICSharpCode.SharpZipLib.Core.PathFilterICSharpCode.SharpZipLib.Core.NameAndSizeFilter

publicclassPathFilter:IScanFilter

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoPathFilterMembers|ICSharpCode.SharpZipLib.CoreNamespace

PathFilterClass

SharpZipCompressionLibrary

PathFilteroverview

PublicInstanceConstructorsPathFilterConstructor Initialiseanewinstanceof

PathFilter.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsMatch Testanametoseeifitmatchesthefilter.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPathFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

PathFilterMembers

SharpZipCompressionLibrary

InitialiseanewinstanceofPathFilter.

publicPathFilter(

stringfilter

);

Parametersfilter

TheNameFilterfilterexpressiontoapply.

SeeAlsoPathFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

PathFilterConstructor

SharpZipCompressionLibrary

ThemethodsofthePathFilterclassarelistedbelow.ForacompletelistofPathFilterclassmembers,seethePathFilterMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsMatch Testanametoseeifitmatchesthefilter.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPathFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

PathFilterMethods

SharpZipCompressionLibrary

Testanametoseeifitmatchesthefilter.

publicvirtualboolIsMatch(

stringname

);

Parametersname

Thenametotest.

ReturnValueTrueifthenamematches,falseotherwise.

ImplementsIScanFilter.IsMatch

SeeAlsoPathFilterClass|ICSharpCode.SharpZipLib.CoreNamespace

PathFilter.IsMatchMethod

SharpZipCompressionLibrary

Delegateinvokkedwhenadirectoryisprocessed.

publicdelegatevoidProcessDirectoryDelegate(

objectSender,

DirectoryEventArgse

);

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.CoreNamespace

ProcessDirectoryDelegateDelegate

SharpZipCompressionLibrary

Delegateinvokedwhenafileisprocessed.

publicdelegatevoidProcessFileDelegate(

objectsender,

ScanEventArgse

);

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.CoreNamespace

ProcessFileDelegateDelegate

SharpZipCompressionLibrary

Eventargumentsforscanning.

Foralistofallmembersofthistype,seeScanEventArgsMembers.

System.ObjectSystem.EventArgsICSharpCode.SharpZipLib.Core.ScanEventArgsICSharpCode.SharpZipLib.Core.DirectoryEventArgs

publicclassScanEventArgs:EventArgs

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoScanEventArgsMembers|ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgsClass

SharpZipCompressionLibrary

ScanEventArgsoverview

PublicInstanceConstructorsScanEventArgsConstructor Initialiseanewinstanceof

ScanEventArgs

PublicInstancePropertiesContinueRunning Getsetavalueindicatingif

scanningshouldcontinueornot.

Name Thenameforthisevent.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inherited Createsashallowcopyofthe

ScanEventArgsMembers

fromObject) currentObject.

SeeAlsoScanEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofScanEventArgs

publicScanEventArgs(

stringname

);

Parametersname

SeeAlsoScanEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgsConstructor

SharpZipCompressionLibrary

ThepropertiesoftheScanEventArgsclassarelistedbelow.ForacompletelistofScanEventArgsclassmembers,seetheScanEventArgsMemberstopic.

PublicInstancePropertiesContinueRunning Getsetavalueindicatingif

scanningshouldcontinueornot.

Name Thenameforthisevent.

SeeAlsoScanEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgsProperties

SharpZipCompressionLibrary

Getsetavalueindicatingifscanningshouldcontinueornot.

publicboolContinueRunning{get;set;}

SeeAlsoScanEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgs.ContinueRunningProperty

SharpZipCompressionLibrary

Thenameforthisevent.

publicstringName{get;}

SeeAlsoScanEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanEventArgs.NameProperty

SharpZipCompressionLibrary

Argumentspassedwhenscanfailuresaredetected.

Foralistofallmembersofthistype,seeScanFailureEventArgsMembers.

System.ObjectICSharpCode.SharpZipLib.Core.ScanFailureEventArgs

publicclassScanFailureEventArgs

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.CoreAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoScanFailureEventArgsMembers|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgsClass

SharpZipCompressionLibrary

ScanFailureEventArgsoverview

PublicInstanceConstructorsScanFailureEventArgs

ConstructorInitialiseanewinstanceofScanFailureEventArgs

PublicInstancePropertiesContinueRunning Get/setavalueindicating

wetherscanningshouldcontinue.

Exception Theapplicableexception.

Name Theapplicablename.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

ScanFailureEventArgsMembers

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofScanFailureEventArgs

publicScanFailureEventArgs(

stringname,

Exceptione

);

Parametersname

Thenametoapply.

eTheexceptiontouse.

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgsConstructor

SharpZipCompressionLibrary

ThepropertiesoftheScanFailureEventArgsclassarelistedbelow.ForacompletelistofScanFailureEventArgsclassmembers,seetheScanFailureEventArgsMemberstopic.

PublicInstancePropertiesContinueRunning Get/setavalueindicating

wetherscanningshouldcontinue.

Exception Theapplicableexception.

Name Theapplicablename.

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgsProperties

SharpZipCompressionLibrary

Get/setavalueindicatingwetherscanningshouldcontinue.

publicboolContinueRunning{get;set;}

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgs.ContinueRunningProperty

SharpZipCompressionLibrary

Theapplicableexception.

publicSystem.ExceptionException{get;}

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgs.ExceptionProperty

SharpZipCompressionLibrary

Theapplicablename.

publicstringName{get;}

SeeAlsoScanFailureEventArgsClass|ICSharpCode.SharpZipLib.CoreNamespace

ScanFailureEventArgs.NameProperty

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionPkzipClassic PkzipClassicembodiesthe

classicororiginalencryptionfacilitiesusedinPkziparchives.Whileithasbeensupercededbymorerecentandmorepowerfulalgorithms,itsstillinuseandisviableforpreventingcasualsnooping

PkzipClassicManaged DefinesawrapperobjecttoaccessthePkzipalgorithm.Thisclasscannotbeinherited.

ICSharpCode.SharpZipLib.EncryptionNamespace

SharpZipCompressionLibrary

PkzipClassicembodiestheclassicororiginalencryptionfacilitiesusedinPkziparchives.Whileithasbeensupercededbymorerecentandmorepowerfulalgorithms,itsstillinuseandisviableforpreventingcasualsnooping

Foralistofallmembersofthistype,seePkzipClassicMembers.

System.ObjectSystem.Security.Cryptography.SymmetricAlgorithmICSharpCode.SharpZipLib.Encryption.PkzipClassicICSharpCode.SharpZipLib.Encryption.PkzipClassicManaged

publicabstractclassPkzipClassic:

SymmetricAlgorithm

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.EncryptionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoPkzipClassicMembers|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicClass

SharpZipCompressionLibrary

PkzipClassicoverview

PublicStaticMethodsGenerateKeys Generatesnewencryptionkeys

basedongivenseed

PublicInstancePropertiesBlockSize(inheritedfrom

SymmetricAlgorithm)Getsorsetstheblocksizeofthecryptographicoperationinbits.

FeedbackSize(inheritedfromSymmetricAlgorithm)

Getsorsetsthefeedbacksizeofthecryptographicoperationinbits.

IV(inheritedfromSymmetricAlgorithm)

Getsorsetstheinitializationvector(IV)forthesymmetricalgorithm.

Key(inheritedfromSymmetricAlgorithm)

Getsorsetsthesecretkeyforthesymmetricalgorithm.

KeySize(inheritedfromSymmetricAlgorithm)

Getsorsetsthesizeofthesecretkeyusedbythesymmetricalgorithminbits.

LegalBlockSizes(inheritedfromSymmetricAlgorithm)

Getstheblocksizesthataresupportedbythesymmetricalgorithm.

LegalKeySizes(inheritedfromSymmetricAlgorithm)

Getsthekeysizesthataresupportedbythesymmetricalgorithm.

Mode(inheritedfromSymmetricAlgorithm)

Getsorsetsthemodeforoperationofthesymmetricalgorithm.

Padding(inheritedfromSymmetricAlgorithm)

Getsorsetsthepaddingmodeusedinthesymmetric

PkzipClassicMembers

algorithm.

PublicInstanceMethodsClear(inheritedfrom

SymmetricAlgorithm)ReleasesallresourcesusedbytheSymmetricAlgorithm.

CreateDecryptor(inheritedfromSymmetricAlgorithm)

Overloaded.Whenoverriddeninaderivedclass,createsasymmetricdecryptorobjectwiththespecifiedKeyandinitializationvector(IV).

CreateEncryptor(inheritedfromSymmetricAlgorithm)

Overloaded.Whenoverriddeninaderivedclass,createsasymmetricencryptorobjectwiththespecifiedKeyandinitializationvector(IV).

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GenerateIV(inheritedfromSymmetricAlgorithm)

Whenoverriddeninaderivedclass,generatesarandominitializationvector(IV)tobeusedforthealgorithm.

GenerateKey(inheritedfromSymmetricAlgorithm)

Whenoverriddeninaderivedclass,generatesarandomKeytobeusedforthealgorithm.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ValidKeySize(inheritedfrom Determineswhetherthe

SymmetricAlgorithm) specifiedkeysizeisvalidforthecurrentalgorithm.

ProtectedInstanceConstructorsPkzipClassicConstructor Initializesanewinstanceofthe

PkzipClassicclass.

ProtectedInstanceFieldsBlockSizeValue(inherited

fromSymmetricAlgorithm)Representstheblocksizeofthecryptographicoperationinbits.

FeedbackSizeValue(inheritedfromSymmetricAlgorithm)

Representsthefeedbacksizeofthecryptographicoperationinbits.

IVValue(inheritedfromSymmetricAlgorithm)

Representstheinitializationvector(IV)forthesymmetricalgorithm.

KeySizeValue(inheritedfromSymmetricAlgorithm)

Representsthesizeofthesecretkeyusedbythesymmetricalgorithminbits.

KeyValue(inheritedfromSymmetricAlgorithm)

Representsthesecretkeyforthesymmetricalgorithm.

LegalBlockSizesValue(inheritedfromSymmetricAlgorithm)

Specifiestheblocksizesthataresupportedbythesymmetricalgorithm.

LegalKeySizesValue(inheritedfromSymmetricAlgorithm)

Specifiesthekeysizesthataresupportedbythesymmetricalgorithm.

ModeValue(inheritedfromSymmetricAlgorithm)

Representstheciphermodeusedinthesymmetricalgorithm.

PaddingValue(inheritedfromSymmetricAlgorithm)

Representsthepaddingmodeusedinthesymmetricalgorithm.

ProtectedInstanceMethodsDispose(inheritedfrom

SymmetricAlgorithm)ReleasestheunmanagedresourcesusedbytheSymmetricAlgorithmandoptionallyreleasesthemanagedresources.

Finalize(inheritedfromSymmetricAlgorithm)

ReleasestheunmanagedresourcesusedbytheSymmetricAlgorithm.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPkzipClassicClass|ICSharpCode.SharpZipLib.EncryptionNamespace

SharpZipCompressionLibrary

InitializesanewinstanceofthePkzipClassicclass.

protectedPkzipClassic();

SeeAlsoPkzipClassicClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicConstructor

SharpZipCompressionLibrary

ThemethodsofthePkzipClassicclassarelistedbelow.ForacompletelistofPkzipClassicclassmembers,seethePkzipClassicMemberstopic.

PublicStaticMethodsGenerateKeys Generatesnewencryptionkeys

basedongivenseed

PublicInstanceMethodsClear(inheritedfrom

SymmetricAlgorithm)ReleasesallresourcesusedbytheSymmetricAlgorithm.

CreateDecryptor(inheritedfromSymmetricAlgorithm)

Overloaded.Whenoverriddeninaderivedclass,createsasymmetricdecryptorobjectwiththespecifiedKeyandinitializationvector(IV).

CreateEncryptor(inheritedfromSymmetricAlgorithm)

Overloaded.Whenoverriddeninaderivedclass,createsasymmetricencryptorobjectwiththespecifiedKeyandinitializationvector(IV).

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GenerateIV(inheritedfromSymmetricAlgorithm)

Whenoverriddeninaderivedclass,generatesarandominitializationvector(IV)tobeusedforthealgorithm.

GenerateKey(inheritedfromSymmetricAlgorithm)

Whenoverriddeninaderivedclass,generatesarandomKeytobeusedforthealgorithm.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuse

PkzipClassicMethods

inhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ValidKeySize(inheritedfromSymmetricAlgorithm)

Determineswhetherthespecifiedkeysizeisvalidforthecurrentalgorithm.

ProtectedInstanceMethodsDispose(inheritedfrom

SymmetricAlgorithm)ReleasestheunmanagedresourcesusedbytheSymmetricAlgorithmandoptionallyreleasesthemanagedresources.

Finalize(inheritedfromSymmetricAlgorithm)

ReleasestheunmanagedresourcesusedbytheSymmetricAlgorithm.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPkzipClassicClass|ICSharpCode.SharpZipLib.EncryptionNamespace

SharpZipCompressionLibrary

Generatesnewencryptionkeysbasedongivenseed

publicstaticbyte[]GenerateKeys(

byte[]seed

);

SeeAlsoPkzipClassicClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassic.GenerateKeysMethod

SharpZipCompressionLibrary

DefinesawrapperobjecttoaccessthePkzipalgorithm.Thisclasscannotbeinherited.

Foralistofallmembersofthistype,seePkzipClassicManagedMembers.

System.ObjectSystem.Security.Cryptography.SymmetricAlgorithmICSharpCode.SharpZipLib.Encryption.PkzipClassicICSharpCode.SharpZipLib.Encryption.PkzipClassicManaged

publicsealedclassPkzipClassicManaged:

PkzipClassic

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.EncryptionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoPkzipClassicManagedMembers|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManagedClass

SharpZipCompressionLibrary

PkzipClassicManagedoverview

PublicInstanceConstructorsPkzipClassicManaged

ConstructorInitializesanewinstanceofthePkzipClassicManagedclass.

PublicInstancePropertiesBlockSize Get/settheapplicableblock

size.

FeedbackSize(inheritedfromSymmetricAlgorithm)

Getsorsetsthefeedbacksizeofthecryptographicoperationinbits.

IV(inheritedfromSymmetricAlgorithm)

Getsorsetstheinitializationvector(IV)forthesymmetricalgorithm.

Key Get/setthekeyvalueapplicable.

KeySize(inheritedfromSymmetricAlgorithm)

Getsorsetsthesizeofthesecretkeyusedbythesymmetricalgorithminbits.

LegalBlockSizes Getanarrayoflegalblocksizes.

LegalKeySizes Getanarrayoflegalkeysizes.

Mode(inheritedfromSymmetricAlgorithm)

Getsorsetsthemodeforoperationofthesymmetricalgorithm.

Padding(inheritedfromSymmetricAlgorithm)

Getsorsetsthepaddingmodeusedinthesymmetricalgorithm.

PublicInstanceMethods

PkzipClassicManagedMembers

Clear(inheritedfromSymmetricAlgorithm)

ReleasesallresourcesusedbytheSymmetricAlgorithm.

CreateDecryptor Overloaded.Createadecryptor.

CreateDecryptor(inheritedfromSymmetricAlgorithm)

Overloaded.CreatesasymmetricdecryptorobjectwiththecurrentKeyandinitializationvector(IV).

CreateEncryptor Overloaded.Createanencryptor.

CreateEncryptor(inheritedfromSymmetricAlgorithm)

Overloaded.CreatesasymmetricencryptorobjectwiththecurrentKeyandinitializationvector(IV).

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GenerateIV Generateaninitialvector.

GenerateKey Generateanewrandomkey.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ValidKeySize(inheritedfromSymmetricAlgorithm)

Determineswhetherthespecifiedkeysizeisvalidforthecurrentalgorithm.

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

SharpZipCompressionLibrary

InitializesanewinstanceofthePkzipClassicManagedclass.

publicPkzipClassicManaged();

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManagedConstructor

SharpZipCompressionLibrary

ThepropertiesofthePkzipClassicManagedclassarelistedbelow.ForacompletelistofPkzipClassicManagedclassmembers,seethePkzipClassicManagedMemberstopic.

PublicInstancePropertiesBlockSize Get/settheapplicableblock

size.

FeedbackSize(inheritedfromSymmetricAlgorithm)

Getsorsetsthefeedbacksizeofthecryptographicoperationinbits.

IV(inheritedfromSymmetricAlgorithm)

Getsorsetstheinitializationvector(IV)forthesymmetricalgorithm.

Key Get/setthekeyvalueapplicable.

KeySize(inheritedfromSymmetricAlgorithm)

Getsorsetsthesizeofthesecretkeyusedbythesymmetricalgorithminbits.

LegalBlockSizes Getanarrayoflegalblocksizes.

LegalKeySizes Getanarrayoflegalkeysizes.

Mode(inheritedfromSymmetricAlgorithm)

Getsorsetsthemodeforoperationofthesymmetricalgorithm.

Padding(inheritedfromSymmetricAlgorithm)

Getsorsetsthepaddingmodeusedinthesymmetricalgorithm.

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManagedProperties

SharpZipCompressionLibrary

Get/settheapplicableblocksize.

publicoverrideintBlockSize{get;set;}

RemarksTheonlyvalidblocksizeis8.

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.BlockSizeProperty

SharpZipCompressionLibrary

Get/setthekeyvalueapplicable.

publicoverridebyte[]Key{get;set;}

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.KeyProperty

SharpZipCompressionLibrary

Getanarrayoflegalblocksizes.

publicoverrideSystem.Security.Cryptography.KeySizes[]

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.LegalBlockSizesProperty

SharpZipCompressionLibrary

Getanarrayoflegalkeysizes.

publicoverrideSystem.Security.Cryptography.KeySizes[]

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.LegalKeySizesProperty

SharpZipCompressionLibrary

ThemethodsofthePkzipClassicManagedclassarelistedbelow.ForacompletelistofPkzipClassicManagedclassmembers,seethePkzipClassicManagedMemberstopic.

PublicInstanceMethodsClear(inheritedfrom

SymmetricAlgorithm)ReleasesallresourcesusedbytheSymmetricAlgorithm.

CreateDecryptor Overloaded.Createadecryptor.

CreateDecryptor(inheritedfromSymmetricAlgorithm)

Overloaded.CreatesasymmetricdecryptorobjectwiththecurrentKeyandinitializationvector(IV).

CreateEncryptor Overloaded.Createanencryptor.

CreateEncryptor(inheritedfromSymmetricAlgorithm)

Overloaded.CreatesasymmetricencryptorobjectwiththecurrentKeyandinitializationvector(IV).

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GenerateIV Generateaninitialvector.

GenerateKey Generateanewrandomkey.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

PkzipClassicManagedMethods

ValidKeySize(inheritedfromSymmetricAlgorithm)

Determineswhetherthespecifiedkeysizeisvalidforthecurrentalgorithm.

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

SharpZipCompressionLibrary

Createadecryptor.

OverloadListInheritedfromSymmetricAlgorithm.

publicvirtualICryptoTransformCreateDecryptor();

Createadecryptor.

publicoverrideICryptoTransformCreateDecryptor(byte[],byte[]);

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.CreateDecryptorMethod

SharpZipCompressionLibrary

Createadecryptor.

publicoverrideICryptoTransformCreateDecryptor(

byte[]rgbKey,

byte[]rgbIV

);

ParametersrgbKey

Keystouseforthisnewdecryptor.

rgbIVInitialisationvectorforthenewdecryptor.

ReturnValueReturnsanewdecryptor.

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace|PkzipClassicManaged.CreateDecryptorOverloadList

PkzipClassicManaged.CreateDecryptorMethod(Byte[],Byte[])

SharpZipCompressionLibrary

Createanencryptor.

OverloadListInheritedfromSymmetricAlgorithm.

publicvirtualICryptoTransformCreateEncryptor();

Createanencryptor.

publicoverrideICryptoTransformCreateEncryptor(byte[],byte[]);

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.CreateEncryptorMethod

SharpZipCompressionLibrary

Createanencryptor.

publicoverrideICryptoTransformCreateEncryptor(

byte[]rgbKey,

byte[]rgbIV

);

ParametersrgbKey

Thekeytouseforthisencryptor.

rgbIVInitialisationvectorforthenewencryptor.

ReturnValueReturnsanewPkzipClassicencryptor

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace|PkzipClassicManaged.CreateEncryptorOverloadList

PkzipClassicManaged.CreateEncryptorMethod(Byte[],Byte[])

SharpZipCompressionLibrary

Generateaninitialvector.

publicoverridevoidGenerateIV();

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.GenerateIVMethod

SharpZipCompressionLibrary

Generateanewrandomkey.

publicoverridevoidGenerateKey();

SeeAlsoPkzipClassicManagedClass|ICSharpCode.SharpZipLib.EncryptionNamespace

PkzipClassicManaged.GenerateKeyMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionGZipConstants Thisclasscontainsconstants

usedforgzip.

GZipException GZipExceptionrepresentsaGzipspecificexception

GZipInputStream Thisfilterstreamisusedtodecompressa"GZIP"formatstream.The"GZIP"formatisdescribedbaseInputStreamRFC1952.authoroftheoriginaljavaversion:JohnLeuner

GZipOutputStream Thisfilterstreamisusedtocompressastreamintoa"GZIP"stream.The"GZIP"formatisdescribedinRFC1952.authoroftheoriginaljavaversion:JohnLeuner

ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

Thisclasscontainsconstantsusedforgzip.

Foralistofallmembersofthistype,seeGZipConstantsMembers.

System.ObjectICSharpCode.SharpZipLib.GZip.GZipConstants

publicclassGZipConstants

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.GZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoGZipConstantsMembers|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstantsClass

SharpZipCompressionLibrary

GZipConstantsoverview

PublicStaticFieldsFCOMMENT flagbitmaskindicating

commentispresent

FEXTRA Flagbitmaskforextra

FHCRC FlagbitmaskforCrc

FNAME flagbitmaskforname

FTEXT Flagbitmaskfortext

GZIP_MAGIC MagicnumberfoundatstartofGZIPheader

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

GZipConstantsMembers

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

ThefieldsoftheGZipConstantsclassarelistedbelow.ForacompletelistofGZipConstantsclassmembers,seetheGZipConstantsMemberstopic.

PublicStaticFieldsFCOMMENT flagbitmaskindicating

commentispresent

FEXTRA Flagbitmaskforextra

FHCRC FlagbitmaskforCrc

FNAME flagbitmaskforname

FTEXT Flagbitmaskfortext

GZIP_MAGIC MagicnumberfoundatstartofGZIPheader

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstantsFields

SharpZipCompressionLibrary

flagbitmaskindicatingcommentispresent

publicconstintFCOMMENT=16;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.FCOMMENTField

SharpZipCompressionLibrary

Flagbitmaskforextra

publicconstintFEXTRA=4;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.FEXTRAField

SharpZipCompressionLibrary

FlagbitmaskforCrc

publicconstintFHCRC=2;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.FHCRCField

SharpZipCompressionLibrary

flagbitmaskforname

publicconstintFNAME=8;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.FNAMEField

SharpZipCompressionLibrary

Flagbitmaskfortext

publicconstintFTEXT=1;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.FTEXTField

SharpZipCompressionLibrary

MagicnumberfoundatstartofGZIPheader

publicstaticreadonlyintGZIP_MAGIC;

SeeAlsoGZipConstantsClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipConstants.GZIP_MAGICField

SharpZipCompressionLibrary

GZipExceptionrepresentsaGzipspecificexception

Foralistofallmembersofthistype,seeGZipExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.GZip.GZipException

publicclassGZipException:

SharpZipBaseException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.GZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoGZipExceptionMembers|ICSharpCode.SharpZipLib.GZipNamespace

GZipExceptionClass

SharpZipCompressionLibrary

GZipExceptionoverview

PublicInstanceConstructorsGZipException Overloaded.Initializesanew

instanceoftheGZipExceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

GZipExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoGZipExceptionClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofGZipException

OverloadListInitialiseanewinstanceofGZipException

publicGZipException();

InitialiseanewinstanceofGZipExceptionwithitsmessagestring.

publicGZipException(string);

SeeAlsoGZipExceptionClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipExceptionConstructor

SharpZipCompressionLibrary

InitialiseanewinstanceofGZipException

publicGZipException();

SeeAlsoGZipExceptionClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipExceptionConstructorOverloadList

GZipExceptionConstructor()

SharpZipCompressionLibrary

InitialiseanewinstanceofGZipExceptionwithitsmessagestring.

publicGZipException(

stringmessage

);

Parametersmessage

AStringstringthatdescribestheerror.

SeeAlsoGZipExceptionClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipExceptionConstructorOverloadList

GZipExceptionConstructor(String)

SharpZipCompressionLibrary

Thisfilterstreamisusedtodecompressa"GZIP"formatstream.The"GZIP"formatisdescribedbaseInputStreamRFC1952.authoroftheoriginaljavaversion:JohnLeuner

Foralistofallmembersofthistype,seeGZipInputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStreamICSharpCode.SharpZipLib.GZip.GZipInputStream

publicclassGZipInputStream:

InflaterInputStream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

ExampleThissampleshowshowtounzipagzippedfile

usingSystem;

usingSystem.IO;

usingICSharpCode.SharpZipLib.GZip;

classMainClass

{

publicstaticvoidMain(string[]args)

{

Streams=newGZipInputStream(File.OpenRead(args[0]));

FileStreamfs=File.Create(Path.GetFileNameWithoutExtension(args[0]));

intsize=2048;

byte[]writeData=newbyte[2048];

GZipInputStreamClass

while(true){

size=s.Read(writeData,0,size);

if(size>0){

fs.Write(writeData,0,size);

}else{

break;

}

}

s.Close();

}

}

RequirementsNamespace:ICSharpCode.SharpZipLib.GZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoGZipInputStreamMembers|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

GZipInputStreamoverview

PublicInstanceConstructorsGZipInputStream Overloaded.Initializesanew

instanceoftheGZipInputStreamclass.

PublicInstancePropertiesAvailable(inheritedfrom

InflaterInputStream)Returns0oncetheendofthestream(EOF)hasbeenreached.Otherwisereturns1.

CanRead(inheritedfromInflaterInputStream)

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

CanWrite(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

IsStreamOwner(inheritedfromInflaterInputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromInflaterInputStream)

Avaluerepresentingthelengthofthestreaminbytes.

Position(inheritedfromInflaterInputStream)

Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

PublicInstanceMethods

GZipInputStreamMembers

BeginRead(inheritedfromStream)

Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromInflaterInputStream)

Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

Close(inheritedfromInflaterInputStream)

Closestheinputstream.WhenIsStreamOwneristruetheunderlyingstreamisalsoclosed.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush(inheritedfromInflaterInputStream)

FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readsuncompresseddataintoanarrayofbytes

ReadByte(inheritedfromStream)

Readsabytefromthestreamandadvancesthepositionwithinthestreambyonebyte,orreturns-1ifattheendofthestream.

Seek(inheritedfromInflaterInputStream)

SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength(inheritedfromInflaterInputStream)

SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip(inheritedfromInflaterInputStream)

Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write(inheritedfromInflaterInputStream)

WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte(inheritedfromInflaterInputStream)

WritesonebytetothecurrentstreamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceFieldsbaseInputStream(inherited

fromInflaterInputStream)Basestreamtheinflaterreadsfrom.

crc CRC-32valuefor

uncompresseddata

csize(inheritedfromInflaterInputStream)

Thecompressedsize

eos Indicatesendofstream

inf(inheritedfromInflaterInputStream)

Decompressorforthisstream

inputBuffer(inheritedfromInflaterInputStream)

Inputbufferforthisstream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill(inheritedfromInflaterInputStream)

Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting(inheritedfromInflaterInputStream)

Clearanycryptographicstate.

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

CreatesaGzipInputStreamwiththedefaultbuffersize

OverloadListCreatesaGzipInputStreamwiththedefaultbuffersize

publicGZipInputStream(Stream);

CreatesaGZIPInputStreamwiththespecifiedbuffersize

publicGZipInputStream(Stream,int);

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipInputStreamConstructor

SharpZipCompressionLibrary

CreatesaGzipInputStreamwiththedefaultbuffersize

publicGZipInputStream(

StreambaseInputStream

);

ParametersbaseInputStream

Thestreamtoreadcompresseddatafrom(baseInputStreamGZIPformat)

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipInputStreamConstructorOverloadList

GZipInputStreamConstructor(Stream)

SharpZipCompressionLibrary

CreatesaGZIPInputStreamwiththespecifiedbuffersize

publicGZipInputStream(

StreambaseInputStream,

intsize

);

ParametersbaseInputStream

Thestreamtoreadcompresseddatafrom(baseInputStreamGZIPformat)

sizeSizeofthebuffertouse

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipInputStreamConstructorOverloadList

GZipInputStreamConstructor(Stream,Int32)

SharpZipCompressionLibrary

ThefieldsoftheGZipInputStreamclassarelistedbelow.ForacompletelistofGZipInputStreamclassmembers,seetheGZipInputStreamMemberstopic.

ProtectedInstanceFieldsbaseInputStream(inherited

fromInflaterInputStream)Basestreamtheinflaterreadsfrom.

crc CRC-32valueforuncompresseddata

csize(inheritedfromInflaterInputStream)

Thecompressedsize

eos Indicatesendofstream

inf(inheritedfromInflaterInputStream)

Decompressorforthisstream

inputBuffer(inheritedfromInflaterInputStream)

Inputbufferforthisstream.

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipInputStreamFields

SharpZipCompressionLibrary

CRC-32valueforuncompresseddata

protectedCrc32crc;

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipInputStream.crcField

SharpZipCompressionLibrary

Indicatesendofstream

protectedbooleos;

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipInputStream.eosField

SharpZipCompressionLibrary

ThemethodsoftheGZipInputStreamclassarelistedbelow.ForacompletelistofGZipInputStreamclassmembers,seetheGZipInputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromInflaterInputStream)

Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

Close(inheritedfromInflaterInputStream)

Closestheinputstream.WhenIsStreamOwneristruetheunderlyingstreamisalsoclosed.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush(inheritedfromInflaterInputStream)

FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddata

GZipInputStreamMethods

structureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readsuncompresseddataintoanarrayofbytes

ReadByte(inheritedfromStream)

Readsabytefromthestreamandadvancesthepositionwithinthestreambyonebyte,orreturns-1ifattheendofthestream.

Seek(inheritedfromInflaterInputStream)

SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength(inheritedfromInflaterInputStream)

SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip(inheritedfromInflaterInputStream)

Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write(inheritedfromInflaterInputStream)

WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte(inheritedfromInflaterInputStream)

Writesonebytetothecurrentstreamandadvancesthe

currentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill(inheritedfromInflaterInputStream)

Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting(inheritedfromInflaterInputStream)

Clearanycryptographicstate.

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

Readsuncompresseddataintoanarrayofbytes

publicoverrideintRead(

byte[]buf,

intoffset,

intlen

);

Parametersbuf

Thebuffertoreaduncompresseddatainto

offsetTheoffsetindicatingwherethedatashouldbeplaced

lenThenumberofuncompressedbytestoberead

SeeAlsoGZipInputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipInputStream.ReadMethod

SharpZipCompressionLibrary

Thisfilterstreamisusedtocompressastreamintoa"GZIP"stream.The"GZIP"formatisdescribedinRFC1952.authoroftheoriginaljavaversion:JohnLeuner

Foralistofallmembersofthistype,seeGZipOutputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStreamICSharpCode.SharpZipLib.GZip.GZipOutputStream

publicclassGZipOutputStream:

DeflaterOutputStream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

ExampleThissampleshowshowtogzipafile

usingSystem;

usingSystem.IO;

usingICSharpCode.SharpZipLib.GZip;

classMainClass

{

publicstaticvoidMain(string[]args)

{

Streams=newGZipOutputStream(File.Create(args[0]+".gz"));

FileStreamfs=File.OpenRead(args[0]);

byte[]writeData=newbyte[fs.Length];

fs.Read(writeData,0,(int)fs.Length);

GZipOutputStreamClass

s.Write(writeData,0,writeData.Length);

s.Close();

}

}

RequirementsNamespace:ICSharpCode.SharpZipLib.GZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoGZipOutputStreamMembers|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

GZipOutputStreamoverview

PublicInstanceConstructorsGZipOutputStream Overloaded.Initializesanew

instanceoftheGZipOutputStreamclass.

PublicInstancePropertiesCanPatchEntries

(inheritedfromDeflaterOutputStream)

Allowsclienttodetermineifanentrycanbepatchedafteritsadded

CanRead(inheritedfromDeflaterOutputStream)

Getsvalueindicatingstreamcanbereadfrom

CanSeek(inheritedfromDeflaterOutputStream)

GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

CanWrite(inheritedfromDeflaterOutputStream)

Getvalueindicatingifthisstreamsupportswriting

IsStreamOwner(inheritedfromDeflaterOutputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromDeflaterOutputStream)

Getcurrentlengthofstream

Password(inheritedfromDeflaterOutputStream)

Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

Position(inheritedfromDeflaterOutputStream)

Thecurrentpositionwithinthestream.AlwaysthrowsaNotSupportedExceptionNotSupportedException

GZipOutputStreamMembers

PublicInstanceMethodsBeginRead(inheritedfrom

DeflaterOutputStream)AsynchronousreadsarenotsupportedaNotSupportedExceptionisalwaysthrown

BeginWrite(inheritedfromDeflaterOutputStream)

Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close Writesremainingcompressedoutputdatatotheoutputstreamandclosesit.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishcompressionandwriteanyfooterinformationrequiredtostream

Flush(inheritedfromDeflaterOutputStream)

Flushesthestreambycallingflush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuse

inhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getthecurrentcompressionlevel.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read(inheritedfromDeflaterOutputStream)

Readablockofbytesfromstream

ReadByte(inheritedfromDeflaterOutputStream)

Readabytefromstreamadvancingpositionbyone

Seek(inheritedfromDeflaterOutputStream)

Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLength(inheritedfromDeflaterOutputStream)

Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLevel Setstheactivecompressionlevel(1-9).Thenewlevelwillbeactivatedimmediately.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writegivenbuffertooutputupdatingcrc

WriteByte(inheritedfromDeflaterOutputStream)

Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceFields

baseOutputStream(inheritedfromDeflaterOutputStream)

Basestreamthedeflaterdependson.

buf(inheritedfromDeflaterOutputStream)

Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

crc CRC-32valueforuncompresseddata

def(inheritedfromDeflaterOutputStream)

Thedeflaterwhichisusedtodeflatethestream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Deflate(inheritedfromDeflaterOutputStream)

Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock(inheritedfromDeflaterOutputStream)

Encryptablockofdata

EncryptByte(inheritedfromDeflaterOutputStream)

Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword(inheritedfromDeflaterOutputStream)

Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys(inheritedfromDeflaterOutputStream)

Updateencryptionkeys

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

CreatesaGzipOutputStreamwiththedefaultbuffersize

OverloadListCreatesaGzipOutputStreamwiththedefaultbuffersize

publicGZipOutputStream(Stream);

CreatesaGZipOutputStreamwiththespecifiedbuffersize

publicGZipOutputStream(Stream,int);

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStreamConstructor

SharpZipCompressionLibrary

CreatesaGzipOutputStreamwiththedefaultbuffersize

publicGZipOutputStream(

StreambaseOutputStream

);

ParametersbaseOutputStream

Thestreamtoreaddata(tobecompressed)from

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipOutputStreamConstructorOverloadList

GZipOutputStreamConstructor(Stream)

SharpZipCompressionLibrary

CreatesaGZipOutputStreamwiththespecifiedbuffersize

publicGZipOutputStream(

StreambaseOutputStream,

intsize

);

ParametersbaseOutputStream

Thestreamtoreaddata(tobecompressed)from

sizeSizeofthebuffertouse

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace|GZipOutputStreamConstructorOverloadList

GZipOutputStreamConstructor(Stream,Int32)

SharpZipCompressionLibrary

ThefieldsoftheGZipOutputStreamclassarelistedbelow.ForacompletelistofGZipOutputStreamclassmembers,seetheGZipOutputStreamMemberstopic.

ProtectedInstanceFieldsbaseOutputStream(inherited

fromDeflaterOutputStream)Basestreamthedeflaterdependson.

buf(inheritedfromDeflaterOutputStream)

Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

crc CRC-32valueforuncompresseddata

def(inheritedfromDeflaterOutputStream)

Thedeflaterwhichisusedtodeflatethestream.

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStreamFields

SharpZipCompressionLibrary

CRC-32valueforuncompresseddata

protectedCrc32crc;

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.crcField

SharpZipCompressionLibrary

ThemethodsoftheGZipOutputStreamclassarelistedbelow.ForacompletelistofGZipOutputStreamclassmembers,seetheGZipOutputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

DeflaterOutputStream)AsynchronousreadsarenotsupportedaNotSupportedExceptionisalwaysthrown

BeginWrite(inheritedfromDeflaterOutputStream)

Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close Writesremainingcompressedoutputdatatotheoutputstreamandclosesit.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishcompressionandwriteanyfooterinformationrequiredtostream

Flush(inheritedfrom Flushesthestreambycalling

GZipOutputStreamMethods

DeflaterOutputStream) flush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getthecurrentcompressionlevel.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read(inheritedfromDeflaterOutputStream)

Readablockofbytesfromstream

ReadByte(inheritedfromDeflaterOutputStream)

Readabytefromstreamadvancingpositionbyone

Seek(inheritedfromDeflaterOutputStream)

Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLength(inheritedfromDeflaterOutputStream)

Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLevel Setstheactivecompressionlevel(1-9).Thenewlevelwillbeactivatedimmediately.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writegivenbuffertooutputupdatingcrc

WriteByte(inheritedfromDeflaterOutputStream)

Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Deflate(inheritedfromDeflaterOutputStream)

Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock(inheritedfromDeflaterOutputStream)

Encryptablockofdata

EncryptByte(inheritedfromDeflaterOutputStream)

Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword(inheritedfromDeflaterOutputStream)

Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys(inheritedfromDeflaterOutputStream)

Updateencryptionkeys

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

SharpZipCompressionLibrary

Writesremainingcompressedoutputdatatotheoutputstreamandclosesit.

publicoverridevoidClose();

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.CloseMethod

SharpZipCompressionLibrary

Finishcompressionandwriteanyfooterinformationrequiredtostream

publicoverridevoidFinish();

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.FinishMethod

SharpZipCompressionLibrary

Getthecurrentcompressionlevel.

publicintGetLevel();

ReturnValueThecurrentcompressionlevel.

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.GetLevelMethod

SharpZipCompressionLibrary

Setstheactivecompressionlevel(1-9).Thenewlevelwillbeactivatedimmediately.

publicvoidSetLevel(

intlevel

);

ExceptionsExceptionType ConditionArgumentOutOfRangeException Levelspecifiedisnotsupported.

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.SetLevelMethod

SharpZipCompressionLibrary

Writegivenbuffertooutputupdatingcrc

publicoverridevoidWrite(

byte[]buf,

intoff,

intlen

);

Parametersbuf

Buffertowrite

offOffsetoffirstbyteinbuftowrite

lenNumberofbytestowrite

SeeAlsoGZipOutputStreamClass|ICSharpCode.SharpZipLib.GZipNamespace

GZipOutputStream.WriteMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionInvalidHeaderException Thisexceptionisusedtoindicate

thatthereisaproblemwithaTARarchiveheader.

TarArchive TheTarArchiveclassimplementstheconceptofa'TapeArchive'.Atararchiveisaseriesofentries,eachofwhichrepresentsafilesystemobject.Eachentryinthearchiveconsistsofaheaderblockfollowedby0ormoredatablocks.Directoryentriesconsistonlyoftheheaderblock,andarefollowedbyentriesforthedirectory'scontents.Fileentriesconsistofaheaderfollowedbythenumberofblocksneededtocontainthefile'scontents.Allentriesarewrittenonblockboundaries.Blocksare512byteslong.TarArchivesareinstantiatedineitherreadorwritemode,baseduponwhethertheyareinstantiatedwithanInputStreamoranOutputStream.OnceinstantiatedTarArchivesread/writemodecannotbechanged.Thereiscurrentlynosupportforrandomaccesstotararchives.However,itseemsthatsubclassingTarArchive,andusingthe

ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.getCurrentRecordNum()andTarBuffer.getCurrentBlockNum()methods,thiswouldberathertrvial.

TarBuffer TheTarBufferclassimplementsthetararchiveconceptofabufferedinputstream.Thisconceptgoesbacktothedaysofblockedtapedrivesandspecialiodevices.IntheC#universe,theonlyrealfunctionthatthisclassperformsistoensurethatfileshavethecorrect"record"size,orothertarswillcomplain.

Youshouldneverhaveaneedtoaccessthisclassdirectly.TarBuffersarecreatedbyTarIOStreams.

TarEntry ThisclassrepresentsanentryinaTararchive.Itconsistsoftheentry'sheader,aswellastheentry'sFile.Entriescanbeinstantiatedinoneofthreeways,dependingonhowtheyaretobeused.

TarEntriesthatarecreatedfromtheheaderbytesreadfromanarchiveareinstantiatedwiththeTarEntry(byte[])constructor.Theseentrieswillbeusedwhenextractingfromorlistingthecontentsofanarchive.Theseentrieshavetheirheaderfilledinusingtheheaderbytes.TheyalsosettheFiletonull,sincethey

referenceanarchiveentrynotafile.

TarEntriesthatarecreatedfromfilesthataretobewrittenintoanarchiveareinstantiatedwiththeCreateEntryFromFile(string)pseudoconstructor.TheseentrieshavetheirheaderfilledinusingtheFile'sinformation.TheyalsokeepareferencetotheFileforconveniencewhenwritingentries.

Finally,TarEntriescanbeconstructedfromnothingbutaname.Thisallowstheprogrammertoconstructtheentrybyhand,forinstancewhenonlyanInputStreamisavailableforwritingtothearchive,andtheheaderinformationisconstructedfromotherinformation.InthiscasetheheaderfieldsaresettodefaultsandtheFileissettonull.

TarHeader

TarException TarExceptionsareusedforexceptionsspecifictotarclassesandcode.

TarHeader ThisclassencapsulatestheTarEntryHeaderusedinTarArchives.Theclassalsoholdsanumberoftarconstants,usedmostlyinheaders.

TarInputStream TheTarInputStreamreadsaUNIXtararchiveasanInputStream.methodsareprovidedtopositionateach

successiveentryinthearchive,andthereadeachentryasanormalinputstreamusingread().

TarInputStream.EntryFactoryAdapter StandardentryfactoryclasscreatinginstancesoftheclassTarEntry

TarOutputStream TheTarOutputStreamwritesaUNIXtararchiveasanOutputStream.Methodsareprovidedtoputentries,andthenwritetheircontentsbywritingtothisstreamusingwrite().

InterfacesInterface DescriptionTarInputStream.IEntryFactory Thisinterfaceisprovided,along

withthemethodsetEntryFactory(),toallowtheprogrammertohavetheirownTarEntrysubclassinstantiatedfortheentriesreturnfromgetNextEntry().

DelegatesDelegate DescriptionProgressMessageHandler Usedtoadviseclientsof

'events'whileprocessingarchives

SharpZipCompressionLibrary

ThisexceptionisusedtoindicatethatthereisaproblemwithaTARarchiveheader.

Foralistofallmembersofthistype,seeInvalidHeaderExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.Tar.TarExceptionICSharpCode.SharpZipLib.Tar.InvalidHeaderException

publicclassInvalidHeaderException:

TarException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoInvalidHeaderExceptionMembers|ICSharpCode.SharpZipLib.TarNamespace

InvalidHeaderExceptionClass

SharpZipCompressionLibrary

InvalidHeaderExceptionoverview

PublicInstanceConstructorsInvalidHeaderException Overloaded.Initializesanew

instanceoftheInvalidHeaderExceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

InvalidHeaderExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInvalidHeaderExceptionClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceoftheInvalidHeaderExceptionclass.

OverloadListInitialiseanewinstanceoftheInvalidHeaderExceptionclass.

publicInvalidHeaderException();

InitialisesanewinstanceoftheInvalidHeaderExceptionclasswithaspecifiedmessage.

publicInvalidHeaderException(string);

SeeAlsoInvalidHeaderExceptionClass|ICSharpCode.SharpZipLib.TarNamespace

InvalidHeaderExceptionConstructor

SharpZipCompressionLibrary

InitialiseanewinstanceoftheInvalidHeaderExceptionclass.

publicInvalidHeaderException();

SeeAlsoInvalidHeaderExceptionClass|ICSharpCode.SharpZipLib.TarNamespace|InvalidHeaderExceptionConstructorOverloadList

InvalidHeaderExceptionConstructor()

SharpZipCompressionLibrary

InitialisesanewinstanceoftheInvalidHeaderExceptionclasswithaspecifiedmessage.

publicInvalidHeaderException(

stringmsg

);

SeeAlsoInvalidHeaderExceptionClass|ICSharpCode.SharpZipLib.TarNamespace|InvalidHeaderExceptionConstructorOverloadList

InvalidHeaderExceptionConstructor(String)

SharpZipCompressionLibrary

Usedtoadviseclientsof'events'whileprocessingarchives

publicdelegatevoidProgressMessageHandler(

TarArchivearchive,

TarEntryentry,

stringmessage

);

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.TarNamespace

ProgressMessageHandlerDelegate

SharpZipCompressionLibrary

TheTarArchiveclassimplementstheconceptofa'TapeArchive'.Atararchiveisaseriesofentries,eachofwhichrepresentsafilesystemobject.Eachentryinthearchiveconsistsofaheaderblockfollowedby0ormoredatablocks.Directoryentriesconsistonlyoftheheaderblock,andarefollowedbyentriesforthedirectory'scontents.Fileentriesconsistofaheaderfollowedbythenumberofblocksneededtocontainthefile'scontents.Allentriesarewrittenonblockboundaries.Blocksare512byteslong.TarArchivesareinstantiatedineitherreadorwritemode,baseduponwhethertheyareinstantiatedwithanInputStreamoranOutputStream.OnceinstantiatedTarArchivesread/writemodecannotbechanged.Thereiscurrentlynosupportforrandomaccesstotararchives.However,itseemsthatsubclassingTarArchive,andusingtheTarBuffer.getCurrentRecordNum()andTarBuffer.getCurrentBlockNum()methods,thiswouldberathertrvial.

Foralistofallmembersofthistype,seeTarArchiveMembers.

System.ObjectICSharpCode.SharpZipLib.Tar.TarArchive

publicclassTarArchive

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarArchiveMembers|ICSharpCode.SharpZipLib.TarNamespace

TarArchiveClass

SharpZipCompressionLibrary

TarArchiveoverview

PublicStaticMethodsCreateInputTarArchive Overloaded.TheInputStream

basedconstructorscreateaTarArchiveforthepurposesofextractingorlistingatararchive.Thus,usetheseconstructorswhenyouwishtoextractfilesfromorlistthecontentsofanexistingtararchive.

CreateOutputTarArchive Overloaded.CreateaTarArchiveforwritingto,usingthedefaultblockingfactor

PublicInstancePropertiesApplyUserInfoOverrides Getorsetavalueindicatingif

overridesdefinedbySetUserInfoshouldbeapplied.

GroupId Getthearchivegroupid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

GroupName Getthearchivegroupname.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

PathPrefix PathPrefixisaddedtoentrynamesastheyarewrittenifthevalueisnotnull.AslashcharacterisappendedafterPathPrefix

TarArchiveMembers

RecordSize Getthearchive'srecordsize.Becauseofitshistory,tarsupportstheconceptofbufferedIOconsistingofRECORDSofBLOCKS.ThisallowedtartomatchtheIOcharacteristicsofthephysicaldevicebeingused.Ofcourse,intheC#world,thismakesnosense,WITHONEEXCEPTION-archivesareexpectedtobeproperly"blocked".Thus,allofthehorribleTarBuffersupportboilsdowntosimplygettingthe"boundaries"correct.

RootPath RootPathisremovedfromentrynamesifitisfoundatthebeginningofthename.

UserId Getthearchiveuserid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

UserName Getthearchiveusername.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

PublicInstanceMethodsCloseArchive Closethearchive.Thissimply

callstheunderlyingtarstream'sclose()method.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

ExtractContents Performthe"extract"commandandextractthecontentsofthe

archive.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ListContents Performthe"list"commandforthearchivecontents.NOTEThatthismethodusestheprogresseventtoactuallylistthecontents.Iftheprogressdisplayeventisnotset,nothingwillbelisted!

SetAsciiTranslation Settheasciifiletranslationflag.Ifasciifiletranslationistrue,thenthefileischeckedtoseeifitabinaryfileornot.Iftheflagistrueandthetestindicatesitisasciitextfile,itwillbetranslated.Thetranslationconvertsthelocaloperatingsystem'sconceptoflineendsintotheUNIXlineend,'\n',whichisthedefactostandardforaTARarchive.ThismakestextfilescompatiblewithUNIX.

SetKeepOldFiles Settheflagthatdetermineswhetherexistingfilesarekept,oroverwrittenduringextraction.

SetUserInfo Setuserandgroupinformationthatwillbeusedtofillinthetararchive'sentryheaders.Thisinformationbasedonthatavailableforthelinuxoperatingsystem,whichisnotalways

availableonotheroperatingsystems.TarArchiveallowstheprogrammertospecifyvaluestobeusedintheirplace.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteEntry Writeanentrytothearchive.ThismethodwillcalltheputNextEntryandthenwritethecontentsoftheentry,andfinallycallcloseEntry()forentriesthatarefiles.Fordirectories,itwillcallputNextEntry(),andthen,iftherecurseflagistrue,processeachentrythatisachildofthedirectory.

PublicInstanceEventsProgressMessageEvent Clienthookallowingdetailed

informationtobereportedduringprocessing

ProtectedInstanceConstructorsTarArchiveConstructor ConstructorforaTarArchive.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

OnProgressMessageEvent RaisestheProgressMessageevent

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

ConstructorforaTarArchive.

protectedTarArchive();

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchiveConstructor

SharpZipCompressionLibrary

ThepropertiesoftheTarArchiveclassarelistedbelow.ForacompletelistofTarArchiveclassmembers,seetheTarArchiveMemberstopic.

PublicInstancePropertiesApplyUserInfoOverrides Getorsetavalueindicatingif

overridesdefinedbySetUserInfoshouldbeapplied.

GroupId Getthearchivegroupid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

GroupName Getthearchivegroupname.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

PathPrefix PathPrefixisaddedtoentrynamesastheyarewrittenifthevalueisnotnull.AslashcharacterisappendedafterPathPrefix

RecordSize Getthearchive'srecordsize.Becauseofitshistory,tarsupportstheconceptofbufferedIOconsistingofRECORDSofBLOCKS.ThisallowedtartomatchtheIOcharacteristicsofthephysicaldevicebeingused.Ofcourse,intheC#world,thismakesnosense,WITHONEEXCEPTION-archivesareexpectedtobeproperly"blocked".Thus,allofthehorribleTarBuffersupportboils

TarArchiveProperties

downtosimplygettingthe"boundaries"correct.

RootPath RootPathisremovedfromentrynamesifitisfoundatthebeginningofthename.

UserId Getthearchiveuserid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

UserName Getthearchiveusername.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

GetorsetavalueindicatingifoverridesdefinedbySetUserInfoshouldbeapplied.

publicboolApplyUserInfoOverrides{get;set;}

RemarksIfoverridesarenotappliedthenthevaluesassetineachheaderwillbeused.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.ApplyUserInfoOverridesProperty

SharpZipCompressionLibrary

Getthearchivegroupid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

publicintGroupId{get;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.GroupIdProperty

SharpZipCompressionLibrary

Getthearchivegroupname.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

publicstringGroupName{get;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.GroupNameProperty

SharpZipCompressionLibrary

PathPrefixisaddedtoentrynamesastheyarewrittenifthevalueisnotnull.AslashcharacterisappendedafterPathPrefix

publicstringPathPrefix{get;set;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.PathPrefixProperty

SharpZipCompressionLibrary

Getthearchive'srecordsize.Becauseofitshistory,tarsupportstheconceptofbufferedIOconsistingofRECORDSofBLOCKS.ThisallowedtartomatchtheIOcharacteristicsofthephysicaldevicebeingused.Ofcourse,intheC#world,thismakesnosense,WITHONEEXCEPTION-archivesareexpectedtobeproperly"blocked".Thus,allofthehorribleTarBuffersupportboilsdowntosimplygettingthe"boundaries"correct.

publicintRecordSize{get;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.RecordSizeProperty

SharpZipCompressionLibrary

RootPathisremovedfromentrynamesifitisfoundatthebeginningofthename.

publicstringRootPath{get;set;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.RootPathProperty

SharpZipCompressionLibrary

Getthearchiveuserid.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

publicintUserId{get;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.UserIdProperty

SharpZipCompressionLibrary

Getthearchiveusername.SeeApplyUserInfoOverridesfordetailonhowtoallowsettingvaluesonaperentrybasis.

publicstringUserName{get;}

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.UserNameProperty

SharpZipCompressionLibrary

ThemethodsoftheTarArchiveclassarelistedbelow.ForacompletelistofTarArchiveclassmembers,seetheTarArchiveMemberstopic.

PublicStaticMethodsCreateInputTarArchive Overloaded.TheInputStream

basedconstructorscreateaTarArchiveforthepurposesofextractingorlistingatararchive.Thus,usetheseconstructorswhenyouwishtoextractfilesfromorlistthecontentsofanexistingtararchive.

CreateOutputTarArchive Overloaded.CreateaTarArchiveforwritingto,usingthedefaultblockingfactor

PublicInstanceMethodsCloseArchive Closethearchive.Thissimply

callstheunderlyingtarstream'sclose()method.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

ExtractContents Performthe"extract"commandandextractthecontentsofthearchive.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfrom GetstheTypeofthecurrent

TarArchiveMethods

Object) instance.

ListContents Performthe"list"commandforthearchivecontents.NOTEThatthismethodusestheprogresseventtoactuallylistthecontents.Iftheprogressdisplayeventisnotset,nothingwillbelisted!

SetAsciiTranslation Settheasciifiletranslationflag.Ifasciifiletranslationistrue,thenthefileischeckedtoseeifitabinaryfileornot.Iftheflagistrueandthetestindicatesitisasciitextfile,itwillbetranslated.Thetranslationconvertsthelocaloperatingsystem'sconceptoflineendsintotheUNIXlineend,'\n',whichisthedefactostandardforaTARarchive.ThismakestextfilescompatiblewithUNIX.

SetKeepOldFiles Settheflagthatdetermineswhetherexistingfilesarekept,oroverwrittenduringextraction.

SetUserInfo Setuserandgroupinformationthatwillbeusedtofillinthetararchive'sentryheaders.Thisinformationbasedonthatavailableforthelinuxoperatingsystem,whichisnotalwaysavailableonotheroperatingsystems.TarArchiveallowstheprogrammertospecifyvaluestobeusedintheirplace.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteEntry Writeanentrytothearchive.ThismethodwillcalltheputNextEntryandthenwritethecontentsoftheentry,andfinallycallcloseEntry()forentriesthatarefiles.Fordirectories,itwillcallputNextEntry(),andthen,iftherecurseflagistrue,processeachentrythatisachildofthedirectory.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

OnProgressMessageEvent RaisestheProgressMessageevent

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Closethearchive.Thissimplycallstheunderlyingtarstream'sclose()method.

publicvoidCloseArchive();

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.CloseArchiveMethod

SharpZipCompressionLibrary

TheInputStreambasedconstructorscreateaTarArchiveforthepurposesofextractingorlistingatararchive.Thus,usetheseconstructorswhenyouwishtoextractfilesfromorlistthecontentsofanexistingtararchive.

OverloadListTheInputStreambasedconstructorscreateaTarArchiveforthepurposesofextractingorlistingatararchive.Thus,usetheseconstructorswhenyouwishtoextractfilesfromorlistthecontentsofanexistingtararchive.

publicstaticTarArchiveCreateInputTarArchive(Stream);

CreateTarArchiveforreadingsettingblockfactor

publicstaticTarArchiveCreateInputTarArchive(Stream,int);

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.CreateInputTarArchiveMethod

SharpZipCompressionLibrary

TheInputStreambasedconstructorscreateaTarArchiveforthepurposesofextractingorlistingatararchive.Thus,usetheseconstructorswhenyouwishtoextractfilesfromorlistthecontentsofanexistingtararchive.

publicstaticTarArchiveCreateInputTarArchive(

StreaminputStream

);

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace|TarArchive.CreateInputTarArchiveOverloadList

TarArchive.CreateInputTarArchiveMethod(Stream)

SharpZipCompressionLibrary

CreateTarArchiveforreadingsettingblockfactor

publicstaticTarArchiveCreateInputTarArchive(

StreaminputStream,

intblockFactor

);

ParametersinputStream

Streamfortararchivecontents

blockFactorTheblockingfactortoapply

ReturnValueTarArchive

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace|TarArchive.CreateInputTarArchiveOverloadList

TarArchive.CreateInputTarArchiveMethod(Stream,Int32)

SharpZipCompressionLibrary

CreateaTarArchiveforwritingto,usingthedefaultblockingfactor

OverloadListCreateaTarArchiveforwritingto,usingthedefaultblockingfactor

publicstaticTarArchiveCreateOutputTarArchive(Stream);

CreateaTarArchiveforwritingto

publicstaticTarArchiveCreateOutputTarArchive(Stream,int);

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.CreateOutputTarArchiveMethod

SharpZipCompressionLibrary

CreateaTarArchiveforwritingto,usingthedefaultblockingfactor

publicstaticTarArchiveCreateOutputTarArchive(

StreamoutputStream

);

ParametersoutputStream

Streamtowriteto

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace|TarArchive.CreateOutputTarArchiveOverloadList

TarArchive.CreateOutputTarArchiveMethod(Stream)

SharpZipCompressionLibrary

CreateaTarArchiveforwritingto

publicstaticTarArchiveCreateOutputTarArchive(

StreamoutputStream,

intblockFactor

);

ParametersoutputStream

Thestreamtowriteto

blockFactorTheblockingfactortouseforbuffering.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace|TarArchive.CreateOutputTarArchiveOverloadList

TarArchive.CreateOutputTarArchiveMethod(Stream,Int32)

SharpZipCompressionLibrary

Performthe"extract"commandandextractthecontentsofthearchive.

publicvoidExtractContents(

stringdestDir

);

ParametersdestDir

Thedestinationdirectoryintowhichtoextract.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.ExtractContentsMethod

SharpZipCompressionLibrary

Performthe"list"commandforthearchivecontents.NOTEThatthismethodusestheprogresseventtoactuallylistthecontents.Iftheprogressdisplayeventisnotset,nothingwillbelisted!

publicvoidListContents();

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.ListContentsMethod

SharpZipCompressionLibrary

RaisestheProgressMessageevent

protectedvirtualvoidOnProgressMessageEvent(

TarEntryentry,

stringmessage

);

Parametersentry

TarEntryforthisevent

messagemessageforthisevent.Nullisnomessage

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.OnProgressMessageEventMethod

SharpZipCompressionLibrary

Settheasciifiletranslationflag.Ifasciifiletranslationistrue,thenthefileischeckedtoseeifitabinaryfileornot.Iftheflagistrueandthetestindicatesitisasciitextfile,itwillbetranslated.Thetranslationconvertsthelocaloperatingsystem'sconceptoflineendsintotheUNIXlineend,'\n',whichisthedefactostandardforaTARarchive.ThismakestextfilescompatiblewithUNIX.

publicvoidSetAsciiTranslation(

boolasciiTranslate

);

ParametersasciiTranslate

Iftrue,translateasciitextfiles.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.SetAsciiTranslationMethod

SharpZipCompressionLibrary

Settheflagthatdetermineswhetherexistingfilesarekept,oroverwrittenduringextraction.

publicvoidSetKeepOldFiles(

boolkeepOldFiles

);

ParameterskeepOldFiles

Iftrue,donotoverwriteexistingfiles.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.SetKeepOldFilesMethod

SharpZipCompressionLibrary

Setuserandgroupinformationthatwillbeusedtofillinthetararchive'sentryheaders.Thisinformationbasedonthatavailableforthelinuxoperatingsystem,whichisnotalwaysavailableonotheroperatingsystems.TarArchiveallowstheprogrammertospecifyvaluestobeusedintheirplace.

publicvoidSetUserInfo(

intuserId,

stringuserName,

intgroupId,

stringgroupName

);

ParametersuserId

Theuseridtouseintheheaders.

userNameTheusernametouseintheheaders.

groupIdThegroupidtouseintheheaders.

groupNameThegroupnametouseintheheaders.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.SetUserInfoMethod

SharpZipCompressionLibrary

Writeanentrytothearchive.ThismethodwillcalltheputNextEntryandthenwritethecontentsoftheentry,andfinallycallcloseEntry()forentriesthatarefiles.Fordirectories,itwillcallputNextEntry(),andthen,iftherecurseflagistrue,processeachentrythatisachildofthedirectory.

publicvoidWriteEntry(

TarEntrysourceEntry,

boolrecurse

);

ParameterssourceEntry

TheTarEntryrepresentingtheentrytowritetothearchive.

recurseIftrue,processthechildrenofdirectoryentries.

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.WriteEntryMethod

SharpZipCompressionLibrary

TheeventsoftheTarArchiveclassarelistedbelow.ForacompletelistofTarArchiveclassmembers,seetheTarArchiveMemberstopic.

PublicInstanceEventsProgressMessageEvent Clienthookallowingdetailed

informationtobereportedduringprocessing

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchiveEvents

SharpZipCompressionLibrary

Clienthookallowingdetailedinformationtobereportedduringprocessing

publiceventProgressMessageHandlerProgressMessageEvent;

SeeAlsoTarArchiveClass|ICSharpCode.SharpZipLib.TarNamespace

TarArchive.ProgressMessageEventEvent

SharpZipCompressionLibrary

TheTarBufferclassimplementsthetararchiveconceptofabufferedinputstream.Thisconceptgoesbacktothedaysofblockedtapedrivesandspecialiodevices.IntheC#universe,theonlyrealfunctionthatthisclassperformsistoensurethatfileshavethecorrect"record"size,orothertarswillcomplain.

Youshouldneverhaveaneedtoaccessthisclassdirectly.TarBuffersarecreatedbyTarIOStreams.

Foralistofallmembersofthistype,seeTarBufferMembers.

System.ObjectICSharpCode.SharpZipLib.Tar.TarBuffer

publicclassTarBuffer

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarBufferMembers|ICSharpCode.SharpZipLib.TarNamespace

TarBufferClass

SharpZipCompressionLibrary

TarBufferoverview

PublicStaticFieldsBlockSize Thesizeofablockinatar

archiveinbytes.

DefaultBlockFactor Thenumberofblocksinadefaultrecord.

DefaultRecordSize Thesizeinbytesofadefaultrecord.

PublicStaticMethodsCreateInputTarBuffer Overloaded.CreateTarBuffer

forreadingwithdefaultBlockFactor

CreateOutputTarBuffer Overloaded.ConstructTarBufferforwritingwithdefaultBlockFactor

PublicInstancePropertiesBlockFactor GettheBlockingfactorforthe

buffer

RecordSize Gettherecordsizeforthisbuffer

PublicInstanceMethodsClose ClosetheTarBuffer.Ifthisisan

outputbuffer,alsoflushthecurrentblockbeforeclosing.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

TarBufferMembers

GetBlockFactor GettheTARBuffer'sblockfactor

GetCurrentBlockNum Getthecurrentblocknumber,withinthecurrentrecord,zerobased.

GetCurrentRecordNum Getthecurrentrecordnumber.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetRecordSize GettheTARBuffer'srecordsize.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsEOFBlock DetermineifanarchiveblockindicatesEndofArchive.Endofarchiveisindicatedbyablockthatconsistsentirelyofnullbytes.Allremainingblocksfortherecordshouldalsobenull'sHoweversomeoldertarsonlydoacoupleofnullblocks(OldGNUtarforone)andalsopartialrecords

ReadBlock Readablockfromtheinputstream.

SkipBlock Skipoverablockontheinputstream.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteBlock Overloaded.Writeablockofdatatothearchive.

ProtectedInstanceConstructors

TarBufferConstructor ConstructadefaultTarBuffer

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

ConstructadefaultTarBuffer

protectedTarBuffer();

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBufferConstructor

SharpZipCompressionLibrary

ThefieldsoftheTarBufferclassarelistedbelow.ForacompletelistofTarBufferclassmembers,seetheTarBufferMemberstopic.

PublicStaticFieldsBlockSize Thesizeofablockinatar

archiveinbytes.

DefaultBlockFactor Thenumberofblocksinadefaultrecord.

DefaultRecordSize Thesizeinbytesofadefaultrecord.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBufferFields

SharpZipCompressionLibrary

Thesizeofablockinatararchiveinbytes.

publicconstintBlockSize=512;

RemarksThisis512bytes.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.BlockSizeField

SharpZipCompressionLibrary

Thenumberofblocksinadefaultrecord.

publicconstintDefaultBlockFactor=20;

RemarksThedefaultvalueis20blockperrecord.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.DefaultBlockFactorField

SharpZipCompressionLibrary

Thesizeinbytesofadefaultrecord.

publicconstintDefaultRecordSize=

10240;

RemarksThedefaultsizeis10KB.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.DefaultRecordSizeField

SharpZipCompressionLibrary

ThepropertiesoftheTarBufferclassarelistedbelow.ForacompletelistofTarBufferclassmembers,seetheTarBufferMemberstopic.

PublicInstancePropertiesBlockFactor GettheBlockingfactorforthe

buffer

RecordSize Gettherecordsizeforthisbuffer

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBufferProperties

SharpZipCompressionLibrary

GettheBlockingfactorforthebuffer

publicintBlockFactor{get;}

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.BlockFactorProperty

SharpZipCompressionLibrary

Gettherecordsizeforthisbuffer

publicintRecordSize{get;}

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.RecordSizeProperty

SharpZipCompressionLibrary

ThemethodsoftheTarBufferclassarelistedbelow.ForacompletelistofTarBufferclassmembers,seetheTarBufferMemberstopic.

PublicStaticMethodsCreateInputTarBuffer Overloaded.CreateTarBuffer

forreadingwithdefaultBlockFactor

CreateOutputTarBuffer Overloaded.ConstructTarBufferforwritingwithdefaultBlockFactor

PublicInstanceMethodsClose ClosetheTarBuffer.Ifthisisan

outputbuffer,alsoflushthecurrentblockbeforeclosing.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetBlockFactor GettheTARBuffer'sblockfactor

GetCurrentBlockNum Getthecurrentblocknumber,withinthecurrentrecord,zerobased.

GetCurrentRecordNum Getthecurrentrecordnumber.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetRecordSize GettheTARBuffer'srecordsize.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

TarBufferMethods

IsEOFBlock DetermineifanarchiveblockindicatesEndofArchive.Endofarchiveisindicatedbyablockthatconsistsentirelyofnullbytes.Allremainingblocksfortherecordshouldalsobenull'sHoweversomeoldertarsonlydoacoupleofnullblocks(OldGNUtarforone)andalsopartialrecords

ReadBlock Readablockfromtheinputstream.

SkipBlock Skipoverablockontheinputstream.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteBlock Overloaded.Writeablockofdatatothearchive.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

ClosetheTarBuffer.Ifthisisanoutputbuffer,alsoflushthecurrentblockbeforeclosing.

publicvoidClose();

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.CloseMethod

SharpZipCompressionLibrary

CreateTarBufferforreadingwithdefaultBlockFactor

OverloadListCreateTarBufferforreadingwithdefaultBlockFactor

publicstaticTarBufferCreateInputTarBuffer(Stream);

ConstructTarBufferforreadinginputStreamsettingBlockFactor

publicstaticTarBufferCreateInputTarBuffer(Stream,int);

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.CreateInputTarBufferMethod

SharpZipCompressionLibrary

CreateTarBufferforreadingwithdefaultBlockFactor

publicstaticTarBufferCreateInputTarBuffer(

StreaminputStream

);

ParametersinputStream

Streamtobuffer

ReturnValueTarBuffer

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.CreateInputTarBufferOverloadList

TarBuffer.CreateInputTarBufferMethod(Stream)

SharpZipCompressionLibrary

ConstructTarBufferforreadinginputStreamsettingBlockFactor

publicstaticTarBufferCreateInputTarBuffer(

StreaminputStream,

intblockFactor

);

ParametersinputStream

Streamtobuffer

blockFactorBlockingfactortoapply

ReturnValueTarBuffer

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.CreateInputTarBufferOverloadList

TarBuffer.CreateInputTarBufferMethod(Stream,Int32)

SharpZipCompressionLibrary

ConstructTarBufferforwritingwithdefaultBlockFactor

OverloadListConstructTarBufferforwritingwithdefaultBlockFactor

publicstaticTarBufferCreateOutputTarBuffer(Stream);

ConstructTarBufferforwritingTaroutputtostreams.

publicstaticTarBufferCreateOutputTarBuffer(Stream,int);

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.CreateOutputTarBufferMethod

SharpZipCompressionLibrary

ConstructTarBufferforwritingwithdefaultBlockFactor

publicstaticTarBufferCreateOutputTarBuffer(

StreamoutputStream

);

ParametersoutputStream

outputstreamforbuffer

ReturnValueTarBuffer

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.CreateOutputTarBufferOverloadList

TarBuffer.CreateOutputTarBufferMethod(Stream)

SharpZipCompressionLibrary

ConstructTarBufferforwritingTaroutputtostreams.

publicstaticTarBufferCreateOutputTarBuffer(

StreamoutputStream,

intblockFactor

);

ParametersoutputStream

Outputstreamtowriteto.

blockFactorBlockingfactortoapply

ReturnValueTarBuffer

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.CreateOutputTarBufferOverloadList

TarBuffer.CreateOutputTarBufferMethod(Stream,Int32)

SharpZipCompressionLibrary

GettheTARBuffer'sblockfactor

publicintGetBlockFactor();

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.GetBlockFactorMethod

SharpZipCompressionLibrary

Getthecurrentblocknumber,withinthecurrentrecord,zerobased.

publicintGetCurrentBlockNum();

ReturnValueThecurrentzerobasedblocknumber.

RemarksTheabsoluteblocknumber=(recordnumber*blockfactor)+blocknumber.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.GetCurrentBlockNumMethod

SharpZipCompressionLibrary

Getthecurrentrecordnumber.

publicintGetCurrentRecordNum();

ReturnValueThecurrentzerobasedrecordnumber.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.GetCurrentRecordNumMethod

SharpZipCompressionLibrary

GettheTARBuffer'srecordsize.

publicintGetRecordSize();

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.GetRecordSizeMethod

SharpZipCompressionLibrary

DetermineifanarchiveblockindicatesEndofArchive.Endofarchiveisindicatedbyablockthatconsistsentirelyofnullbytes.Allremainingblocksfortherecordshouldalsobenull'sHoweversomeoldertarsonlydoacoupleofnullblocks(OldGNUtarforone)andalsopartialrecords

publicboolIsEOFBlock(

byte[]block

);

Parametersblock

Thedatablocktocheck.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.IsEOFBlockMethod

SharpZipCompressionLibrary

Readablockfromtheinputstream.

publicbyte[]ReadBlock();

ReturnValueTheblockofdataread.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.ReadBlockMethod

SharpZipCompressionLibrary

Skipoverablockontheinputstream.

publicvoidSkipBlock();

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.SkipBlockMethod

SharpZipCompressionLibrary

Writeablockofdatatothearchive.

OverloadListWriteablockofdatatothearchive.

publicvoidWriteBlock(byte[]);

Writeanarchiverecordtothearchive,wheretherecordmaybeinsideofalargerarraybuffer.Thebuffermustbe"offsetplusrecordsize"long.

publicvoidWriteBlock(byte[],int);

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace

TarBuffer.WriteBlockMethod

SharpZipCompressionLibrary

Writeablockofdatatothearchive.

publicvoidWriteBlock(

byte[]block

);

Parametersblock

Thedatatowritetothearchive.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.WriteBlockOverloadList

TarBuffer.WriteBlockMethod(Byte[])

SharpZipCompressionLibrary

Writeanarchiverecordtothearchive,wheretherecordmaybeinsideofalargerarraybuffer.Thebuffermustbe"offsetplusrecordsize"long.

publicvoidWriteBlock(

byte[]buf,

intoffset

);

Parametersbuf

Thebuffercontainingtherecorddatatowrite.

offsetTheoffsetoftherecorddatawithinbuf.

SeeAlsoTarBufferClass|ICSharpCode.SharpZipLib.TarNamespace|TarBuffer.WriteBlockOverloadList

TarBuffer.WriteBlockMethod(Byte[],Int32)

SharpZipCompressionLibrary

ThisclassrepresentsanentryinaTararchive.Itconsistsoftheentry'sheader,aswellastheentry'sFile.Entriescanbeinstantiatedinoneofthreeways,dependingonhowtheyaretobeused.

TarEntriesthatarecreatedfromtheheaderbytesreadfromanarchiveareinstantiatedwiththeTarEntry(byte[])constructor.Theseentrieswillbeusedwhenextractingfromorlistingthecontentsofanarchive.Theseentrieshavetheirheaderfilledinusingtheheaderbytes.TheyalsosettheFiletonull,sincetheyreferenceanarchiveentrynotafile.

TarEntriesthatarecreatedfromfilesthataretobewrittenintoanarchiveareinstantiatedwiththeCreateEntryFromFile(string)pseudoconstructor.TheseentrieshavetheirheaderfilledinusingtheFile'sinformation.TheyalsokeepareferencetotheFileforconveniencewhenwritingentries.

Finally,TarEntriescanbeconstructedfromnothingbutaname.Thisallowstheprogrammertoconstructtheentrybyhand,forinstancewhenonlyanInputStreamisavailableforwritingtothearchive,andtheheaderinformationisconstructedfromotherinformation.InthiscasetheheaderfieldsaresettodefaultsandtheFileissettonull.

TarHeader

Foralistofallmembersofthistype,seeTarEntryMembers.

System.ObjectICSharpCode.SharpZipLib.Tar.TarEntry

publicclassTarEntry:ICloneable

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(in

TarEntryClass

ICSharpCode.SharpZipLib.dll)

SeeAlsoTarEntryMembers|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

TarEntryoverview

PublicStaticMethodsCreateEntryFromFile Constructanentryforafile.File

issettofile,andtheheaderisconstructedfrominformationfromthefile.

CreateTarEntry Constructanentrywithonlyaname.Thisallowstheprogrammertoconstructtheentry'sheader"byhand".

PublicInstanceConstructorsTarEntry Overloaded.Initializesanew

instanceoftheTarEntryclass.

PublicInstancePropertiesFile Getthisentry'sfile.

GroupId Get/setthisentry'sgroupid.

GroupName Get/setthisentry'sgroupname.

IsDirectory Returntrueifthisentryrepresentsadirectory,falseotherwise

ModTime Get/Setthemodificationtimeforthisentry

Name Get/Setthisentry'sname.

Size Get/setthisentry'srecordedfilesize.

TarHeader Getthisentry'sheader.

UserId Get/setthisentry'suserid.

TarEntryMembers

UserName Get/setthisentry'susername.

PublicInstanceMethodsAdjustEntryName Conveniencemethodthatwill

modifyanentry'snamedirectlyinplaceinanentryheaderbufferbytearray.

Clone Clonethistarentry.

Equals Determineifthetwoentriesareequal.Equalityisdeterminedbytheheadernamesbeingequal.

GetDirectoryEntries Getentriesforallfilespresentinthisentriesdirectory.Ifthisentrydoesntrepresentadirectoryzeroentriesarereturned.

GetFileTarHeader FillinaTarHeaderwithinformationfromaFile.

GetHashCode MustbeoverriddenwhenyouoverrideEquals.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsDescendent Determineifthegivenentryisadescendantofthisentry.Descendancyisdeterminedbythenameofthedescendantstartingwiththisentry'sname.

NameTarHeader FillinaTarHeadergivenonlytheentry'sname.

SetIds Conveniencemethodtosetthisentry'sgroupanduserids.

SetNames Conveniencemethodtosetthisentry'sgroupandusernames.

ToString(inheritedfrom ReturnsaStringthatrepresents

Object) thecurrentObject.

WriteEntryHeader Writeanentry'sheaderinformationtoaheaderbuffer.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Constructanentryfromanarchive'sheaderbytes.Fileissettonull.

OverloadListConstructaTarEntryusingtheheaderprovided

publicTarEntry(TarHeader);

Constructanentryfromanarchive'sheaderbytes.Fileissettonull.

publicTarEntry(byte[]);

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntryConstructor

SharpZipCompressionLibrary

Constructanentryfromanarchive'sheaderbytes.Fileissettonull.

publicTarEntry(

byte[]headerBuf

);

ParametersheaderBuf

Theheaderbytesfromatararchiveentry.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace|TarEntryConstructorOverloadList

TarEntryConstructor(Byte[])

SharpZipCompressionLibrary

ConstructaTarEntryusingtheheaderprovided

publicTarEntry(

TarHeaderheader

);

Parametersheader

Headerdetailsforentry

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace|TarEntryConstructorOverloadList

TarEntryConstructor(TarHeader)

SharpZipCompressionLibrary

ThepropertiesoftheTarEntryclassarelistedbelow.ForacompletelistofTarEntryclassmembers,seetheTarEntryMemberstopic.

PublicInstancePropertiesFile Getthisentry'sfile.

GroupId Get/setthisentry'sgroupid.

GroupName Get/setthisentry'sgroupname.

IsDirectory Returntrueifthisentryrepresentsadirectory,falseotherwise

ModTime Get/Setthemodificationtimeforthisentry

Name Get/Setthisentry'sname.

Size Get/setthisentry'srecordedfilesize.

TarHeader Getthisentry'sheader.

UserId Get/setthisentry'suserid.

UserName Get/setthisentry'susername.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntryProperties

SharpZipCompressionLibrary

Getthisentry'sfile.

publicstringFile{get;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.FileProperty

SharpZipCompressionLibrary

Get/setthisentry'sgroupid.

publicintGroupId{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.GroupIdProperty

SharpZipCompressionLibrary

Get/setthisentry'sgroupname.

publicstringGroupName{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.GroupNameProperty

SharpZipCompressionLibrary

Returntrueifthisentryrepresentsadirectory,falseotherwise

publicboolIsDirectory{get;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.IsDirectoryProperty

SharpZipCompressionLibrary

Get/Setthemodificationtimeforthisentry

publicSystem.DateTimeModTime{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.ModTimeProperty

SharpZipCompressionLibrary

Get/Setthisentry'sname.

publicstringName{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.NameProperty

SharpZipCompressionLibrary

Get/setthisentry'srecordedfilesize.

publiclongSize{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.SizeProperty

SharpZipCompressionLibrary

Getthisentry'sheader.

publicTarHeaderTarHeader{get;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.TarHeaderProperty

SharpZipCompressionLibrary

Get/setthisentry'suserid.

publicintUserId{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.UserIdProperty

SharpZipCompressionLibrary

Get/setthisentry'susername.

publicstringUserName{get;set;}

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.UserNameProperty

SharpZipCompressionLibrary

ThemethodsoftheTarEntryclassarelistedbelow.ForacompletelistofTarEntryclassmembers,seetheTarEntryMemberstopic.

PublicStaticMethodsCreateEntryFromFile Constructanentryforafile.File

issettofile,andtheheaderisconstructedfrominformationfromthefile.

CreateTarEntry Constructanentrywithonlyaname.Thisallowstheprogrammertoconstructtheentry'sheader"byhand".

PublicInstanceMethodsAdjustEntryName Conveniencemethodthatwill

modifyanentry'snamedirectlyinplaceinanentryheaderbufferbytearray.

Clone Clonethistarentry.

Equals Determineifthetwoentriesareequal.Equalityisdeterminedbytheheadernamesbeingequal.

GetDirectoryEntries Getentriesforallfilespresentinthisentriesdirectory.Ifthisentrydoesntrepresentadirectoryzeroentriesarereturned.

GetFileTarHeader FillinaTarHeaderwithinformationfromaFile.

GetHashCode MustbeoverriddenwhenyouoverrideEquals.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

TarEntryMethods

IsDescendent Determineifthegivenentryisadescendantofthisentry.Descendancyisdeterminedbythenameofthedescendantstartingwiththisentry'sname.

NameTarHeader FillinaTarHeadergivenonlytheentry'sname.

SetIds Conveniencemethodtosetthisentry'sgroupanduserids.

SetNames Conveniencemethodtosetthisentry'sgroupandusernames.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteEntryHeader Writeanentry'sheaderinformationtoaheaderbuffer.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Conveniencemethodthatwillmodifyanentry'snamedirectlyinplaceinanentryheaderbufferbytearray.

publicvoidAdjustEntryName(

byte[]outbuf,

stringnewName

);

Parametersoutbuf

Thebuffercontainingtheentryheadertomodify.

newNameThenewnametoplaceintotheheaderbuffer.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.AdjustEntryNameMethod

SharpZipCompressionLibrary

Clonethistarentry.

publicobjectClone();

ReturnValueReturnsacloneofthisentry.

ImplementsICloneable.Clone

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.CloneMethod

SharpZipCompressionLibrary

Constructanentryforafile.Fileissettofile,andtheheaderisconstructedfrominformationfromthefile.

publicstaticTarEntryCreateEntryFromFile(

stringfileName

);

ParametersfileName

Thefilethattheentryrepresents.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.CreateEntryFromFileMethod

SharpZipCompressionLibrary

Constructanentrywithonlyaname.Thisallowstheprogrammertoconstructtheentry'sheader"byhand".

publicstaticTarEntryCreateTarEntry(

stringname

);

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.CreateTarEntryMethod

SharpZipCompressionLibrary

Determineifthetwoentriesareequal.Equalityisdeterminedbytheheadernamesbeingequal.

publicoverrideboolEquals(

objectit

);

ReturnValueTrueiftheentriesareequal.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.EqualsMethod

SharpZipCompressionLibrary

Getentriesforallfilespresentinthisentriesdirectory.Ifthisentrydoesntrepresentadirectoryzeroentriesarereturned.

publicTarEntry[]GetDirectoryEntries();

ReturnValueAnarrayofTarEntry'sforthisentry'schildren.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.GetDirectoryEntriesMethod

SharpZipCompressionLibrary

FillinaTarHeaderwithinformationfromaFile.

publicvoidGetFileTarHeader(

TarHeaderhdr,

stringfile

);

Parametershdr

TheTarHeadertofillin.

fileThefilefromwhichtogettheheaderinformation.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.GetFileTarHeaderMethod

SharpZipCompressionLibrary

MustbeoverriddenwhenyouoverrideEquals.

publicoverrideintGetHashCode();

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.GetHashCodeMethod

SharpZipCompressionLibrary

Determineifthegivenentryisadescendantofthisentry.Descendancyisdeterminedbythenameofthedescendantstartingwiththisentry'sname.

publicboolIsDescendent(

TarEntrydesc

);

Parametersdesc

Entrytobecheckedasadescendentofthis.

ReturnValueTrueifentryisadescendantofthis.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.IsDescendentMethod

SharpZipCompressionLibrary

FillinaTarHeadergivenonlytheentry'sname.

publicvoidNameTarHeader(

TarHeaderhdr,

stringname

);

Parametershdr

TheTarHeadertofillin.

nameThetarentryname.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.NameTarHeaderMethod

SharpZipCompressionLibrary

Conveniencemethodtosetthisentry'sgroupanduserids.

publicvoidSetIds(

intuserId,

intgroupId

);

ParametersuserId

Thisentry'snewuserid.

groupIdThisentry'snewgroupid.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.SetIdsMethod

SharpZipCompressionLibrary

Conveniencemethodtosetthisentry'sgroupandusernames.

publicvoidSetNames(

stringuserName,

stringgroupName

);

ParametersuserName

Thisentry'snewusername.

groupNameThisentry'snewgroupname.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.SetNamesMethod

SharpZipCompressionLibrary

Writeanentry'sheaderinformationtoaheaderbuffer.

publicvoidWriteEntryHeader(

byte[]outbuf

);

Parametersoutbuf

Thetarentryheaderbuffertofillin.

SeeAlsoTarEntryClass|ICSharpCode.SharpZipLib.TarNamespace

TarEntry.WriteEntryHeaderMethod

SharpZipCompressionLibrary

TarExceptionsareusedforexceptionsspecifictotarclassesandcode.

Foralistofallmembersofthistype,seeTarExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.Tar.TarExceptionICSharpCode.SharpZipLib.Tar.InvalidHeaderException

publicclassTarException:

SharpZipBaseException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarExceptionMembers|ICSharpCode.SharpZipLib.TarNamespace

TarExceptionClass

SharpZipCompressionLibrary

TarExceptionoverview

PublicInstanceConstructorsTarException Overloaded.Initializesanew

instanceoftheTarExceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

TarExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarExceptionClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

InitialisesanewinstanceoftheTarExceptionclass.

OverloadListInitialisesanewinstanceoftheTarExceptionclass.

publicTarException();

InitialisesanewinstanceoftheTarExceptionclasswithaspecifiedmessage.

publicTarException(string);

SeeAlsoTarExceptionClass|ICSharpCode.SharpZipLib.TarNamespace

TarExceptionConstructor

SharpZipCompressionLibrary

InitialisesanewinstanceoftheTarExceptionclass.

publicTarException();

SeeAlsoTarExceptionClass|ICSharpCode.SharpZipLib.TarNamespace|TarExceptionConstructorOverloadList

TarExceptionConstructor()

SharpZipCompressionLibrary

InitialisesanewinstanceoftheTarExceptionclasswithaspecifiedmessage.

publicTarException(

stringmessage

);

Parametersmessage

Themessagethatdescribestheerror.

SeeAlsoTarExceptionClass|ICSharpCode.SharpZipLib.TarNamespace|TarExceptionConstructorOverloadList

TarExceptionConstructor(String)

SharpZipCompressionLibrary

ThisclassencapsulatestheTarEntryHeaderusedinTarArchives.Theclassalsoholdsanumberoftarconstants,usedmostlyinheaders.

Foralistofallmembersofthistype,seeTarHeaderMembers.

System.ObjectICSharpCode.SharpZipLib.Tar.TarHeader

publicclassTarHeader:ICloneable

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarHeaderMembers|ICSharpCode.SharpZipLib.TarNamespace

TarHeaderClass

SharpZipCompressionLibrary

TarHeaderoverview

PublicStaticFieldsCHKSUMLEN Thelengthofthechecksum

fieldinaheaderbuffer.

CHKSUMOFS Offsetofchecksuminaheaderbuffer.

DEVLEN Thelengthofthedevicesfieldinaheaderbuffer.

GIDLEN Thelengthofthegroupidfieldinaheaderbuffer.

GNAMELEN Thelengthofthegroupnamefieldinaheaderbuffer.

GNU_TMAGIC ThemagictagrepresentinganoldGNUtararchivewhereversionisincludedinmagicandoverwritesit

LF_ACL Solarisaccesscontrollistfiletype

LF_BLK Blockdevicefiletype.

LF_CHR Characterdevicefiletype.

LF_CONTIG Contiguousfiletype.

LF_DIR Directoryfiletype.

LF_EXTATTR SolarisExtendedAttributeFile

LF_FIFO FIFO(pipe)filetype.

LF_GHDR Posix.12001globalextendedheader

LF_GNU_DUMPDIR GNUdirdumpfiletypeThisisadirentrythatcontainsthenamesoffilesthatwereinthe

TarHeaderMembers

diratthetimethedumpwasmade

LF_GNU_LONGLINK Identifiesthenextfileonthetapeashavingalonglinkname

LF_GNU_LONGNAME Identifiesthenextfileonthetapeashavingalongname

LF_GNU_MULTIVOL Continuationofafilethatbeganonanothervolume

LF_GNU_NAMES Forstoringfilenamesthatdontfitinthemainheader(oldGNU)

LF_GNU_SPARSE GNUSparsefile

LF_GNU_VOLHDR GNUTape/volumeheaderignoreonextraction

LF_LINK Linkfiletype.

LF_META Inode(metadataonly)nofilecontent

LF_NORMAL Normalfiletype.

LF_OLDNORM The"oldway"ofindicatinganormalfile.

LF_SYMLINK Symboliclinkfiletype.

LF_XHDR Posix.12001extendedheader

MAGICLEN Thelengthofthemagicfieldinaheaderbuffer.

MODELEN Thelengthofthemodefieldinaheaderbuffer.

MODTIMELEN Thelengthofthemodificationtimefieldinaheaderbuffer.

NAMELEN Thelengthofthenamefieldinaheaderbuffer.

SIZELEN Thelengthofthesizefieldinaheaderbuffer.

TMAGIC ThemagictagrepresentingaPOSIXtararchive.(includestrailingNULL)

UIDLEN Thelengthoftheuseridfieldinaheaderbuffer.

UNAMELEN Thelengthoftheusernamefieldinaheaderbuffer.

VERSIONLEN Thelengthoftheversionfieldinaheaderbuffer.

PublicStaticMethodsGetAsciiBytes Addastringtoabufferasa

collectionofasciibytes.

GetLongOctalBytes Putanoctalrepresentationofavalueintoabuffer

GetNameBytes Overloaded.Addnametothebufferasacollectionofbytes

GetOctalBytes Putanoctalrepresentationofavalueintoabuffer

ParseName Parseanamefromaheaderbuffer.

ParseOctal Parseanoctalstringfromaheaderbuffer.

ResetValueDefaults Resetvaluedefaultstoinitialvalues.

SetValueDefaults SetdefaultsforvaluesusedwhenconstructingaTarHeaderinstance.

PublicInstanceConstructorsTarHeaderConstructor InitialiseadefaultTarHeader

instance

PublicInstancePropertiesChecksum Gettheentry'schecksum.This

isonlyvalid/updatedafterwritingorreadinganentry.

DevMajor Get/settheentry'smajordevicenumber.

DevMinor Get/settheentry'sminordevicenumber.

GroupId Get/settheentry'sgroupid.

GroupName Get/settheentry'sgroupname.

IsChecksumValid Getvalueoftrueiftheheaderchecksumisvalid,falseotherwise.

LinkName Theentry'slinkname.

Magic Get/settheentry'smagictag.

Mode Get/settheentry'sUnixstylepermissionmode.

ModTime Get/settheentry'smodificationtime.

Name Get/setthenameforthistarentry.

Size Get/settheentry'ssize.

TypeFlag Get/settheentry'stypeflag.

UserId Theentry'suserid.

UserName Theentry'susername.

Version Theentry'sversion.

PublicInstanceMethodsClone CloneaTARheader.

Equals Determinesifthisinstanceis

equaltothespecifiedobject.

GetHashCode Getahashcodeforthecurrentobject.

GetName Obsolete.Getthenameofthisentry.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ParseBuffer ParseTarHeaderinformationfromaheaderbuffer.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteHeader 'Write'headerinformationtobufferprovided,updatingthechecksum.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

InitialiseadefaultTarHeaderinstance

publicTarHeader();

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeaderConstructor

SharpZipCompressionLibrary

ThefieldsoftheTarHeaderclassarelistedbelow.ForacompletelistofTarHeaderclassmembers,seetheTarHeaderMemberstopic.

PublicStaticFieldsCHKSUMLEN Thelengthofthechecksum

fieldinaheaderbuffer.

CHKSUMOFS Offsetofchecksuminaheaderbuffer.

DEVLEN Thelengthofthedevicesfieldinaheaderbuffer.

GIDLEN Thelengthofthegroupidfieldinaheaderbuffer.

GNAMELEN Thelengthofthegroupnamefieldinaheaderbuffer.

GNU_TMAGIC ThemagictagrepresentinganoldGNUtararchivewhereversionisincludedinmagicandoverwritesit

LF_ACL Solarisaccesscontrollistfiletype

LF_BLK Blockdevicefiletype.

LF_CHR Characterdevicefiletype.

LF_CONTIG Contiguousfiletype.

LF_DIR Directoryfiletype.

LF_EXTATTR SolarisExtendedAttributeFile

LF_FIFO FIFO(pipe)filetype.

LF_GHDR Posix.12001globalextendedheader

LF_GNU_DUMPDIR GNUdirdumpfiletypeThisisadirentrythatcontainsthe

TarHeaderFields

namesoffilesthatwereinthediratthetimethedumpwasmade

LF_GNU_LONGLINK Identifiesthenextfileonthetapeashavingalonglinkname

LF_GNU_LONGNAME Identifiesthenextfileonthetapeashavingalongname

LF_GNU_MULTIVOL Continuationofafilethatbeganonanothervolume

LF_GNU_NAMES Forstoringfilenamesthatdontfitinthemainheader(oldGNU)

LF_GNU_SPARSE GNUSparsefile

LF_GNU_VOLHDR GNUTape/volumeheaderignoreonextraction

LF_LINK Linkfiletype.

LF_META Inode(metadataonly)nofilecontent

LF_NORMAL Normalfiletype.

LF_OLDNORM The"oldway"ofindicatinganormalfile.

LF_SYMLINK Symboliclinkfiletype.

LF_XHDR Posix.12001extendedheader

MAGICLEN Thelengthofthemagicfieldinaheaderbuffer.

MODELEN Thelengthofthemodefieldinaheaderbuffer.

MODTIMELEN Thelengthofthemodificationtimefieldinaheaderbuffer.

NAMELEN Thelengthofthenamefieldinaheaderbuffer.

SIZELEN Thelengthofthesizefieldina

headerbuffer.

TMAGIC ThemagictagrepresentingaPOSIXtararchive.(includestrailingNULL)

UIDLEN Thelengthoftheuseridfieldinaheaderbuffer.

UNAMELEN Thelengthoftheusernamefieldinaheaderbuffer.

VERSIONLEN Thelengthoftheversionfieldinaheaderbuffer.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Thelengthofthechecksumfieldinaheaderbuffer.

publicstaticreadonlyintCHKSUMLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.CHKSUMLENField

SharpZipCompressionLibrary

Offsetofchecksuminaheaderbuffer.

publicconstintCHKSUMOFS=148;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.CHKSUMOFSField

SharpZipCompressionLibrary

Thelengthofthedevicesfieldinaheaderbuffer.

publicstaticreadonlyintDEVLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.DEVLENField

SharpZipCompressionLibrary

Thelengthofthegroupidfieldinaheaderbuffer.

publicstaticreadonlyintGIDLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GIDLENField

SharpZipCompressionLibrary

Thelengthofthegroupnamefieldinaheaderbuffer.

publicstaticreadonlyintGNAMELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GNAMELENField

SharpZipCompressionLibrary

ThemagictagrepresentinganoldGNUtararchivewhereversionisincludedinmagicandoverwritesit

publicstaticreadonlystringGNU_TMAGIC;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GNU_TMAGICField

SharpZipCompressionLibrary

Solarisaccesscontrollistfiletype

publicconstbyteLF_ACL=65;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_ACLField

SharpZipCompressionLibrary

Blockdevicefiletype.

publicconstbyteLF_BLK=52;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_BLKField

SharpZipCompressionLibrary

Characterdevicefiletype.

publicconstbyteLF_CHR=51;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_CHRField

SharpZipCompressionLibrary

Contiguousfiletype.

publicconstbyteLF_CONTIG=55;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_CONTIGField

SharpZipCompressionLibrary

Directoryfiletype.

publicconstbyteLF_DIR=53;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_DIRField

SharpZipCompressionLibrary

SolarisExtendedAttributeFile

publicconstbyteLF_EXTATTR=69;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_EXTATTRField

SharpZipCompressionLibrary

FIFO(pipe)filetype.

publicconstbyteLF_FIFO=54;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_FIFOField

SharpZipCompressionLibrary

Posix.12001globalextendedheader

publicconstbyteLF_GHDR=103;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GHDRField

SharpZipCompressionLibrary

GNUdirdumpfiletypeThisisadirentrythatcontainsthenamesoffilesthatwereinthediratthetimethedumpwasmade

publicconstbyteLF_GNU_DUMPDIR=68;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_DUMPDIRField

SharpZipCompressionLibrary

Identifiesthenextfileonthetapeashavingalonglinkname

publicconstbyteLF_GNU_LONGLINK=75;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_LONGLINKField

SharpZipCompressionLibrary

Identifiesthenextfileonthetapeashavingalongname

publicconstbyteLF_GNU_LONGNAME=76;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_LONGNAMEField

SharpZipCompressionLibrary

Continuationofafilethatbeganonanothervolume

publicconstbyteLF_GNU_MULTIVOL=77;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_MULTIVOLField

SharpZipCompressionLibrary

Forstoringfilenamesthatdontfitinthemainheader(oldGNU)

publicconstbyteLF_GNU_NAMES=78;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_NAMESField

SharpZipCompressionLibrary

GNUSparsefile

publicconstbyteLF_GNU_SPARSE=83;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_SPARSEField

SharpZipCompressionLibrary

GNUTape/volumeheaderignoreonextraction

publicconstbyteLF_GNU_VOLHDR=86;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_GNU_VOLHDRField

SharpZipCompressionLibrary

Linkfiletype.

publicconstbyteLF_LINK=49;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_LINKField

SharpZipCompressionLibrary

Inode(metadataonly)nofilecontent

publicconstbyteLF_META=73;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_METAField

SharpZipCompressionLibrary

Normalfiletype.

publicconstbyteLF_NORMAL=48;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_NORMALField

SharpZipCompressionLibrary

The"oldway"ofindicatinganormalfile.

publicconstbyteLF_OLDNORM=0;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_OLDNORMField

SharpZipCompressionLibrary

Symboliclinkfiletype.

publicconstbyteLF_SYMLINK=50;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_SYMLINKField

SharpZipCompressionLibrary

Posix.12001extendedheader

publicstaticreadonlybyteLF_XHDR;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LF_XHDRField

SharpZipCompressionLibrary

Thelengthofthemagicfieldinaheaderbuffer.

publicstaticreadonlyintMAGICLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.MAGICLENField

SharpZipCompressionLibrary

Thelengthofthemodefieldinaheaderbuffer.

publicstaticreadonlyintMODELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.MODELENField

SharpZipCompressionLibrary

Thelengthofthemodificationtimefieldinaheaderbuffer.

publicstaticreadonlyintMODTIMELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.MODTIMELENField

SharpZipCompressionLibrary

Thelengthofthenamefieldinaheaderbuffer.

publicstaticreadonlyintNAMELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.NAMELENField

SharpZipCompressionLibrary

Thelengthofthesizefieldinaheaderbuffer.

publicstaticreadonlyintSIZELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.SIZELENField

SharpZipCompressionLibrary

ThemagictagrepresentingaPOSIXtararchive.(includestrailingNULL)

publicstaticreadonlystringTMAGIC;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.TMAGICField

SharpZipCompressionLibrary

Thelengthoftheuseridfieldinaheaderbuffer.

publicstaticreadonlyintUIDLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.UIDLENField

SharpZipCompressionLibrary

Thelengthoftheusernamefieldinaheaderbuffer.

publicstaticreadonlyintUNAMELEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.UNAMELENField

SharpZipCompressionLibrary

Thelengthoftheversionfieldinaheaderbuffer.

publicstaticreadonlyintVERSIONLEN;

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.VERSIONLENField

SharpZipCompressionLibrary

ThepropertiesoftheTarHeaderclassarelistedbelow.ForacompletelistofTarHeaderclassmembers,seetheTarHeaderMemberstopic.

PublicInstancePropertiesChecksum Gettheentry'schecksum.This

isonlyvalid/updatedafterwritingorreadinganentry.

DevMajor Get/settheentry'smajordevicenumber.

DevMinor Get/settheentry'sminordevicenumber.

GroupId Get/settheentry'sgroupid.

GroupName Get/settheentry'sgroupname.

IsChecksumValid Getvalueoftrueiftheheaderchecksumisvalid,falseotherwise.

LinkName Theentry'slinkname.

Magic Get/settheentry'smagictag.

Mode Get/settheentry'sUnixstylepermissionmode.

ModTime Get/settheentry'smodificationtime.

Name Get/setthenameforthistarentry.

Size Get/settheentry'ssize.

TypeFlag Get/settheentry'stypeflag.

UserId Theentry'suserid.

UserName Theentry'susername.

TarHeaderProperties

Version Theentry'sversion.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Gettheentry'schecksum.Thisisonlyvalid/updatedafterwritingorreadinganentry.

publicintChecksum{get;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ChecksumProperty

SharpZipCompressionLibrary

Get/settheentry'smajordevicenumber.

publicintDevMajor{get;set;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.DevMajorProperty

SharpZipCompressionLibrary

Get/settheentry'sminordevicenumber.

publicintDevMinor{get;set;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.DevMinorProperty

SharpZipCompressionLibrary

Get/settheentry'sgroupid.

publicintGroupId{get;set;}

RemarksThisisonlydirectlyrelevanttolinux/unixsystems.Thedefaultvalueiszero.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GroupIdProperty

SharpZipCompressionLibrary

Get/settheentry'sgroupname.

publicstringGroupName{get;set;}

RemarksThisisonlydirectlyrelevanttounixsystems.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GroupNameProperty

SharpZipCompressionLibrary

Getvalueoftrueiftheheaderchecksumisvalid,falseotherwise.

publicboolIsChecksumValid{get;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.IsChecksumValidProperty

SharpZipCompressionLibrary

Theentry'slinkname.

publicstringLinkName{get;set;}

ExceptionsExceptionType ConditionArgumentNullException Thrownwhenattemptingtoset

LinkNametonull.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.LinkNameProperty

SharpZipCompressionLibrary

Get/settheentry'smagictag.

publicstringMagic{get;set;}

ExceptionsExceptionType ConditionArgumentNullException Thrownwhenattemptingtoset

Magictonull.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.MagicProperty

SharpZipCompressionLibrary

Get/settheentry'sUnixstylepermissionmode.

publicintMode{get;set;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ModeProperty

SharpZipCompressionLibrary

Get/settheentry'smodificationtime.

publicSystem.DateTimeModTime{get;set;}

RemarksThemodificationtimeisonlyaccuratetowithinasecond.

ExceptionsExceptionType ConditionArgumentOutOfRangeException Thrownwhensettingthedate

timetolessthan1/1/1970.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ModTimeProperty

SharpZipCompressionLibrary

Get/setthenameforthistarentry.

publicstringName{get;set;}

ExceptionsExceptionType ConditionArgumentNullException Thrownwhenattemptingtoset

thepropertytonull.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.NameProperty

SharpZipCompressionLibrary

Get/settheentry'ssize.

publiclongSize{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Thrownwhensettingthesizeto

lessthanzero.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.SizeProperty

SharpZipCompressionLibrary

Get/settheentry'stypeflag.

publicbyteTypeFlag{get;set;}

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.TypeFlagProperty

SharpZipCompressionLibrary

Theentry'suserid.

publicintUserId{get;set;}

RemarksThisisonlydirectlyrelevanttounixsystems.Thedefaultiszero.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.UserIdProperty

SharpZipCompressionLibrary

Theentry'susername.

publicstringUserName{get;set;}

RemarksSeeResetValueDefaultsfordetailonhowthisvalueisderived.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.UserNameProperty

SharpZipCompressionLibrary

Theentry'sversion.

publicstringVersion{get;set;}

ExceptionsExceptionType ConditionArgumentNullException Thrownwhenattemptingtoset

Versiontonull.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.VersionProperty

SharpZipCompressionLibrary

ThemethodsoftheTarHeaderclassarelistedbelow.ForacompletelistofTarHeaderclassmembers,seetheTarHeaderMemberstopic.

PublicStaticMethodsGetAsciiBytes Addastringtoabufferasa

collectionofasciibytes.

GetLongOctalBytes Putanoctalrepresentationofavalueintoabuffer

GetNameBytes Overloaded.Addnametothebufferasacollectionofbytes

GetOctalBytes Putanoctalrepresentationofavalueintoabuffer

ParseName Parseanamefromaheaderbuffer.

ParseOctal Parseanoctalstringfromaheaderbuffer.

ResetValueDefaults Resetvaluedefaultstoinitialvalues.

SetValueDefaults SetdefaultsforvaluesusedwhenconstructingaTarHeaderinstance.

PublicInstanceMethodsClone CloneaTARheader.

Equals Determinesifthisinstanceisequaltothespecifiedobject.

GetHashCode Getahashcodeforthecurrentobject.

GetName Obsolete.Getthenameofthisentry.

TarHeaderMethods

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ParseBuffer ParseTarHeaderinformationfromaheaderbuffer.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteHeader 'Write'headerinformationtobufferprovided,updatingthechecksum.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

CloneaTARheader.

publicobjectClone();

ImplementsICloneable.Clone

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.CloneMethod

SharpZipCompressionLibrary

Determinesifthisinstanceisequaltothespecifiedobject.

publicoverrideboolEquals(

objectobj

);

Parametersobj

Theobjecttocomparewith.

ReturnValuetrueiftheobjectsareequal,falseotherwise.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.EqualsMethod

SharpZipCompressionLibrary

Addastringtoabufferasacollectionofasciibytes.

publicstaticintGetAsciiBytes(

stringtoAdd,

intnameOffset,

byte[]buffer,

intbufferOffset,

intlength

);

ParameterstoAdd

Thestringtoadd

nameOffsetTheoffsetofthefirstcharactertoadd.

bufferThebuffertoaddto.

bufferOffsetTheoffsettostartaddingat.

lengthThenumberofasciicharacterstoadd.

ReturnValueThenextfreeindexinthebuffer.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetAsciiBytesMethod

SharpZipCompressionLibrary

Getahashcodeforthecurrentobject.

publicoverrideintGetHashCode();

ReturnValueAhashcodeforthecurrentobject.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetHashCodeMethod

SharpZipCompressionLibrary

Putanoctalrepresentationofavalueintoabuffer

publicstaticintGetLongOctalBytes(

longval,

byte[]buf,

intoffset,

intlength

);

Parametersval

Valuetobeconverttooctal

bufThebuffertoupdate

offsetTheoffsetintothebuffertostorethevalue

lengthThelengthoftheoctalstring

ReturnValueIndexofnextbyte

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetLongOctalBytesMethod

SharpZipCompressionLibrary

NOTE:Thismethodisnowobsolete.

Getthenameofthisentry.

publicstringGetName();

ReturnValueTheentry'sname.

RemarksThisisobsoleteusetheNamepropertyinstead.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetNameMethod

SharpZipCompressionLibrary

Addanentrynametothebuffer

OverloadListAddanentrynametothebuffer

publicstaticintGetNameBytes(string,byte[],int,int);

Addnametothebufferasacollectionofbytes

publicstaticintGetNameBytes(string,int,byte[],int,int);

Addanentrynametothebuffer

publicstaticintGetNameBytes(StringBuilder,byte[],int,int);

Addnametothebufferasacollectionofbytes

publicstaticintGetNameBytes(StringBuilder,int,byte[],int,int);

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetNameBytesMethod

SharpZipCompressionLibrary

Addanentrynametothebuffer

publicstaticintGetNameBytes(

stringname,

byte[]buf,

intoffset,

intlength

);

Parametersname

Thenametoadd

bufThebuffertoaddto

offsetTheoffsetintothebufferfromwhichtostartadding

lengthThenumberofheaderbytestoadd

ReturnValueTheindexofthenextfreebyteinthebuffer

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace|TarHeader.GetNameBytesOverloadList

TarHeader.GetNameBytesMethod(String,Byte[],Int32,Int32)

SharpZipCompressionLibrary

Addnametothebufferasacollectionofbytes

publicstaticintGetNameBytes(

stringname,

intnameOffset,

byte[]buf,

intbufferOffset,

intlength

);

Parametersname

Thenametoadd

nameOffsetTheoffsetofthefirstcharacter

bufThebuffertoaddto

bufferOffsetTheindexofthefirstbytetoadd

lengthThenumberofcharacters/bytestoadd

ReturnValueThenextfreeindexinthebuf

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace|TarHeader.GetNameBytesOverloadList

TarHeader.GetNameBytesMethod(String,Int32,Byte[],Int32,Int32)

SharpZipCompressionLibrary

Addanentrynametothebuffer

publicstaticintGetNameBytes(

StringBuildername,

byte[]buf,

intoffset,

intlength

);

Parametersname

Thenametoadd

bufThebuffertoaddto

offsetTheoffsetintothebufferfromwhichtostartadding

lengthThenumberofheaderbytestoadd

ReturnValueTheindexofthenextfreebyteinthebuffer

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace|TarHeader.GetNameBytesOverloadList

TarHeader.GetNameBytesMethod(StringBuilder,Byte[],Int32,Int32)

SharpZipCompressionLibrary

Addnametothebufferasacollectionofbytes

publicstaticintGetNameBytes(

StringBuildername,

intnameOffset,

byte[]buf,

intbufferOffset,

intlength

);

Parametersname

Thenametoadd

nameOffsetTheoffsetofthefirstcharacter

bufThebuffertoaddto

bufferOffsetTheindexofthefirstbytetoadd

lengthThenumberofcharacters/bytestoadd

ReturnValueThenextfreeindexinthebuf

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace|TarHeader.GetNameBytesOverloadList

TarHeader.GetNameBytesMethod(StringBuilder,Int32,Byte[],Int32,Int32)

SharpZipCompressionLibrary

Putanoctalrepresentationofavalueintoabuffer

publicstaticintGetOctalBytes(

longval,

byte[]buf,

intoffset,

intlength

);

Parametersval

thevaluetobeconvertedtooctal

bufbuffertostoretheoctalstring

offsetTheoffsetintothebufferwherethevaluestarts

lengthThelengthoftheoctalstringtocreate

ReturnValueTheoffsetofthecharacternextbyteaftertheoctalstring

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.GetOctalBytesMethod

SharpZipCompressionLibrary

ParseTarHeaderinformationfromaheaderbuffer.

publicvoidParseBuffer(

byte[]header

);

Parametersheader

Thetarentryheaderbuffertogetinformationfrom.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ParseBufferMethod

SharpZipCompressionLibrary

Parseanamefromaheaderbuffer.

publicstaticStringBuilderParseName(

byte[]header,

intoffset,

intlength

);

Parametersheader

Theheaderbufferfromwhichtoparse.

offsetTheoffsetintothebufferfromwhichtoparse.

lengthThenumberofheaderbytestoparse.

ReturnValueThenameparsed.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ParseNameMethod

SharpZipCompressionLibrary

Parseanoctalstringfromaheaderbuffer.

publicstaticlongParseOctal(

byte[]header,

intoffset,

intlength

);

Parametersheader

Theheaderbufferfromwhichtoparse.

offsetTheoffsetintothebufferfromwhichtoparse.

lengthThenumberofheaderbytestoparse.

ReturnValueThelongequivalentoftheoctalstring.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ParseOctalMethod

SharpZipCompressionLibrary

Resetvaluedefaultstoinitialvalues.

publicstaticvoidResetValueDefaults();

RemarksThedefaultvaluesareuserid=0,groupid=0,groupname="None",username=null.WhenthedefaultusernameisnullthevaluefromEnvironment.UserNameisused.Or"PocketPC"fortheCompactframework.Whenthedefaultgroupnameisnullthevalue"None"isused.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.ResetValueDefaultsMethod

SharpZipCompressionLibrary

SetdefaultsforvaluesusedwhenconstructingaTarHeaderinstance.

publicstaticvoidSetValueDefaults(

intuserId,

stringuserName,

intgroupId,

stringgroupName

);

ParametersuserId

ValuetoapplyasadefaultforuserId.

userNameValuetoapplyasadefaultforuserName.

groupIdValuetoapplyasadefaultforgroupId.

groupNameValuetoapplyasadefaultforgroupName.

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.SetValueDefaultsMethod

SharpZipCompressionLibrary

'Write'headerinformationtobufferprovided,updatingthechecksum.

publicvoidWriteHeader(

byte[]outbuf

);

Parametersoutbuf

outputbufferforheaderinformation

SeeAlsoTarHeaderClass|ICSharpCode.SharpZipLib.TarNamespace

TarHeader.WriteHeaderMethod

SharpZipCompressionLibrary

TheTarInputStreamreadsaUNIXtararchiveasanInputStream.methodsareprovidedtopositionateachsuccessiveentryinthearchive,andthereadeachentryasanormalinputstreamusingread().

Foralistofallmembersofthistype,seeTarInputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Tar.TarInputStream

publicclassTarInputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarInputStreamMembers|ICSharpCode.SharpZipLib.TarNamespace

TarInputStreamClass

SharpZipCompressionLibrary

TarInputStreamoverview

PublicInstanceConstructorsTarInputStream Overloaded.Initializesanew

instanceoftheTarInputStreamclass.

PublicInstancePropertiesAvailable Gettheavailabledatathatcanbereadfrom

thecurrententryinthearchive.Thisdoesnotindicatehowmuchdataisleftintheentirearchive,onlyinthecurrententry.Thisvalueisdeterminedfromtheentry'ssizeheaderfieldandtheamountofdataalreadyreadfromthecurrententry.

CanRead Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek GetsavalueindicatingwhetherthecurrentstreamsupportsseekingThispropertyalwaysreturnsfalse.

CanWrite Getsavalueindicatingifthestreamsupportswriting.Thispropertyalwaysreturnsfalse.

IsMarkSupportedSincewedonotsupportmarkingjustyet,wereturnfalse.

Length Thelengthinbytesofthestream

Position Getsorsetsthepositionwithinthestream.SettingthePositionisnotsupportedandthrowsaNotSupportedExceptionNotSupportedException

PublicInstanceMethodsBeginRead(inheritedfrom Beginsanasynchronousread

TarInputStreamMembers

Stream) operation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Closesthisstream.CallstheTarBuffer'sclose()method.TheunderlyingstreamisclosedbytheTarBuffer.

CopyEntryContents Copiesthecontentsofthecurrenttararchiveentrydirectlyintoanoutputstream.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetNextEntry Getthenextentryinthistararchive.Thiswillskipoveranyremainingdatainthecurrent

entry,ifthereisone,andplacetheinputstreamattheheaderofthenextentry,andreadtheheaderandinstantiateanewTarEntryfromtheheaderbytesandreturnthatentry.Iftherearenomoreentriesinthearchive,nullwillbereturnedtoindicatethattheendofthearchivehasbeenreached.

GetRecordSize Gettherecordsizebeingusedbythisstream'sTarBuffer.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Mark Sincewedonotsupportmarkingjustyet,wedonothing.

Read Readsbytesfromthecurrenttararchiveentry.Thismethodisawareoftheboundariesofthecurrententryinthearchiveandwilldealwiththemappropriately

ReadByte Readsabytefromthecurrenttararchiveentry.Thismethodsimplycallsread(byte[],int,int).

Reset Sincewedonotsupportmarkingjustyet,wedonothing.

Seek Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

SetEntryFactory Settheentryfactoryforthis

instance.

SetLength SetsthelengthofthestreamThisoperationisnotsupportedandwillthrowaNotSupportedException

Skip Skipbytesintheinputbuffer.Thisskipsbytesinthecurrententry'sdata,nottheentirearchive,andwillstopattheendofthecurrententry'sdataifthenumbertoskipextendsbeyondthatpoint.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

WriteByte Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

ProtectedInstanceFieldsbuffer Workingbuffer

currEntry Currententrybeingread

eFactory FactoryusedtocreateTarEntryordescendantclassinstance

entryOffset Numberofbytesreadforthisentrysofar

entrySize Sizeofthisentryasrecordedinheader

hasHitEOF Flagsetwhenlastblockhasbeenread

readBuf Bufferusedwithcallsto

Read()

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

ConstructaTarInputStreamwithdefaultblockfactor

OverloadListConstructaTarInputStreamwithdefaultblockfactor

publicTarInputStream(Stream);

ConstructaTarInputStreamwithuserspecifiedblockfactor

publicTarInputStream(Stream,int);

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStreamConstructor

SharpZipCompressionLibrary

ConstructaTarInputStreamwithdefaultblockfactor

publicTarInputStream(

StreaminputStream

);

ParametersinputStream

streamtosourcedatafrom

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace|TarInputStreamConstructorOverloadList

TarInputStreamConstructor(Stream)

SharpZipCompressionLibrary

ConstructaTarInputStreamwithuserspecifiedblockfactor

publicTarInputStream(

StreaminputStream,

intblockFactor

);

ParametersinputStream

streamtosourcedatafrom

blockFactorblockfactortoapplytoarchive

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace|TarInputStreamConstructorOverloadList

TarInputStreamConstructor(Stream,Int32)

SharpZipCompressionLibrary

ThefieldsoftheTarInputStreamclassarelistedbelow.ForacompletelistofTarInputStreamclassmembers,seetheTarInputStreamMemberstopic.

ProtectedInstanceFieldsbuffer Workingbuffer

currEntry Currententrybeingread

eFactory FactoryusedtocreateTarEntryordescendantclassinstance

entryOffset Numberofbytesreadforthisentrysofar

entrySize Sizeofthisentryasrecordedinheader

hasHitEOF Flagsetwhenlastblockhasbeenread

readBuf Bufferusedwithcallsto

Read()

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStreamFields

SharpZipCompressionLibrary

Workingbuffer

protectedTarBufferbuffer;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.bufferField

SharpZipCompressionLibrary

Currententrybeingread

protectedTarEntrycurrEntry;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.currEntryField

SharpZipCompressionLibrary

FactoryusedtocreateTarEntryordescendantclassinstance

protectedIEntryFactoryeFactory;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.eFactoryField

SharpZipCompressionLibrary

Numberofbytesreadforthisentrysofar

protectedlongentryOffset;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.entryOffsetField

SharpZipCompressionLibrary

Sizeofthisentryasrecordedinheader

protectedlongentrySize;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.entrySizeField

SharpZipCompressionLibrary

Flagsetwhenlastblockhasbeenread

protectedboolhasHitEOF;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.hasHitEOFField

SharpZipCompressionLibrary

Bufferusedwithcallsto

Read()

protectedbyte[]readBuf;

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.readBufField

SharpZipCompressionLibrary

ThepropertiesoftheTarInputStreamclassarelistedbelow.ForacompletelistofTarInputStreamclassmembers,seetheTarInputStreamMemberstopic.

PublicInstancePropertiesAvailable Gettheavailabledatathatcanbereadfrom

thecurrententryinthearchive.Thisdoesnotindicatehowmuchdataisleftintheentirearchive,onlyinthecurrententry.Thisvalueisdeterminedfromtheentry'ssizeheaderfieldandtheamountofdataalreadyreadfromthecurrententry.

CanRead Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek GetsavalueindicatingwhetherthecurrentstreamsupportsseekingThispropertyalwaysreturnsfalse.

CanWrite Getsavalueindicatingifthestreamsupportswriting.Thispropertyalwaysreturnsfalse.

IsMarkSupportedSincewedonotsupportmarkingjustyet,wereturnfalse.

Length Thelengthinbytesofthestream

Position Getsorsetsthepositionwithinthestream.SettingthePositionisnotsupportedandthrowsaNotSupportedExceptionNotSupportedException

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStreamProperties

SharpZipCompressionLibrary

Gettheavailabledatathatcanbereadfromthecurrententryinthearchive.Thisdoesnotindicatehowmuchdataisleftintheentirearchive,onlyinthecurrententry.Thisvalueisdeterminedfromtheentry'ssizeheaderfieldandtheamountofdataalreadyreadfromthecurrententry.

publiclongAvailable{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.AvailableProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

publicoverrideboolCanRead{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.CanReadProperty

SharpZipCompressionLibrary

GetsavalueindicatingwhetherthecurrentstreamsupportsseekingThispropertyalwaysreturnsfalse.

publicoverrideboolCanSeek{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.CanSeekProperty

SharpZipCompressionLibrary

Getsavalueindicatingifthestreamsupportswriting.Thispropertyalwaysreturnsfalse.

publicoverrideboolCanWrite{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.CanWriteProperty

SharpZipCompressionLibrary

Sincewedonotsupportmarkingjustyet,wereturnfalse.

publicboolIsMarkSupported{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IsMarkSupportedProperty

SharpZipCompressionLibrary

Thelengthinbytesofthestream

publicoverridelongLength{get;}

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.LengthProperty

SharpZipCompressionLibrary

Getsorsetsthepositionwithinthestream.SettingthePositionisnotsupportedandthrowsaNotSupportedExceptionNotSupportedException

publicoverridelongPosition{get;set;}

ExceptionsExceptionType ConditionNotSupportedException Anyattempttosetposition

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheTarInputStreamclassarelistedbelow.ForacompletelistofTarInputStreamclassmembers,seetheTarInputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close Closesthisstream.CallstheTarBuffer'sclose()method.TheunderlyingstreamisclosedbytheTarBuffer.

CopyEntryContents Copiesthecontentsofthecurrenttararchiveentrydirectlyintoanoutputstream.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddata

TarInputStreamMethods

structureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetNextEntry Getthenextentryinthistararchive.Thiswillskipoveranyremainingdatainthecurrententry,ifthereisone,andplacetheinputstreamattheheaderofthenextentry,andreadtheheaderandinstantiateanewTarEntryfromtheheaderbytesandreturnthatentry.Iftherearenomoreentriesinthearchive,nullwillbereturnedtoindicatethattheendofthearchivehasbeenreached.

GetRecordSize Gettherecordsizebeingusedbythisstream'sTarBuffer.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Mark Sincewedonotsupportmarkingjustyet,wedonothing.

Read Readsbytesfromthecurrenttararchiveentry.Thismethodisawareoftheboundariesofthecurrententryinthearchiveandwilldealwiththemappropriately

ReadByte Readsabytefromthecurrenttararchiveentry.Thismethodsimplycallsread(byte[],int,int).

Reset Sincewedonotsupportmarkingjustyet,wedonothing.

Seek Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

SetEntryFactory Settheentryfactoryforthisinstance.

SetLength SetsthelengthofthestreamThisoperationisnotsupportedandwillthrowaNotSupportedException

Skip Skipbytesintheinputbuffer.Thisskipsbytesinthecurrententry'sdata,nottheentirearchive,andwillstopattheendofthecurrententry'sdataifthenumbertoskipextendsbeyondthatpoint.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

WriteByte Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

Closesthisstream.CallstheTarBuffer'sclose()method.TheunderlyingstreamisclosedbytheTarBuffer.

publicoverridevoidClose();

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.CloseMethod

SharpZipCompressionLibrary

Copiesthecontentsofthecurrenttararchiveentrydirectlyintoanoutputstream.

publicvoidCopyEntryContents(

StreamoutputStream

);

ParametersoutputStream

TheOutputStreamintowhichtowritetheentry'sdata.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.CopyEntryContentsMethod

SharpZipCompressionLibrary

FlushesthebaseInputStream

publicoverridevoidFlush();

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.FlushMethod

SharpZipCompressionLibrary

Getthenextentryinthistararchive.Thiswillskipoveranyremainingdatainthecurrententry,ifthereisone,andplacetheinputstreamattheheaderofthenextentry,andreadtheheaderandinstantiateanewTarEntryfromtheheaderbytesandreturnthatentry.Iftherearenomoreentriesinthearchive,nullwillbereturnedtoindicatethattheendofthearchivehasbeenreached.

publicTarEntryGetNextEntry();

ReturnValueThenextTarEntryinthearchive,ornull.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.GetNextEntryMethod

SharpZipCompressionLibrary

Gettherecordsizebeingusedbythisstream'sTarBuffer.

publicintGetRecordSize();

ReturnValueTarBufferrecordsize.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.GetRecordSizeMethod

SharpZipCompressionLibrary

Sincewedonotsupportmarkingjustyet,wedonothing.

publicvoidMark(

intmarkLimit

);

ParametersmarkLimit

Thelimittomark.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.MarkMethod

SharpZipCompressionLibrary

Readsbytesfromthecurrenttararchiveentry.Thismethodisawareoftheboundariesofthecurrententryinthearchiveandwilldealwiththemappropriately

publicoverrideintRead(

byte[]outputBuffer,

intoffset,

intcount

);

ParametersoutputBuffer

Thebufferintowhichtoplacebytesread.

offsetTheoffsetatwhichtoplacebytesread.

countThenumberofbytestoread.

ReturnValueThenumberofbytesread,or0atendofstream/EOF.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.ReadMethod

SharpZipCompressionLibrary

Readsabytefromthecurrenttararchiveentry.Thismethodsimplycallsread(byte[],int,int).

publicoverrideintReadByte();

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.ReadByteMethod

SharpZipCompressionLibrary

Sincewedonotsupportmarkingjustyet,wedonothing.

publicvoidReset();

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.ResetMethod

SharpZipCompressionLibrary

Setthestreamsposition.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.SeekMethod

SharpZipCompressionLibrary

Settheentryfactoryforthisinstance.

publicvoidSetEntryFactory(

IEntryFactoryfactory

);

Parametersfactory

Thefactoryforcreatingnewentries

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.SetEntryFactoryMethod

SharpZipCompressionLibrary

SetsthelengthofthestreamThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridevoidSetLength(

longval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.SetLengthMethod

SharpZipCompressionLibrary

Skipbytesintheinputbuffer.Thisskipsbytesinthecurrententry'sdata,nottheentirearchive,andwillstopattheendofthecurrententry'sdataifthenumbertoskipextendsbeyondthatpoint.

publicvoidSkip(

longnumToSkip

);

ParametersnumToSkip

Thenumberofbytestoskip.

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.SkipMethod

SharpZipCompressionLibrary

Writesablockofbytestothisstreamusingdatafromabuffer.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridevoidWrite(

byte[]array,

intoffset,

intcount

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.WriteMethod

SharpZipCompressionLibrary

Writesabytetothecurrentpositioninthefilestream.ThisoperationisnotsupportedandwillthrowaNotSupportedException

publicoverridevoidWriteByte(

byteval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoTarInputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.WriteByteMethod

SharpZipCompressionLibrary

StandardentryfactoryclasscreatinginstancesoftheclassTarEntry

Foralistofallmembersofthistype,seeTarInputStream.EntryFactoryAdapterMembers.

System.ObjectICSharpCode.SharpZipLib.Tar.TarInputStream.EntryFactoryAdapter

publicclassTarInputStream.EntryFactoryAdapter

:IEntryFactory

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarInputStream.EntryFactoryAdapterMembers|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.EntryFactoryAdapterClass

SharpZipCompressionLibrary

TarInputStream.EntryFactoryAdapteroverview

PublicInstanceConstructors

TarInputStream.EntryFactoryAdapterConstructor

InitializesanewinstanceoftheTarInputStream.EntryFactoryAdapterclass.

PublicInstanceMethodsCreateEntry Overloaded.Createandentry

basedondetailsinheaderBuf

CreateEntryFromFile CreateatarentrywithdetailsobtainedfromfileName

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

TarInputStream.EntryFactoryAdapterMembers

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheTarInputStream.EntryFactoryAdapterclass.

publicTarInputStream.EntryFactoryAdapter();

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.EntryFactoryAdapterConstructor

SharpZipCompressionLibrary

ThemethodsoftheTarInputStream.EntryFactoryAdapterclassarelistedbelow.ForacompletelistofTarInputStream.EntryFactoryAdapterclassmembers,seetheTarInputStream.EntryFactoryAdapterMemberstopic.

PublicInstanceMethodsCreateEntry Overloaded.Createandentry

basedondetailsinheaderBuf

CreateEntryFromFile CreateatarentrywithdetailsobtainedfromfileName

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlso

TarInputStream.EntryFactoryAdapterMethods

TarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

CreateandentrybasedondetailsinheaderBuf

OverloadListCreateandentrybasedondetailsinheaderBuf

publicTarEntryCreateEntry(byte[]);

CreateaTarEntrybasedonnamed

publicTarEntryCreateEntry(string);

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.EntryFactoryAdapter.CreateEntryMethod

SharpZipCompressionLibrary

CreateandentrybasedondetailsinheaderBuf

publicTarEntryCreateEntry(

byte[]headerBuf

);

ImplementsIEntryFactory.CreateEntry

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace|TarInputStream.EntryFactoryAdapter.CreateEntryOverloadList

TarInputStream.EntryFactoryAdapter.CreateEntryMethod(Byte[])

SharpZipCompressionLibrary

CreateaTarEntrybasedonnamed

publicTarEntryCreateEntry(

stringname

);

ImplementsIEntryFactory.CreateEntry

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace|TarInputStream.EntryFactoryAdapter.CreateEntryOverloadList

TarInputStream.EntryFactoryAdapter.CreateEntryMethod(String)

SharpZipCompressionLibrary

CreateatarentrywithdetailsobtainedfromfileName

publicTarEntryCreateEntryFromFile(

stringfileName

);

ImplementsIEntryFactory.CreateEntryFromFile

SeeAlsoTarInputStream.EntryFactoryAdapterClass|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.EntryFactoryAdapter.CreateEntryFromFileMethod

SharpZipCompressionLibrary

Thisinterfaceisprovided,alongwiththemethodsetEntryFactory(),toallowtheprogrammertohavetheirownTarEntrysubclassinstantiatedfortheentriesreturnfromgetNextEntry().

Foralistofallmembersofthistype,seeTarInputStream.IEntryFactoryMembers.

publicinterfaceTarInputStream.IEntryFactory

TypesthatimplementTarInputStream.IEntryFactoryType DescriptionTarInputStream.EntryFactoryAdapter Standardentryfactoryclass

creatinginstancesoftheclassTarEntry

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarInputStream.IEntryFactoryMembers|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IEntryFactoryInterface

SharpZipCompressionLibrary

TarInputStream.IEntryFactoryoverview

PublicInstanceMethodsCreateEntry Overloaded.Createatarentry

basedontheheaderinformationpassed

CreateEntryFromFile Createaninstancebasedonanactualfile

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IEntryFactoryMembers

SharpZipCompressionLibrary

ThemethodsoftheTarInputStream.IEntryFactoryinterfacearelistedbelow.ForacompletelistofTarInputStream.IEntryFactoryinterfacemembers,seetheTarInputStream.IEntryFactoryMemberstopic.

PublicInstanceMethodsCreateEntry Overloaded.Createatarentry

basedontheheaderinformationpassed

CreateEntryFromFile Createaninstancebasedonanactualfile

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IEntryFactoryMethods

SharpZipCompressionLibrary

Createatarentrybasedontheheaderinformationpassed

OverloadListCreateatarentrybasedontheheaderinformationpassed

TarEntryCreateEntry(byte[]);

Createanentrybasedonnamealone

TarEntryCreateEntry(string);

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IEntryFactory.CreateEntryMethod

SharpZipCompressionLibrary

Createatarentrybasedontheheaderinformationpassed

TarEntryCreateEntry(

byte[]headerBuf

);

ParametersheaderBuf

Buffercontainingheaderinformationtobaseentryon

ReturnValueCreatedTarEntryordescendantclass

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace|TarInputStream.IEntryFactory.CreateEntryOverloadList

TarInputStream.IEntryFactory.CreateEntryMethod(Byte[])

SharpZipCompressionLibrary

Createanentrybasedonnamealone

TarEntryCreateEntry(

stringname

);

Parametersname

NameofthenewEntryPointNotFoundExceptiontocreate

ReturnValuecreatedTarEntryordescendantclass

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace|TarInputStream.IEntryFactory.CreateEntryOverloadList

TarInputStream.IEntryFactory.CreateEntryMethod(String)

SharpZipCompressionLibrary

Createaninstancebasedonanactualfile

TarEntryCreateEntryFromFile(

stringfileName

);

ParametersfileName

Nameoffiletorepresentintheentry

ReturnValueCreatedTarEntryordescendantclass

SeeAlsoTarInputStream.IEntryFactoryInterface|ICSharpCode.SharpZipLib.TarNamespace

TarInputStream.IEntryFactory.CreateEntryFromFileMethod

SharpZipCompressionLibrary

TheTarOutputStreamwritesaUNIXtararchiveasanOutputStream.Methodsareprovidedtoputentries,andthenwritetheircontentsbywritingtothisstreamusingwrite().

Foralistofallmembersofthistype,seeTarOutputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Tar.TarOutputStream

publicclassTarOutputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.TarAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoTarOutputStreamMembers|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStreamClass

SharpZipCompressionLibrary

TarOutputStreamoverview

PublicInstanceConstructorsTarOutputStream Overloaded.Initializesanew

instanceoftheTarOutputStreamclass.

PublicInstancePropertiesCanRead trueifthestreamsupports

reading;otherwise,false.

CanSeek trueifthestreamsupportsseeking;otherwise,false.

CanWrite trueifstreamsupportswriting;otherwise,false.

Length lengthofstreaminbytes

Position getsorsetsthepositionwithinthecurrentstream.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close EndstheTARarchiveandclosestheunderlyingOutputStream.Thismeansthatfinish()iscalledfollowedbycallingtheTarBuffer'sclose().

CloseEntry Closeanentry.ThismethodMUSTbecalledforallfileentriesthatcontaindata.Thereasonisthatwemustbuffer

TarOutputStreamMembers

datawrittentothestreaminordertosatisfythebuffer'sblockbasedwrites.Thus,theremaybedatafragmentsstillbeingassembledthatmustbewrittentotheoutputstreambeforethisentryisclosedandthenextentrywritten.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish EndstheTARarchivewithoutclosingtheunderlyingOutputStream.TheresultisthattheEOFrecordofnullsiswritten.

Flush Allbuffereddataiswrittentodestination

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetRecordSize Gettherecordsizebeingusedbythisstream'sTarBuffer.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

PutNextEntry Putanentryontheoutputstream.Thiswritestheentry'sheaderandpositionstheoutputstreamforwritingthecontentsoftheentry.Oncethismethodiscalled,thestreamisreadyforcallstowrite()towritetheentry'scontents.Oncethecontentsarewritten,closeEntry()MUSTbecalledtoensurethatallbuffereddataiscompletelywrittentotheoutputstream.

Read readbytesfromthecurrentstreamandadvancethepositionwithinthestreambythenumberofbytesread.

ReadByte Readabytefromthestreamandadvancethepositionwithinthestreambyonebyteorreturns-1ifattheendofthestream.

Seek setthepositionwithinthecurrentstream

SetLength setthelengthofthecurrentstream

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesbytestothecurrenttararchiveentry.Thismethodisawareofthecurrententryandwillthrowanexceptionifyouattempttowritebytespastthelengthspecifiedforthecurrententry.Themethodisalso(painfully)awareoftherecordbufferingrequiredbyTarBuffer,andmanagesbuffersthatarenotamultipleofrecordsizeinlength,includingassemblingrecordsfromsmallbuffers.

WriteByte Writesabytetothecurrenttararchiveentry.ThismethodsimplycallsWrite(byte[],int,int).

ProtectedInstanceFieldsassemBuf 'Assembly'bufferusedto

assmbledatabeforewriting

assemLen current'Assembly'bufferlength

blockBuf singleblockworkingbuffer

buffer TarBufferusedtoprovidecorrectblockingfactor

currBytes byteswrittenforthisentrysofar

currSize Sizeforthecurrententry

debug flagindicatingdebuggingcodeshouldbeactivatedornot

outputStream thedestinationstreamforthearchivecontents

ProtectedInstanceMethodsCreateWaitHandle(inherited AllocatesaWaitHandleobject.

fromStream)

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

ConstructTarOutputStreamusingdefaultblockfactor

OverloadListConstructTarOutputStreamusingdefaultblockfactor

publicTarOutputStream(Stream);

ConstructTarOutputStreamwithuserspecifiedblockfactor

publicTarOutputStream(Stream,int);

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStreamConstructor

SharpZipCompressionLibrary

ConstructTarOutputStreamusingdefaultblockfactor

publicTarOutputStream(

StreamoutputStream

);

ParametersoutputStream

streamtowriteto

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace|TarOutputStreamConstructorOverloadList

TarOutputStreamConstructor(Stream)

SharpZipCompressionLibrary

ConstructTarOutputStreamwithuserspecifiedblockfactor

publicTarOutputStream(

StreamoutputStream,

intblockFactor

);

ParametersoutputStream

streamtowriteto

blockFactorblockingfactor

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace|TarOutputStreamConstructorOverloadList

TarOutputStreamConstructor(Stream,Int32)

SharpZipCompressionLibrary

ThefieldsoftheTarOutputStreamclassarelistedbelow.ForacompletelistofTarOutputStreamclassmembers,seetheTarOutputStreamMemberstopic.

ProtectedInstanceFieldsassemBuf 'Assembly'bufferusedto

assmbledatabeforewriting

assemLen current'Assembly'bufferlength

blockBuf singleblockworkingbuffer

buffer TarBufferusedtoprovidecorrectblockingfactor

currBytes byteswrittenforthisentrysofar

currSize Sizeforthecurrententry

debug flagindicatingdebuggingcodeshouldbeactivatedornot

outputStream thedestinationstreamforthearchivecontents

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStreamFields

SharpZipCompressionLibrary

'Assembly'bufferusedtoassmbledatabeforewriting

protectedbyte[]assemBuf;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.assemBufField

SharpZipCompressionLibrary

current'Assembly'bufferlength

protectedintassemLen;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.assemLenField

SharpZipCompressionLibrary

singleblockworkingbuffer

protectedbyte[]blockBuf;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.blockBufField

SharpZipCompressionLibrary

TarBufferusedtoprovidecorrectblockingfactor

protectedTarBufferbuffer;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.bufferField

SharpZipCompressionLibrary

byteswrittenforthisentrysofar

protectedlongcurrBytes;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.currBytesField

SharpZipCompressionLibrary

Sizeforthecurrententry

protectedlongcurrSize;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.currSizeField

SharpZipCompressionLibrary

flagindicatingdebuggingcodeshouldbeactivatedornot

protectedbooldebug;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.debugField

SharpZipCompressionLibrary

thedestinationstreamforthearchivecontents

protectedStreamoutputStream;

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.outputStreamField

SharpZipCompressionLibrary

ThepropertiesoftheTarOutputStreamclassarelistedbelow.ForacompletelistofTarOutputStreamclassmembers,seetheTarOutputStreamMemberstopic.

PublicInstancePropertiesCanRead trueifthestreamsupports

reading;otherwise,false.

CanSeek trueifthestreamsupportsseeking;otherwise,false.

CanWrite trueifstreamsupportswriting;otherwise,false.

Length lengthofstreaminbytes

Position getsorsetsthepositionwithinthecurrentstream.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStreamProperties

SharpZipCompressionLibrary

trueifthestreamsupportsreading;otherwise,false.

publicoverrideboolCanRead{get;}

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.CanReadProperty

SharpZipCompressionLibrary

trueifthestreamsupportsseeking;otherwise,false.

publicoverrideboolCanSeek{get;}

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.CanSeekProperty

SharpZipCompressionLibrary

trueifstreamsupportswriting;otherwise,false.

publicoverrideboolCanWrite{get;}

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.CanWriteProperty

SharpZipCompressionLibrary

lengthofstreaminbytes

publicoverridelongLength{get;}

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.LengthProperty

SharpZipCompressionLibrary

getsorsetsthepositionwithinthecurrentstream.

publicoverridelongPosition{get;set;}

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheTarOutputStreamclassarelistedbelow.ForacompletelistofTarOutputStreamclassmembers,seetheTarOutputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromStream)

Beginsanasynchronouswriteoperation.

Close EndstheTARarchiveandclosestheunderlyingOutputStream.Thismeansthatfinish()iscalledfollowedbycallingtheTarBuffer'sclose().

CloseEntry Closeanentry.ThismethodMUSTbecalledforallfileentriesthatcontaindata.Thereasonisthatwemustbufferdatawrittentothestreaminordertosatisfythebuffer'sblockbasedwrites.Thus,theremaybedatafragmentsstillbeingassembledthatmustbewrittentotheoutputstreambeforethisentryisclosedandthenextentrywritten.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

TarOutputStreamMethods

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish EndstheTARarchivewithoutclosingtheunderlyingOutputStream.TheresultisthattheEOFrecordofnullsiswritten.

Flush Allbuffereddataiswrittentodestination

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetRecordSize Gettherecordsizebeingusedbythisstream'sTarBuffer.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

PutNextEntry Putanentryontheoutputstream.Thiswritestheentry'sheaderandpositionstheoutputstreamforwritingthecontentsoftheentry.Oncethismethodiscalled,thestreamisreadyforcallstowrite()towritetheentry'scontents.Oncethe

contentsarewritten,closeEntry()MUSTbecalledtoensurethatallbuffereddataiscompletelywrittentotheoutputstream.

Read readbytesfromthecurrentstreamandadvancethepositionwithinthestreambythenumberofbytesread.

ReadByte Readabytefromthestreamandadvancethepositionwithinthestreambyonebyteorreturns-1ifattheendofthestream.

Seek setthepositionwithinthecurrentstream

SetLength setthelengthofthecurrentstream

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesbytestothecurrenttararchiveentry.Thismethodisawareofthecurrententryandwillthrowanexceptionifyouattempttowritebytespastthelengthspecifiedforthecurrententry.Themethodisalso(painfully)awareoftherecordbufferingrequiredbyTarBuffer,andmanagesbuffersthatarenotamultipleofrecordsizeinlength,includingassemblingrecordsfromsmallbuffers.

WriteByte Writesabytetothecurrenttararchiveentry.Thismethod

simplycallsWrite(byte[],int,int).

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

SharpZipCompressionLibrary

EndstheTARarchiveandclosestheunderlyingOutputStream.Thismeansthatfinish()iscalledfollowedbycallingtheTarBuffer'sclose().

publicoverridevoidClose();

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.CloseMethod

SharpZipCompressionLibrary

Closeanentry.ThismethodMUSTbecalledforallfileentriesthatcontaindata.Thereasonisthatwemustbufferdatawrittentothestreaminordertosatisfythebuffer'sblockbasedwrites.Thus,theremaybedatafragmentsstillbeingassembledthatmustbewrittentotheoutputstreambeforethisentryisclosedandthenextentrywritten.

publicvoidCloseEntry();

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.CloseEntryMethod

SharpZipCompressionLibrary

EndstheTARarchivewithoutclosingtheunderlyingOutputStream.TheresultisthattheEOFrecordofnullsiswritten.

publicvoidFinish();

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.FinishMethod

SharpZipCompressionLibrary

Allbuffereddataiswrittentodestination

publicoverridevoidFlush();

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.FlushMethod

SharpZipCompressionLibrary

Gettherecordsizebeingusedbythisstream'sTarBuffer.

publicintGetRecordSize();

ReturnValueTheTarBufferrecordsize.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.GetRecordSizeMethod

SharpZipCompressionLibrary

Putanentryontheoutputstream.Thiswritestheentry'sheaderandpositionstheoutputstreamforwritingthecontentsoftheentry.Oncethismethodiscalled,thestreamisreadyforcallstowrite()towritetheentry'scontents.Oncethecontentsarewritten,closeEntry()MUSTbecalledtoensurethatallbuffereddataiscompletelywrittentotheoutputstream.

publicvoidPutNextEntry(

TarEntryentry

);

Parametersentry

TheTarEntrytobewrittentothearchive.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.PutNextEntryMethod

SharpZipCompressionLibrary

readbytesfromthecurrentstreamandadvancethepositionwithinthestreambythenumberofbytesread.

publicoverrideintRead(

byte[]b,

intoff,

intlen

);

ReturnValueThetotalnumberofbytesread,orzeroifattheendofthestream

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.ReadMethod

SharpZipCompressionLibrary

Readabytefromthestreamandadvancethepositionwithinthestreambyonebyteorreturns-1ifattheendofthestream.

publicoverrideintReadByte();

ReturnValueThebytevalueor-1ifatendofstream

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.ReadByteMethod

SharpZipCompressionLibrary

setthepositionwithinthecurrentstream

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.SeekMethod

SharpZipCompressionLibrary

setthelengthofthecurrentstream

publicoverridevoidSetLength(

longval

);

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.SetLengthMethod

SharpZipCompressionLibrary

Writesbytestothecurrenttararchiveentry.Thismethodisawareofthecurrententryandwillthrowanexceptionifyouattempttowritebytespastthelengthspecifiedforthecurrententry.Themethodisalso(painfully)awareoftherecordbufferingrequiredbyTarBuffer,andmanagesbuffersthatarenotamultipleofrecordsizeinlength,includingassemblingrecordsfromsmallbuffers.

publicoverridevoidWrite(

byte[]wBuf,

intwOffset,

intnumToWrite

);

ParameterswBuf

Thebuffertowritetothearchive.

wOffsetTheoffsetinthebufferfromwhichtogetbytes.

numToWriteThenumberofbytestowrite.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.WriteMethod

SharpZipCompressionLibrary

Writesabytetothecurrenttararchiveentry.ThismethodsimplycallsWrite(byte[],int,int).

publicoverridevoidWriteByte(

byteb

);

Parametersb

Thebytetobewritten.

SeeAlsoTarOutputStreamClass|ICSharpCode.SharpZipLib.TarNamespace

TarOutputStream.WriteByteMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionFastZip FastZipprovidesfacilitiesfor

creatingandextractingzipfiles.Onlyrelativepathsaresupported.

FastZipEvents FastZipEventssupportsalleventsapplicabletoFastZipoperations.

KeysRequiredEventArgs ArgumentsusedwithKeysRequiredEvent

ZipConstants ThisclasscontainsconstantsusedforZipformatfiles

ZipEntry Thisclassrepresentsanentryinaziparchive.ThiscanbeafileoradirectoryZipFileandZipInputStreamwillgiveyouinstancesofthisclassasinformationaboutthemembersinanarchive.ZipOutputStreamusesaninstanceofthisclasswhencreatinganentryinaZipfile.

Authoroftheoriginaljavaversion:JochenHoenicke

ZipException RepresentserrorsspecifictoZipfilehandling

ZipFile ThisclassrepresentsaZiparchive.Youcanaskforthecontainedentries,orgetan

ICSharpCode.SharpZipLib.ZipNamespace

inputstreamforafileentry.Theentryisautomaticallydecompressed.Thisclassisthreadsafe:Youcanopeninputstreamsforarbitraryentriesindifferentthreads.

Authoroftheoriginaljavaversion:JochenHoenicke

ZipInputStream ThisisanInflaterInputStreamthatreadsthefilesbaseInputStreamanziparchiveoneafteranother.Ithasaspecialmethodtogetthezipentryofthenextfile.Thezipentrycontainsinformationaboutthefilenamesize,compressedsize,Crc,etc.ItincludessupportforStoredandDeflatedentries.

Authoroftheoriginaljavaversion:JochenHoenicke

ZipNameTransform ZipNameTransformtransformsnameaspertheZipfileconvention.

ZipOutputStream ThisisaDeflaterOutputStreamthatwritesthefilesintoaziparchiveoneafteranother.Ithasaspecialmethodtostartanewzipentry.Thezipentriescontainsinformationaboutthefilenamesize,compressedsize,CRC,etc.ItincludessupportforStoredandDeflatedentries.Thisclassisnotthreadsafe.

Authoroftheoriginaljavaversion:JochenHoenicke

DelegatesDelegate DescriptionFastZip.ConfirmOverwriteDelegate Delegatecalledwhen

confirmingoverwritingoffiles.

ZipFile.KeysRequiredEventHandler Delegateforhandlingkeys/passwordsettingduringcompresion/decompression.

EnumerationsEnumeration DescriptionCompressionMethod Thekindofcompressionused

foranentryinanarchive

FastZip.Overwrite Definesthedesiredhandlingwhenoverwritingfiles.

SharpZipCompressionLibrary

Thekindofcompressionusedforanentryinanarchive

publicenumCompressionMethod

MembersMemberName DescriptionStored Adirectcopyofthefilecontents

isheldinthearchive

Deflated CommonZipcompressionmethodusingaslidingdictionaryofupto32KBandsecondarycompressionfromHuffman/Shannon-Fanotrees

Deflate64 Anextensiontodeflatewitha64KBwindow.Notsupportedby#Zip

BZip2 Notsupportedby#Zip

WinZipAES WinZipspecialforAESencryption,Notsupportedby#Zip

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.ZipNamespace

CompressionMethodEnumeration

SharpZipCompressionLibrary

FastZipprovidesfacilitiesforcreatingandextractingzipfiles.Onlyrelativepathsaresupported.

Foralistofallmembersofthistype,seeFastZipMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.FastZip

publicclassFastZip

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoFastZipMembers|ICSharpCode.SharpZipLib.ZipNamespace

FastZipClass

SharpZipCompressionLibrary

FastZipoverview

PublicInstanceConstructorsFastZip Overloaded.Initializesanew

instanceoftheFastZipclass.

PublicInstancePropertiesCreateEmptyDirectories Get/setavalueindicating

wetheremptydirectoriesshouldbecreated.

NameTransform GetorsettheactivewhencreatingZipfiles.

PublicInstanceMethodsCreateZip Overloaded.Createazipfile.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

ExtractZip Overloaded.Extractthecontentsofazipfile.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom AllowsanObjecttoattemptto

FastZipMembers

Object) freeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitializeadefaultinstanceofFastZip.

OverloadListInitializeadefaultinstanceofFastZip.

publicFastZip();

InitialiseanewinstanceofFastZip

publicFastZip(FastZipEvents);

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipConstructor

SharpZipCompressionLibrary

InitializeadefaultinstanceofFastZip.

publicFastZip();

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZipConstructorOverloadList

FastZipConstructor()

SharpZipCompressionLibrary

InitialiseanewinstanceofFastZip

publicFastZip(

FastZipEventsevents

);

Parametersevents

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZipConstructorOverloadList

FastZipConstructor(FastZipEvents)

SharpZipCompressionLibrary

ThepropertiesoftheFastZipclassarelistedbelow.ForacompletelistofFastZipclassmembers,seetheFastZipMemberstopic.

PublicInstancePropertiesCreateEmptyDirectories Get/setavalueindicating

wetheremptydirectoriesshouldbecreated.

NameTransform GetorsettheactivewhencreatingZipfiles.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipProperties

SharpZipCompressionLibrary

Get/setavalueindicatingwetheremptydirectoriesshouldbecreated.

publicboolCreateEmptyDirectories{get;set;}

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZip.CreateEmptyDirectoriesProperty

SharpZipCompressionLibrary

GetorsettheactivewhencreatingZipfiles.

publicZipNameTransformNameTransform{get;set;}

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZip.NameTransformProperty

SharpZipCompressionLibrary

ThemethodsoftheFastZipclassarelistedbelow.ForacompletelistofFastZipclassmembers,seetheFastZipMemberstopic.

PublicInstanceMethodsCreateZip Overloaded.Createazipfile.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

ExtractZip Overloaded.Extractthecontentsofazipfile.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipMethods

SharpZipCompressionLibrary

Createazipfile/archive.

OverloadListCreateazipfile/archive.

publicvoidCreateZip(string,string,bool,string);

Createazipfile.

publicvoidCreateZip(string,string,bool,string,string);

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZip.CreateZipMethod

SharpZipCompressionLibrary

Createazipfile/archive.

publicvoidCreateZip(

stringzipFileName,

stringsourceDirectory,

boolrecurse,

stringfileFilter

);

ParameterszipFileName

Thenameofthezipfiletocreate.

sourceDirectoryThedirectorytoobtainfilesanddirectoriesfrom.

recurseTruetorecursedirectories,falsefornorecursion.

fileFilterThefilefiltertoapply.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZip.CreateZipOverloadList

FastZip.CreateZipMethod(String,String,Boolean,String)

SharpZipCompressionLibrary

Createazipfile.

publicvoidCreateZip(

stringzipFileName,

stringsourceDirectory,

boolrecurse,

stringfileFilter,

stringdirectoryFilter

);

ParameterszipFileName

Thenameofthezipfiletocreate.

sourceDirectoryThedirectorytosourcefilesfrom.

recurseTruetorecursedirectories,falsefornorecursion.

fileFilterThefilefiltertoapply.

directoryFilterThedirectoryfiltertoapply.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZip.CreateZipOverloadList

FastZip.CreateZipMethod(String,String,Boolean,String,String)

SharpZipCompressionLibrary

Exatractthecontentsofazipfile.

OverloadListExatractthecontentsofazipfile.

publicvoidExtractZip(string,string,Overwrite,ConfirmOverwriteDelegate,string,string);

Extractthecontentsofazipfile.

publicvoidExtractZip(string,string,string);

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZip.ExtractZipMethod

SharpZipCompressionLibrary

Exatractthecontentsofazipfile.

publicvoidExtractZip(

stringzipFileName,

stringtargetDirectory,

Overwriteoverwrite,

ConfirmOverwriteDelegateconfirmDelegate,

stringfileFilter,

stringdirectoryFilter

);

ParameterszipFileName

Thezipfiletoextractfrom.

targetDirectoryThedirectorytosaveextractedinformationin.

overwriteThestyleofoverwritingtoapply.

confirmDelegateAdelegatetoinvokewhenconfirmingoverwriting.

fileFilterAfiltertoapplytofiles.

directoryFilterAfiltertoapplytodirectories.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZip.ExtractZipOverloadList

FastZip.ExtractZipMethod(String,String,Overwrite,ConfirmOverwriteDelegate,String,String)

SharpZipCompressionLibrary

Extractthecontentsofazipfile.

publicvoidExtractZip(

stringzipFileName,

stringtargetDirectory,

stringfileFilter

);

ParameterszipFileName

Thezipfiletoextractfrom.

targetDirectoryThedirectorytosaveextractedinformationin.

fileFilterAfiltertoapplytofiles.

SeeAlsoFastZipClass|ICSharpCode.SharpZipLib.ZipNamespace|FastZip.ExtractZipOverloadList

FastZip.ExtractZipMethod(String,String,String)

SharpZipCompressionLibrary

Delegatecalledwhenconfirmingoverwritingoffiles.

publicdelegateboolFastZip.ConfirmOverwriteDelegate(

stringfileName

);

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.ZipNamespace

FastZip.ConfirmOverwriteDelegateDelegate

SharpZipCompressionLibrary

Definesthedesiredhandlingwhenoverwritingfiles.

publicenumFastZip.Overwrite

MembersMemberName DescriptionPrompt Prompttheusertoconfirm

overwriting

Never Neveroverwritefiles.

Always Alwaysoverwritefiles.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.ZipNamespace

FastZip.OverwriteEnumeration

SharpZipCompressionLibrary

FastZipEventssupportsalleventsapplicabletoFastZipoperations.

Foralistofallmembersofthistype,seeFastZipEventsMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.FastZipEvents

publicclassFastZipEvents

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoFastZipEventsMembers|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEventsClass

SharpZipCompressionLibrary

FastZipEventsoverview

PublicInstanceConstructorsFastZipEventsConstructor Initializesanewinstanceofthe

FastZipEventsclass.

PublicInstanceFieldsDirectoryFailure Delegatetoinvokewhen

processingdirectoryfailures.

FileFailure Delegatetoinvokewhenprocessingfilefailures.

ProcessDirectory Delegatetoinvokewhenprocessingdirectories.

ProcessFile Delegatetoinvokewhenprocessingfiles.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

OnDirectoryFailure Raisethedirectoryfailureevent.

OnFileFailure Raisesthefilefailureevent.

OnProcessDirectory RaisestheProcessDirectoryEvent.

OnProcessFile RaisestheProcessFileEvent.

FastZipEventsMembers

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheFastZipEventsclass.

publicFastZipEvents();

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEventsConstructor

SharpZipCompressionLibrary

ThefieldsoftheFastZipEventsclassarelistedbelow.ForacompletelistofFastZipEventsclassmembers,seetheFastZipEventsMemberstopic.

PublicInstanceFieldsDirectoryFailure Delegatetoinvokewhen

processingdirectoryfailures.

FileFailure Delegatetoinvokewhenprocessingfilefailures.

ProcessDirectory Delegatetoinvokewhenprocessingdirectories.

ProcessFile Delegatetoinvokewhenprocessingfiles.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEventsFields

SharpZipCompressionLibrary

Delegatetoinvokewhenprocessingdirectoryfailures.

publicDirectoryFailureDelegateDirectoryFailure;

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.DirectoryFailureField

SharpZipCompressionLibrary

Delegatetoinvokewhenprocessingfilefailures.

publicFileFailureDelegateFileFailure;

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.FileFailureField

SharpZipCompressionLibrary

Delegatetoinvokewhenprocessingdirectories.

publicProcessDirectoryDelegateProcessDirectory;

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.ProcessDirectoryField

SharpZipCompressionLibrary

Delegatetoinvokewhenprocessingfiles.

publicProcessFileDelegateProcessFile;

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.ProcessFileField

SharpZipCompressionLibrary

ThemethodsoftheFastZipEventsclassarelistedbelow.ForacompletelistofFastZipEventsclassmembers,seetheFastZipEventsMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

OnDirectoryFailure Raisethedirectoryfailureevent.

OnFileFailure Raisesthefilefailureevent.

OnProcessDirectory RaisestheProcessDirectoryEvent.

OnProcessFile RaisestheProcessFileEvent.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlso

FastZipEventsMethods

FastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Raisethedirectoryfailureevent.

publicvoidOnDirectoryFailure(

stringdirectory,

Exceptione

);

Parametersdirectory

Thedirectory.

eTheexceptionforthisevent.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.OnDirectoryFailureMethod

SharpZipCompressionLibrary

Raisesthefilefailureevent.

publicvoidOnFileFailure(

stringfile,

Exceptione

);

Parametersfile

Thefileforthisevent.

eTheexceptionforthisevent.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.OnFileFailureMethod

SharpZipCompressionLibrary

RaisestheProcessDirectoryEvent.

publicvoidOnProcessDirectory(

stringdirectory,

boolhasMatchingFiles

);

Parametersdirectory

Thedirectoryforthisevent.

hasMatchingFilesFlagindicatingifdirectoryhasmatchingfilesasdeterminedbythecurrentfilter.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.OnProcessDirectoryMethod

SharpZipCompressionLibrary

RaisestheProcessFileEvent.

publicvoidOnProcessFile(

stringfile

);

Parametersfile

Thefileforthisevent.

SeeAlsoFastZipEventsClass|ICSharpCode.SharpZipLib.ZipNamespace

FastZipEvents.OnProcessFileMethod

SharpZipCompressionLibrary

ArgumentsusedwithKeysRequiredEvent

Foralistofallmembersofthistype,seeKeysRequiredEventArgsMembers.

System.ObjectSystem.EventArgsICSharpCode.SharpZipLib.Zip.KeysRequiredEventArgs

publicclassKeysRequiredEventArgs:

EventArgs

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoKeysRequiredEventArgsMembers|ICSharpCode.SharpZipLib.ZipNamespace

KeysRequiredEventArgsClass

SharpZipCompressionLibrary

KeysRequiredEventArgsoverview

PublicInstanceConstructorsKeysRequiredEventArgs Overloaded.Initializesanew

instanceoftheKeysRequiredEventArgsclass.

PublicInstancePropertiesFileName Getthenameofthefilefor

whichkeysarerequired.

Key Get/setthekeyvalue

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inherited Createsashallowcopyofthe

KeysRequiredEventArgsMembers

fromObject) currentObject.

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofKeysRequiredEventArgs

OverloadListInitialiseanewinstanceofKeysRequiredEventArgs

publicKeysRequiredEventArgs(string);

InitialiseanewinstanceofKeysRequiredEventArgs

publicKeysRequiredEventArgs(string,byte[]);

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace

KeysRequiredEventArgsConstructor

SharpZipCompressionLibrary

InitialiseanewinstanceofKeysRequiredEventArgs

publicKeysRequiredEventArgs(

stringname

);

Parametersname

Thenameofthefileforwhichkeysarerequired.

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace|KeysRequiredEventArgsConstructorOverloadList

KeysRequiredEventArgsConstructor(String)

SharpZipCompressionLibrary

InitialiseanewinstanceofKeysRequiredEventArgs

publicKeysRequiredEventArgs(

stringname,

byte[]keyValue

);

Parametersname

Thenameofthefileforwhichkeysarerequired.

keyValueThecurrentkeyvalue.

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace|KeysRequiredEventArgsConstructorOverloadList

KeysRequiredEventArgsConstructor(String,Byte[])

SharpZipCompressionLibrary

ThepropertiesoftheKeysRequiredEventArgsclassarelistedbelow.ForacompletelistofKeysRequiredEventArgsclassmembers,seetheKeysRequiredEventArgsMemberstopic.

PublicInstancePropertiesFileName Getthenameofthefilefor

whichkeysarerequired.

Key Get/setthekeyvalue

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace

KeysRequiredEventArgsProperties

SharpZipCompressionLibrary

Getthenameofthefileforwhichkeysarerequired.

publicstringFileName{get;}

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace

KeysRequiredEventArgs.FileNameProperty

SharpZipCompressionLibrary

Get/setthekeyvalue

publicbyte[]Key{get;set;}

SeeAlsoKeysRequiredEventArgsClass|ICSharpCode.SharpZipLib.ZipNamespace

KeysRequiredEventArgs.KeyProperty

SharpZipCompressionLibrary

ThisclasscontainsconstantsusedforZipformatfiles

Foralistofallmembersofthistype,seeZipConstantsMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.ZipConstants

publicsealedclassZipConstants

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipConstantsMembers|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstantsClass

SharpZipCompressionLibrary

ZipConstantsoverview

PublicStaticFieldsCENATT Offsetofinternalfile

attributesincentralfileheader

CENATX Offsetofexternalfileattributesincentralfileheader

CENCOM Offsetoffilecommentlengthincentralfileheader

CENCRC Offsetofcrc-32incentralfileheader

CENDIGITALSIG Centralheaderdigitialsignature

CENDSK Offsetofdiskstartnumberincentralfileheader

CENEXT Offsetofextrafieldlengthincentralfileheader

CENFLG Offsetofgeneralpurposebitflagincentralfileheader

CENHDR Sizeofcentralheaderentry

CENHOW Offsetofcompressionmethodincentralfileheader

CENLEN Offsetofuncompressedsizeincentralfileheader

CENNAM Offsetoffilenamelengthincentralfileheader

CENOFF Offsetofrelativeoffsetof

ZipConstantsMembers

localheaderincentralfileheader

CENSIG Signatureforcentralheader

CENSIG64 SignatureforZip64centralfileheader

CENSIZ Offsetofcompressedsizeincentralfileheader

CENTIM Offsetoftime/dateincentralfileheader

CENVEM Offsetofversionmadebyincentralfileheader

CENVER Offsetofversionneededtoextractincentralfileheader

CRYPTO_HEADER_SIZE Sizeofcryptographicheaderstoredbeforeentrydata

ENDCOM OffsetofZIPfilecommentlength

ENDDCD Offsetofnumberofdiskwithstartofcentraldirectory

ENDHDR Sizeofendofcentralrecord(excludingvariablefields)

ENDNRD Offsetofnumberofthisdisk

ENDOFF Offsetofoffsetofstartofcentraldirectorywithrespecttostartingdisknumber

ENDSIG Endofcentraldirectory

recordsignature

ENDSIZ Offsetofsizeofcentraldirectory

ENDSUB Offsetofnumberofentriesinthecentraldirectoryofthisdisk

ENDTOT Offsetoftotalnumberofentriesinthecentraldirectory

EXTCRC Offsetofcrc-32indatadescriptor

EXTHDR Sizeofdatadescriptor

EXTLEN Offsetofuncompressedlengthindatadescriptor

EXTSIG Signaturefordatadescriptor

EXTSIZ Offsetofcompressedsizeindatadescriptor

LOCCRC Offsetofcrc-32inlocalentryheader

LOCEXT Offsetofextrafieldlengthinlocalentryheader

LOCFLG Offsetofgeneralpurposeflagsinlocalentryheader

LOCHDR Sizeoflocalentryheader(excludingvariablelengthfieldsatend)

LOCHOW Offsetofcompressionmethodinlocalentryheader

LOCLEN Offsetofuncompressedsizeinlocalentryheader

LOCNAM Offsetoffilenamelengthinlocalentryheader

LOCSIG Signatureforlocalentryheader

LOCSIZ Offsetofcompressedsizeinlocalentryheader

LOCTIM Offsetoflastmodfiletime+dateinlocalentryheader

LOCVER Offsetofversiontoextractinlocalentryheader

SPANNINGSIG Signatureforspanningentry

SPANTEMPSIG Signaturefortemporaryspanningentry

VERSION_MADE_BY Theversionmadebyfieldforentriesinthecentralheaderwhencreatedbythislibrary

VERSION_STRONG_ENCRYPTIONTheminimumversionrequiredtosupportstrongencryption

PublicStaticPropertiesDefaultCodePage Defaultencodingusedforstring

conversion.0givesthedefaultsystemAnsicodepage.DontuseunicodeencodingsifyouwanttobeZipcompatible!Usingthedefaultcodepageisntthefullsolutionneccessarilytherearemanyvariablefactors,codepage850isoftenagoodchoiceforEuropeanusers,howeverbecarefulabout

compatability.

PublicStaticMethodsConvertToArray Convertastringtoabytearray

ConvertToString Overloaded.Convertaportionofabytearraytoastring.

PublicInstanceConstructorsZipConstantsConstructor Initializesanewinstanceofthe

ZipConstantsclass.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheZipConstantsclass.

publicZipConstants();

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstantsConstructor

SharpZipCompressionLibrary

ThefieldsoftheZipConstantsclassarelistedbelow.ForacompletelistofZipConstantsclassmembers,seetheZipConstantsMemberstopic.

PublicStaticFieldsCENATT Offsetofinternalfile

attributesincentralfileheader

CENATX Offsetofexternalfileattributesincentralfileheader

CENCOM Offsetoffilecommentlengthincentralfileheader

CENCRC Offsetofcrc-32incentralfileheader

CENDIGITALSIG Centralheaderdigitialsignature

CENDSK Offsetofdiskstartnumberincentralfileheader

CENEXT Offsetofextrafieldlengthincentralfileheader

CENFLG Offsetofgeneralpurposebitflagincentralfileheader

CENHDR Sizeofcentralheaderentry

CENHOW Offsetofcompressionmethodincentralfileheader

CENLEN Offsetofuncompressedsizeincentralfileheader

CENNAM Offsetoffilenamelengthincentralfileheader

ZipConstantsFields

CENOFF Offsetofrelativeoffsetoflocalheaderincentralfileheader

CENSIG Signatureforcentralheader

CENSIG64 SignatureforZip64centralfileheader

CENSIZ Offsetofcompressedsizeincentralfileheader

CENTIM Offsetoftime/dateincentralfileheader

CENVEM Offsetofversionmadebyincentralfileheader

CENVER Offsetofversionneededtoextractincentralfileheader

CRYPTO_HEADER_SIZE Sizeofcryptographicheaderstoredbeforeentrydata

ENDCOM OffsetofZIPfilecommentlength

ENDDCD Offsetofnumberofdiskwithstartofcentraldirectory

ENDHDR Sizeofendofcentralrecord(excludingvariablefields)

ENDNRD Offsetofnumberofthisdisk

ENDOFF Offsetofoffsetofstartofcentraldirectorywithrespecttostartingdisknumber

ENDSIG Endofcentraldirectoryrecordsignature

ENDSIZ Offsetofsizeofcentraldirectory

ENDSUB Offsetofnumberofentriesinthecentraldirectoryofthisdisk

ENDTOT Offsetoftotalnumberofentriesinthecentraldirectory

EXTCRC Offsetofcrc-32indatadescriptor

EXTHDR Sizeofdatadescriptor

EXTLEN Offsetofuncompressedlengthindatadescriptor

EXTSIG Signaturefordatadescriptor

EXTSIZ Offsetofcompressedsizeindatadescriptor

LOCCRC Offsetofcrc-32inlocalentryheader

LOCEXT Offsetofextrafieldlengthinlocalentryheader

LOCFLG Offsetofgeneralpurposeflagsinlocalentryheader

LOCHDR Sizeoflocalentryheader(excludingvariablelengthfieldsatend)

LOCHOW Offsetofcompressionmethodinlocalentryheader

LOCLEN Offsetofuncompressed

sizeinlocalentryheader

LOCNAM Offsetoffilenamelengthinlocalentryheader

LOCSIG Signatureforlocalentryheader

LOCSIZ Offsetofcompressedsizeinlocalentryheader

LOCTIM Offsetoflastmodfiletime+dateinlocalentryheader

LOCVER Offsetofversiontoextractinlocalentryheader

SPANNINGSIG Signatureforspanningentry

SPANTEMPSIG Signaturefortemporaryspanningentry

VERSION_MADE_BY Theversionmadebyfieldforentriesinthecentralheaderwhencreatedbythislibrary

VERSION_STRONG_ENCRYPTIONTheminimumversionrequiredtosupportstrongencryption

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Offsetofinternalfileattributesincentralfileheader

publicconstintCENATT=36;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENATTField

SharpZipCompressionLibrary

Offsetofexternalfileattributesincentralfileheader

publicconstintCENATX=38;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENATXField

SharpZipCompressionLibrary

Offsetoffilecommentlengthincentralfileheader

publicconstintCENCOM=32;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENCOMField

SharpZipCompressionLibrary

Offsetofcrc-32incentralfileheader

publicconstintCENCRC=16;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENCRCField

SharpZipCompressionLibrary

Centralheaderdigitialsignature

publicconstintCENDIGITALSIG=84233040;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENDIGITALSIGField

SharpZipCompressionLibrary

Offsetofdiskstartnumberincentralfileheader

publicconstintCENDSK=34;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENDSKField

SharpZipCompressionLibrary

Offsetofextrafieldlengthincentralfileheader

publicconstintCENEXT=30;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENEXTField

SharpZipCompressionLibrary

Offsetofgeneralpurposebitflagincentralfileheader

publicconstintCENFLG=8;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENFLGField

SharpZipCompressionLibrary

Sizeofcentralheaderentry

publicconstintCENHDR=46;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENHDRField

SharpZipCompressionLibrary

Offsetofcompressionmethodincentralfileheader

publicconstintCENHOW=10;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENHOWField

SharpZipCompressionLibrary

Offsetofuncompressedsizeincentralfileheader

publicconstintCENLEN=24;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENLENField

SharpZipCompressionLibrary

Offsetoffilenamelengthincentralfileheader

publicconstintCENNAM=28;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENNAMField

SharpZipCompressionLibrary

Offsetofrelativeoffsetoflocalheaderincentralfileheader

publicconstintCENOFF=42;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENOFFField

SharpZipCompressionLibrary

Signatureforcentralheader

publicconstintCENSIG=33639248;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENSIGField

SharpZipCompressionLibrary

SignatureforZip64centralfileheader

publicconstintCENSIG64=101075792;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENSIG64Field

SharpZipCompressionLibrary

Offsetofcompressedsizeincentralfileheader

publicconstintCENSIZ=20;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENSIZField

SharpZipCompressionLibrary

Offsetoftime/dateincentralfileheader

publicconstintCENTIM=12;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENTIMField

SharpZipCompressionLibrary

Offsetofversionmadebyincentralfileheader

publicconstintCENVEM=4;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENVEMField

SharpZipCompressionLibrary

Offsetofversionneededtoextractincentralfileheader

publicconstintCENVER=6;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CENVERField

SharpZipCompressionLibrary

Sizeofcryptographicheaderstoredbeforeentrydata

publicconstintCRYPTO_HEADER_SIZE=12;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.CRYPTO_HEADER_SIZEField

SharpZipCompressionLibrary

OffsetofZIPfilecommentlength

publicconstintENDCOM=20;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDCOMField

SharpZipCompressionLibrary

Offsetofnumberofdiskwithstartofcentraldirectory

publicconstintENDDCD=6;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDDCDField

SharpZipCompressionLibrary

Sizeofendofcentralrecord(excludingvariablefields)

publicconstintENDHDR=22;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDHDRField

SharpZipCompressionLibrary

Offsetofnumberofthisdisk

publicconstintENDNRD=4;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDNRDField

SharpZipCompressionLibrary

Offsetofoffsetofstartofcentraldirectorywithrespecttostartingdisknumber

publicconstintENDOFF=16;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDOFFField

SharpZipCompressionLibrary

Endofcentraldirectoryrecordsignature

publicconstintENDSIG=101010256;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDSIGField

SharpZipCompressionLibrary

Offsetofsizeofcentraldirectory

publicconstintENDSIZ=12;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDSIZField

SharpZipCompressionLibrary

Offsetofnumberofentriesinthecentraldirectoryofthisdisk

publicconstintENDSUB=8;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDSUBField

SharpZipCompressionLibrary

Offsetoftotalnumberofentriesinthecentraldirectory

publicconstintENDTOT=10;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ENDTOTField

SharpZipCompressionLibrary

Offsetofcrc-32indatadescriptor

publicconstintEXTCRC=4;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.EXTCRCField

SharpZipCompressionLibrary

Sizeofdatadescriptor

publicconstintEXTHDR=16;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.EXTHDRField

SharpZipCompressionLibrary

Offsetofuncompressedlengthindatadescriptor

publicconstintEXTLEN=12;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.EXTLENField

SharpZipCompressionLibrary

Signaturefordatadescriptor

publicconstintEXTSIG=134695760;

RemarksThisisonlyusedwherethelength,Crc,orcompressedsizeisntknownwhentheentryiscreatedandtheoutputstreamdoesntsupportseeking.Thelocalentrycannotbe'patched'withthecorrectvaluesinthiscasesothevaluesarerecordedafterthedataprefixedbythisheader,aswellasinthecentraldirectory.

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.EXTSIGField

SharpZipCompressionLibrary

Offsetofcompressedsizeindatadescriptor

publicconstintEXTSIZ=8;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.EXTSIZField

SharpZipCompressionLibrary

Offsetofcrc-32inlocalentryheader

publicconstintLOCCRC=14;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCCRCField

SharpZipCompressionLibrary

Offsetofextrafieldlengthinlocalentryheader

publicconstintLOCEXT=28;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCEXTField

SharpZipCompressionLibrary

Offsetofgeneralpurposeflagsinlocalentryheader

publicconstintLOCFLG=6;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCFLGField

SharpZipCompressionLibrary

Sizeoflocalentryheader(excludingvariablelengthfieldsatend)

publicconstintLOCHDR=30;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCHDRField

SharpZipCompressionLibrary

Offsetofcompressionmethodinlocalentryheader

publicconstintLOCHOW=8;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCHOWField

SharpZipCompressionLibrary

Offsetofuncompressedsizeinlocalentryheader

publicconstintLOCLEN=22;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCLENField

SharpZipCompressionLibrary

Offsetoffilenamelengthinlocalentryheader

publicconstintLOCNAM=26;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCNAMField

SharpZipCompressionLibrary

Signatureforlocalentryheader

publicconstintLOCSIG=67324752;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCSIGField

SharpZipCompressionLibrary

Offsetofcompressedsizeinlocalentryheader

publicconstintLOCSIZ=18;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCSIZField

SharpZipCompressionLibrary

Offsetoflastmodfiletime+dateinlocalentryheader

publicconstintLOCTIM=10;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCTIMField

SharpZipCompressionLibrary

Offsetofversiontoextractinlocalentryheader

publicconstintLOCVER=4;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.LOCVERField

SharpZipCompressionLibrary

Signatureforspanningentry

publicconstintSPANNINGSIG=134695760;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.SPANNINGSIGField

SharpZipCompressionLibrary

Signaturefortemporaryspanningentry

publicconstintSPANTEMPSIG=808471376;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.SPANTEMPSIGField

SharpZipCompressionLibrary

Theversionmadebyfieldforentriesinthecentralheaderwhencreatedbythislibrary

publicconstintVERSION_MADE_BY=20;

RemarksThisisalsotheZipversionforthelibrarywhencomparingagainsttheversionrequiredtoextractforanentry.SeeZipInputStream.CanDecompressEntry.

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.VERSION_MADE_BYField

SharpZipCompressionLibrary

Theminimumversionrequiredtosupportstrongencryption

publicconstintVERSION_STRONG_ENCRYPTION

=50;

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.VERSION_STRONG_ENCRYPTIONField

SharpZipCompressionLibrary

ThepropertiesoftheZipConstantsclassarelistedbelow.ForacompletelistofZipConstantsclassmembers,seetheZipConstantsMemberstopic.

PublicStaticPropertiesDefaultCodePage Defaultencodingusedforstring

conversion.0givesthedefaultsystemAnsicodepage.DontuseunicodeencodingsifyouwanttobeZipcompatible!Usingthedefaultcodepageisntthefullsolutionneccessarilytherearemanyvariablefactors,codepage850isoftenagoodchoiceforEuropeanusers,howeverbecarefulaboutcompatability.

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstantsProperties

SharpZipCompressionLibrary

Defaultencodingusedforstringconversion.0givesthedefaultsystemAnsicodepage.DontuseunicodeencodingsifyouwanttobeZipcompatible!Usingthedefaultcodepageisntthefullsolutionneccessarilytherearemanyvariablefactors,codepage850isoftenagoodchoiceforEuropeanusers,howeverbecarefulaboutcompatability.

publicstaticintDefaultCodePage{get;set;}

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.DefaultCodePageProperty

SharpZipCompressionLibrary

ThemethodsoftheZipConstantsclassarelistedbelow.ForacompletelistofZipConstantsclassmembers,seetheZipConstantsMemberstopic.

PublicStaticMethodsConvertToArray Convertastringtoabytearray

ConvertToString Overloaded.Convertaportionofabytearraytoastring.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstantsMethods

SharpZipCompressionLibrary

Convertastringtoabytearray

publicstaticbyte[]ConvertToArray(

stringstr

);

Parametersstr

Stringtoconverttoanarray

ReturnValueConvertedarray

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ConvertToArrayMethod

SharpZipCompressionLibrary

Convertbytearraytostring

OverloadListConvertbytearraytostring

publicstaticstringConvertToString(byte[]);

Convertaportionofabytearraytoastring.

publicstaticstringConvertToString(byte[],int);

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipConstants.ConvertToStringMethod

SharpZipCompressionLibrary

Convertbytearraytostring

publicstaticstringConvertToString(

byte[]data

);

Parametersdata

Bytearraytoconvert

ReturnValuedataconvertedtoastring

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipConstants.ConvertToStringOverloadList

ZipConstants.ConvertToStringMethod(Byte[])

SharpZipCompressionLibrary

Convertaportionofabytearraytoastring.

publicstaticstringConvertToString(

byte[]data,

intlength

);

Parametersdata

Datatoconverttostring

lengthNumberofbytestoconvertstartingfromindex0

ReturnValuedata[0]..data[length-1]convertedtoastring

SeeAlsoZipConstantsClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipConstants.ConvertToStringOverloadList

ZipConstants.ConvertToStringMethod(Byte[],Int32)

SharpZipCompressionLibrary

Thisclassrepresentsanentryinaziparchive.ThiscanbeafileoradirectoryZipFileandZipInputStreamwillgiveyouinstancesofthisclassasinformationaboutthemembersinanarchive.ZipOutputStreamusesaninstanceofthisclasswhencreatinganentryinaZipfile.

Authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeZipEntryMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.ZipEntry

publicclassZipEntry:ICloneable

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipEntryMembers|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntryClass

SharpZipCompressionLibrary

ZipEntryoverview

PublicStaticMethodsCleanName Overloaded.Cleansaname

makingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').

PublicInstanceConstructorsZipEntry Overloaded.Initializesanew

instanceoftheZipEntryclass.

PublicInstancePropertiesComment Gets/Setstheentrycomment.

CompressedSize Gets/Setsthesizeofthecompresseddata.

CompressionMethod Gets/Setsthecompressionmethod.OnlyDeflatedandStoredaresupported.

Crc Gets/Setsthecrcoftheuncompresseddata.

DateTime Gets/Setsthetimeoflastmodificationoftheentry.

DosTime Get/SetDosTime

ExternalFileAttributes Get/Setexternalfileattributesasaninteger.ThevaluesofthisareoperatingsystemdependantseeHostSystemfordetails

ExtraData Gets/Setstheextradata.

ZipEntryMembers

Flags Get/Setgeneralpurposebitflagforentry

HostSystem GetsthecompatabilityinformationfortheexternalfileattributeIftheexternalfileattributesarecompatiblewithMS-DOSandcanbereadbyPKZIPforDOSversion2.04gthenthisvaluewillbezero.Otherwisethevaluewillbenon-zeroandidentifythehostsystemonwhichtheattributesarecompatible.

IsCrypted Get/Setflagindicatingifentryisencrypted.Asimplehelperroutinetoaidinterpretationofflags

IsDirectory Getsavalueindicatingoftheiftheentryisadirectory.Adirectoryisdeterminedbyanentrynamewithatrailingslash'/'.Theexternalfileattributescanalsomarkafileasadirectory.Thetrailingslashconventionshouldalwaysbefollowedhowever.

IsFile Getavalueoftrueiftheentryappearstobeafile;falseotherwise

Name Returnstheentryname.Thepathcomponentsintheentryshouldalwaysseparatedbyslashes('/').DosdevicenameslikeC:shouldalsoberemoved.SeeCleanName.

Offset Get/setoffsetforuseincentralheader

RequiresZip64 GetsavalueindicatingiftheentryrequiresZip64extensionstobestored

Size Gets/Setsthesizeoftheuncompresseddata.

Version GetminimumZipfeatureversionrequiredtoextractthisentry

VersionMadeBy Gettheversionmadebyforthisentryorzeroifunknown.Thevalue/10indicatesthemajorversionnumber,andthevaluemod10istheminorversionnumber

ZipFileIndex Get/SetindexofthisentryinZipfile

PublicInstanceMethodsClone Createsacopyofthiszipentry.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString GetsthestringrepresentationofthisZipEntry.

ProtectedInstanceMethods

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Createsazipentrywiththegivenname.

OverloadListCreatesacopyofthegivenzipentry.

publicZipEntry(ZipEntry);

Createsazipentrywiththegivenname.

publicZipEntry(string);

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntryConstructor

SharpZipCompressionLibrary

Createsazipentrywiththegivenname.

publicZipEntry(

stringname

);

Parametersname

Thenameforthisentry.Canincludedirectorycomponents.Theconventionfornamesis'unix'stylepathswithnodevicenamesandpathelementsseparatedby'/'characters.ThisisnotenforcedseeCleanNameonhowtoensurenamesarevalidifthisisdesired.

ExceptionsExceptionType ConditionArgumentNullException Thenamepassedisnull

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipEntryConstructorOverloadList

ZipEntryConstructor(String)

SharpZipCompressionLibrary

Createsacopyofthegivenzipentry.

publicZipEntry(

ZipEntrye

);

Parameterse

Theentrytocopy.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipEntryConstructorOverloadList

ZipEntryConstructor(ZipEntry)

SharpZipCompressionLibrary

ThepropertiesoftheZipEntryclassarelistedbelow.ForacompletelistofZipEntryclassmembers,seetheZipEntryMemberstopic.

PublicInstancePropertiesComment Gets/Setstheentrycomment.

CompressedSize Gets/Setsthesizeofthecompresseddata.

CompressionMethod Gets/Setsthecompressionmethod.OnlyDeflatedandStoredaresupported.

Crc Gets/Setsthecrcoftheuncompresseddata.

DateTime Gets/Setsthetimeoflastmodificationoftheentry.

DosTime Get/SetDosTime

ExternalFileAttributes Get/Setexternalfileattributesasaninteger.ThevaluesofthisareoperatingsystemdependantseeHostSystemfordetails

ExtraData Gets/Setstheextradata.

Flags Get/Setgeneralpurposebitflagforentry

HostSystem GetsthecompatabilityinformationfortheexternalfileattributeIftheexternalfileattributesarecompatiblewithMS-DOSandcanbereadbyPKZIPforDOSversion2.04gthenthisvaluewillbezero.Otherwisethevaluewillbenon-zeroandidentifythehost

ZipEntryProperties

systemonwhichtheattributesarecompatible.

IsCrypted Get/Setflagindicatingifentryisencrypted.Asimplehelperroutinetoaidinterpretationofflags

IsDirectory Getsavalueindicatingoftheiftheentryisadirectory.Adirectoryisdeterminedbyanentrynamewithatrailingslash'/'.Theexternalfileattributescanalsomarkafileasadirectory.Thetrailingslashconventionshouldalwaysbefollowedhowever.

IsFile Getavalueoftrueiftheentryappearstobeafile;falseotherwise

Name Returnstheentryname.Thepathcomponentsintheentryshouldalwaysseparatedbyslashes('/').DosdevicenameslikeC:shouldalsoberemoved.SeeCleanName.

Offset Get/setoffsetforuseincentralheader

RequiresZip64 GetsavalueindicatingiftheentryrequiresZip64extensionstobestored

Size Gets/Setsthesizeoftheuncompresseddata.

Version GetminimumZipfeatureversionrequiredtoextractthisentry

VersionMadeBy Gettheversionmadebyforthisentryorzeroifunknown.Thevalue/10indicatesthemajorversionnumber,andthevaluemod10istheminorversionnumber

ZipFileIndex Get/SetindexofthisentryinZipfile

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Gets/Setstheentrycomment.

publicstringComment{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Ifcommentislongerthan0xffff.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CommentProperty

SharpZipCompressionLibrary

Gets/Setsthesizeofthecompresseddata.

publiclongCompressedSize{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Sizeisnotintherange

0..0xffffffff

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CompressedSizeProperty

SharpZipCompressionLibrary

Gets/Setsthecompressionmethod.OnlyDeflatedandStoredaresupported.

publicCompressionMethodCompressionMethod{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CompressionMethodProperty

SharpZipCompressionLibrary

Gets/Setsthecrcoftheuncompresseddata.

publiclongCrc{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Crcisnotintherange

0..0xffffffffL

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CrcProperty

SharpZipCompressionLibrary

Gets/Setsthetimeoflastmodificationoftheentry.

publicSystem.DateTimeDateTime{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.DateTimeProperty

SharpZipCompressionLibrary

Get/SetDosTime

publiclongDosTime{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.DosTimeProperty

SharpZipCompressionLibrary

Get/Setexternalfileattributesasaninteger.ThevaluesofthisareoperatingsystemdependantseeHostSystemfordetails

publicintExternalFileAttributes{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.ExternalFileAttributesProperty

SharpZipCompressionLibrary

Gets/Setstheextradata.

publicbyte[]ExtraData{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Extradataislongerthan0xffff

bytes.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.ExtraDataProperty

SharpZipCompressionLibrary

Get/Setgeneralpurposebitflagforentry

publicintFlags{get;set;}

RemarksGeneralpurposebitflagBit0:Ifset,indicatesthefileisencryptedBit1-2Onlyusedforcompressiontype6Imploding,and8,9deflatingImploding:Bit1ifsetindicatesan8Kslidingdictionarywasused.Ifcleara4kdictionarywasusedBit2ifsetindicates3Shannon-Fannotreeswereusedtoencodetheslidingdictionary,2otherwise

Deflating:Bit2Bit100Normalcompressionwasused01Maximumcompressionwasused10Fastcompressionwasused11Superfastcompressionwasused

Bit3:Ifset,thefieldscrc-32,compressedsizeanduncompressedsizearewerenotabletobewrittenduringzipfilecreationThecorrectvaluesareheldinadatadescriptorimmediatelyfollowingthecompresseddata.Bit4:ReservedforusebyPKZIPforenhanceddeflatingBit5:IfsetindicatesthefilecontainscompressedpatchdataBit6:Ifsetindicatesstrongencryptionwasused.Bit7-15:Unusedorreserved

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.FlagsProperty

SharpZipCompressionLibrary

GetsthecompatabilityinformationfortheexternalfileattributeIftheexternalfileattributesarecompatiblewithMS-DOSandcanbereadbyPKZIPforDOSversion2.04gthenthisvaluewillbezero.Otherwisethevaluewillbenon-zeroandidentifythehostsystemonwhichtheattributesarecompatible.

publicintHostSystem{get;}

RemarksThevaluesforthisasdefinedintheZipFileformatandbyothersareshownbelow.Thevaluesaresomewhatmisleadinginsomecasesastheyarenotallusedasshown.Youshouldconsulttherelevantdocumentationtoobtainuptodateandcorrectinformation.Themodifiedappnotebytheinfozipgroupisparticularlyhelpfulasitdocumentsalotofpeculiarities.Thedocumentishoweveralittledated.0-MS-DOSandOS/2(FAT/VFAT/FAT32filesystems)1-Amiga2-OpenVMS3-Unix4-VM/CMS5-AtariST6-OS/2HPFS7-Macintosh8-Z-System9-CP/M10-WindowsNTFS11-MVS(OS/390-Z/OS)12-VSE13-AcornRisc14-VFAT15-AlternateMVS16-BeOS17-Tandem18-OS/40019-OS/X(Darwin)99-WinZipAESremainder-unused

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.HostSystemProperty

SharpZipCompressionLibrary

Get/Setflagindicatingifentryisencrypted.Asimplehelperroutinetoaidinterpretationofflags

publicboolIsCrypted{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.IsCryptedProperty

SharpZipCompressionLibrary

Getsavalueindicatingoftheiftheentryisadirectory.Adirectoryisdeterminedbyanentrynamewithatrailingslash'/'.Theexternalfileattributescanalsomarkafileasadirectory.Thetrailingslashconventionshouldalwaysbefollowedhowever.

publicboolIsDirectory{get;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.IsDirectoryProperty

SharpZipCompressionLibrary

Getavalueoftrueiftheentryappearstobeafile;falseotherwise

publicboolIsFile{get;}

RemarksThisonlytakesaccountWindowsattributes.Otheroperatingsystemsareignored.Forlinuxandotherstheresultmaybeincorrect.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.IsFileProperty

SharpZipCompressionLibrary

Returnstheentryname.Thepathcomponentsintheentryshouldalwaysseparatedbyslashes('/').DosdevicenameslikeC:shouldalsoberemoved.SeeCleanName.

publicstringName{get;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.NameProperty

SharpZipCompressionLibrary

Get/setoffsetforuseincentralheader

publicintOffset{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.OffsetProperty

SharpZipCompressionLibrary

GetsavalueindicatingiftheentryrequiresZip64extensionstobestored

publicboolRequiresZip64{get;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.RequiresZip64Property

SharpZipCompressionLibrary

Gets/Setsthesizeoftheuncompresseddata.

publiclongSize{get;set;}

ExceptionsExceptionType ConditionArgumentOutOfRangeException Ifthesizeisnotintherange

0..0xffffffffL

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.SizeProperty

SharpZipCompressionLibrary

GetminimumZipfeatureversionrequiredtoextractthisentry

publicintVersion{get;}

RemarksMinimumfeaturesaredefinedas:1.0-Defaultvalue1.1-Fileisavolumelabel2.0-Fileisafolder/directory2.0-FileiscompressedusingDeflatecompression2.0-Fileisencryptedusingtraditionalencryption2.1-FileiscompressedusingDeflate642.5-FileiscompressedusingPKWAREDCLImplode2.7-Fileisapatchdataset4.5-FileusesZip64formatextensions4.6-FileiscompressedusingBZIP2compression5.0-FileisencryptedusingDES5.0-Fileisencryptedusing3DES5.0-FileisencryptedusingoriginalRC2encryption5.0-FileisencryptedusingRC4encryption5.1-FileisencryptedusingAESencryption5.1-FileisencryptedusingcorrectedRC2encryption5.1-FileisencryptedusingcorrectedRC2-64encryption6.1-Fileisencryptedusingnon-OAEPkeywrapping6.2-Centraldirectoryencryption(notconfirmedyet)

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.VersionProperty

SharpZipCompressionLibrary

Gettheversionmadebyforthisentryorzeroifunknown.Thevalue/10indicatesthemajorversionnumber,andthevaluemod10istheminorversionnumber

publicintVersionMadeBy{get;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.VersionMadeByProperty

SharpZipCompressionLibrary

Get/SetindexofthisentryinZipfile

publicintZipFileIndex{get;set;}

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.ZipFileIndexProperty

SharpZipCompressionLibrary

ThemethodsoftheZipEntryclassarelistedbelow.ForacompletelistofZipEntryclassmembers,seetheZipEntryMemberstopic.

PublicStaticMethodsCleanName Overloaded.Cleansaname

makingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').

PublicInstanceMethodsClone Createsacopyofthiszipentry.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString GetsthestringrepresentationofthisZipEntry.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inherited Createsashallowcopyofthe

ZipEntryMethods

fromObject) currentObject.

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

CleansanamemakingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').NamesaremaderelativebytrimmingleadingslasheswhichiscompatiblewithWindows-XPsbuiltinZipfilehandling.

OverloadListCleansanamemakingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').NamesaremaderelativebytrimmingleadingslasheswhichiscompatiblewithWindows-XPsbuiltinZipfilehandling.

publicstaticstringCleanName(string);

CleansanamemakingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').

publicstaticstringCleanName(string,bool);

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CleanNameMethod

SharpZipCompressionLibrary

CleansanamemakingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').NamesaremaderelativebytrimmingleadingslasheswhichiscompatiblewithWindows-XPsbuiltinZipfilehandling.

publicstaticstringCleanName(

stringname

);

Parametersname

Nametoclean

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipEntry.CleanNameOverloadList

ZipEntry.CleanNameMethod(String)

SharpZipCompressionLibrary

CleansanamemakingitconformtoZipfileconventions.Devicesnames('c:\')andUNCsharenames('\\server\share')areremovedandforwardslashes('\')areconvertedtobackslashes('/').

publicstaticstringCleanName(

stringname,

boolrelativePath

);

Parametersname

Nametoclean

relativePathMakenamesrelativeiftrueorabsoluteiffalse

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipEntry.CleanNameOverloadList

ZipEntry.CleanNameMethod(String,Boolean)

SharpZipCompressionLibrary

Createsacopyofthiszipentry.

publicobjectClone();

ImplementsICloneable.Clone

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.CloneMethod

SharpZipCompressionLibrary

GetsthestringrepresentationofthisZipEntry.

publicoverridestringToString();

SeeAlsoZipEntryClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipEntry.ToStringMethod

SharpZipCompressionLibrary

RepresentserrorsspecifictoZipfilehandling

Foralistofallmembersofthistype,seeZipExceptionMembers.

System.ObjectSystem.ExceptionSystem.ApplicationExceptionICSharpCode.SharpZipLib.SharpZipBaseExceptionICSharpCode.SharpZipLib.Zip.ZipException

publicclassZipException:

SharpZipBaseException

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipExceptionMembers|ICSharpCode.SharpZipLib.ZipNamespace

ZipExceptionClass

SharpZipCompressionLibrary

ZipExceptionoverview

PublicInstanceConstructorsZipException Overloaded.Initializesanew

instanceoftheZipExceptionclass.

PublicInstancePropertiesHelpLink(inheritedfrom

Exception)Getsorsetsalinktothehelpfileassociatedwiththisexception.

InnerException(inheritedfromException)

GetstheExceptioninstancethatcausedthecurrentexception.

Message(inheritedfromException)

Getsamessagethatdescribesthecurrentexception.

Source(inheritedfromException)

Getsorsetsthenameoftheapplicationortheobjectthatcausestheerror.

StackTrace(inheritedfromException)

Getsastringrepresentationoftheframesonthecallstackatthetimethecurrentexceptionwasthrown.

TargetSite(inheritedfromException)

Getsthemethodthatthrowsthecurrentexception.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetBaseException(inheritedfromException)

Whenoverriddeninaderivedclass,returnstheExceptionthat

ZipExceptionMembers

istherootcauseofoneormoresubsequentexceptions.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetObjectData(inheritedfromException)

Whenoverriddeninaderivedclass,setstheSerializationInfowithinformationabouttheexception.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromException)

Createsandreturnsastringrepresentationofthecurrentexception.

ProtectedInstancePropertiesHResult(inheritedfrom

Exception)GetsorsetsHRESULT,acodednumericalvaluethatisassignedtoaspecificexception.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoZipExceptionClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheZipExceptionclass.

OverloadListInitializesanewinstanceoftheZipExceptionclass.

publicZipException();

InitializesanewinstanceoftheZipExceptionclasswithaspecifiederrormessage.

publicZipException(string);

SeeAlsoZipExceptionClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipExceptionConstructor

SharpZipCompressionLibrary

InitializesanewinstanceoftheZipExceptionclass.

publicZipException();

SeeAlsoZipExceptionClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipExceptionConstructorOverloadList

ZipExceptionConstructor()

SharpZipCompressionLibrary

InitializesanewinstanceoftheZipExceptionclasswithaspecifiederrormessage.

publicZipException(

stringmsg

);

SeeAlsoZipExceptionClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipExceptionConstructorOverloadList

ZipExceptionConstructor(String)

SharpZipCompressionLibrary

ThisclassrepresentsaZiparchive.Youcanaskforthecontainedentries,orgetaninputstreamforafileentry.Theentryisautomaticallydecompressed.Thisclassisthreadsafe:Youcanopeninputstreamsforarbitraryentriesindifferentthreads.

Authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeZipFileMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.ZipFile

publicclassZipFile:IEnumerable

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

Example

usingSystem;

usingSystem.Text;

usingSystem.Collections;

usingSystem.IO;

usingICSharpCode.SharpZipLib.Zip;

classMainClass

{

staticpublicvoidMain(string[]args)

{

ZipFilezFile=newZipFile(args[0]);

Console.WriteLine("Listingof:"+zFile.Name);

Console.WriteLine("");

Console.WriteLine("RawSizeSizeDateTimeName");

Console.WriteLine("---------------------------------------");

ZipFileClass

foreach(ZipEntryeinzFile){

DateTimed=e.DateTime;

Console.WriteLine("{0,-10}{1,-10}{2}{3}{4}",e.Size,e.CompressedSize,

d.ToString("dd-MM-yy"),d.ToString("t"),

e.Name);

}

}

}

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipFileMembers|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

ZipFileoverview

PublicInstanceConstructorsZipFile Overloaded.Initializesanew

instanceoftheZipFileclass.

PublicInstanceFieldsKeysRequired Eventhandlerforhandling

encryptionkeys.

PublicInstancePropertiesEntryByIndex IndexerpropertyforZipEntries

Name Getsthenameofthiszipfile.

Password Passwordtobeusedforencrypting/decryptingfiles.

Size Getsthenumberofentriesinthiszipfile.

ZipFileComment Getsthecommentforthezipfile.

PublicInstanceMethodsClose ClosestheZipFile.Ifthestream

isIsStreamOwnerthenthisalsoclosestheunderlyinginputstream.Onceclosed,nofurtherinstancemethodsshouldbecalled.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FindEntry Returntheindexoftheentry

ZipFileMembers

withamatchingname

GetEntry Searchesforazipentryinthisarchivewiththegivenname.Stringcomparisonsarecaseinsensitive

GetEnumerator ReturnsanenumeratorfortheZipentriesinthisZipfile.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetInputStream Overloaded.Createsaninputstreamreadingthegivenzipentryasuncompresseddata.NormallyzipentryshouldbeanentryreturnedbyGetEntry().

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

TestArchive Testanarchiveforintegrity/validity

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

OpensaZipfilewiththegivennameforreading.

OverloadListOpensaZipfilereadingthegivenFileStream

publicZipFile(FileStream);

OpensaZipfilereadingthegivenStream

publicZipFile(Stream);

OpensaZipfilewiththegivennameforreading.

publicZipFile(string);

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFileConstructor

SharpZipCompressionLibrary

OpensaZipfilewiththegivennameforreading.

publicZipFile(

stringname

);

ExceptionsExceptionType ConditionIOException Ani/oerroroccurs

ZipException Thefiledoesn'tcontainavalidziparchive.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipFileConstructorOverloadList

ZipFileConstructor(String)

SharpZipCompressionLibrary

OpensaZipfilereadingthegivenFileStream

publicZipFile(

FileStreamfile

);

ExceptionsExceptionType ConditionIOException Ani/oerroroccurs.

ZipException Thefiledoesn'tcontainavalidziparchive.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipFileConstructorOverloadList

ZipFileConstructor(FileStream)

SharpZipCompressionLibrary

OpensaZipfilereadingthegivenStream

publicZipFile(

StreambaseStream

);

ExceptionsExceptionType ConditionIOException Ani/oerroroccurs

ZipException Thefiledoesn'tcontainavalidziparchive.Thestreamprovidedcannotseek

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipFileConstructorOverloadList

ZipFileConstructor(Stream)

SharpZipCompressionLibrary

ThefieldsoftheZipFileclassarelistedbelow.ForacompletelistofZipFileclassmembers,seetheZipFileMemberstopic.

PublicInstanceFieldsKeysRequired Eventhandlerforhandling

encryptionkeys.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFileFields

SharpZipCompressionLibrary

Eventhandlerforhandlingencryptionkeys.

publicKeysRequiredEventHandlerKeysRequired;

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.KeysRequiredField

SharpZipCompressionLibrary

ThepropertiesoftheZipFileclassarelistedbelow.ForacompletelistofZipFileclassmembers,seetheZipFileMemberstopic.

PublicInstancePropertiesEntryByIndex IndexerpropertyforZipEntries

Name Getsthenameofthiszipfile.

Password Passwordtobeusedforencrypting/decryptingfiles.

Size Getsthenumberofentriesinthiszipfile.

ZipFileComment Getsthecommentforthezipfile.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFileProperties

SharpZipCompressionLibrary

IndexerpropertyforZipEntries

publicZipEntrythis[

intindex

]{get;}

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.EntryByIndexProperty

SharpZipCompressionLibrary

Getsthenameofthiszipfile.

publicstringName{get;}

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.NameProperty

SharpZipCompressionLibrary

Passwordtobeusedforencrypting/decryptingfiles.

publicstringPassword{set;}

RemarksSettonullifnopasswordisrequired.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.PasswordProperty

SharpZipCompressionLibrary

Getsthenumberofentriesinthiszipfile.

publicintSize{get;}

ExceptionsExceptionType ConditionInvalidOperationException TheZipfilehasbeenclosed.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.SizeProperty

SharpZipCompressionLibrary

Getsthecommentforthezipfile.

publicstringZipFileComment{get;}

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.ZipFileCommentProperty

SharpZipCompressionLibrary

ThemethodsoftheZipFileclassarelistedbelow.ForacompletelistofZipFileclassmembers,seetheZipFileMemberstopic.

PublicInstanceMethodsClose ClosestheZipFile.Ifthestream

isIsStreamOwnerthenthisalsoclosestheunderlyinginputstream.Onceclosed,nofurtherinstancemethodsshouldbecalled.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FindEntry Returntheindexoftheentrywithamatchingname

GetEntry Searchesforazipentryinthisarchivewiththegivenname.Stringcomparisonsarecaseinsensitive

GetEnumerator ReturnsanenumeratorfortheZipentriesinthisZipfile.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetInputStream Overloaded.Createsaninputstreamreadingthegivenzipentryasuncompresseddata.NormallyzipentryshouldbeanentryreturnedbyGetEntry().

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ZipFileMethods

TestArchive Testanarchiveforintegrity/validity

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

ClosestheZipFile.IfthestreamisIsStreamOwnerthenthisalsoclosestheunderlyinginputstream.Onceclosed,nofurtherinstancemethodsshouldbecalled.

publicvoidClose();

ExceptionsExceptionType ConditionIOException Ani/oerroroccurs.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.CloseMethod

SharpZipCompressionLibrary

Returntheindexoftheentrywithamatchingname

publicintFindEntry(

stringname,

boolignoreCase

);

Parametersname

Entrynametofind

ignoreCaseIftruethecomparisoniscaseinsensitive

ReturnValueTheindexpositionofthematchingentryor-1ifnotfound

ExceptionsExceptionType ConditionInvalidOperationException TheZipfilehasbeenclosed.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.FindEntryMethod

SharpZipCompressionLibrary

Searchesforazipentryinthisarchivewiththegivenname.Stringcomparisonsarecaseinsensitive

publicZipEntryGetEntry(

stringname

);

Parametersname

Thenametofind.Maycontaindirectorycomponentsseparatedbyslashes('/').

ReturnValueThezipentry,ornullifnoentrywiththatnameexists.

ExceptionsExceptionType ConditionInvalidOperationException TheZipfilehasbeenclosed.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.GetEntryMethod

SharpZipCompressionLibrary

ReturnsanenumeratorfortheZipentriesinthisZipfile.

publicIEnumeratorGetEnumerator();

ImplementsIEnumerable.GetEnumerator

ExceptionsExceptionType ConditionInvalidOperationException TheZipfilehasbeenclosed.

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.GetEnumeratorMethod

SharpZipCompressionLibrary

Createsaninputstreamreadingthegivenzipentryasuncompresseddata.NormallyzipentryshouldbeanentryreturnedbyGetEntry().

OverloadListCreatesaninputstreamreadingthegivenzipentryasuncompresseddata.NormallyzipentryshouldbeanentryreturnedbyGetEntry().

publicStreamGetInputStream(ZipEntry);

Createsaninputstreamreadingazipentry

publicStreamGetInputStream(int);

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.GetInputStreamMethod

SharpZipCompressionLibrary

Createsaninputstreamreadingthegivenzipentryasuncompresseddata.NormallyzipentryshouldbeanentryreturnedbyGetEntry().

publicStreamGetInputStream(

ZipEntryentry

);

ReturnValuetheinputstream.

ExceptionsExceptionType ConditionInvalidOperationException TheZipFilehasalreadybeen

closed

ZipException Thecompressionmethodfortheentryisunknown

IndexOutOfRangeException TheentryisnotfoundintheZipFile

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipFile.GetInputStreamOverloadList

ZipFile.GetInputStreamMethod(ZipEntry)

SharpZipCompressionLibrary

Createsaninputstreamreadingazipentry

publicStreamGetInputStream(

intentryIndex

);

ParametersentryIndex

Theindexoftheentrytoobtainaninputstreamfor.

ReturnValueAninputstream.

ExceptionsExceptionType ConditionInvalidOperationException TheZipFilehasalreadybeen

closed

ZipException Thecompressionmethodfortheentryisunknown

IndexOutOfRangeException TheentryisnotfoundintheZipFile

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipFile.GetInputStreamOverloadList

ZipFile.GetInputStreamMethod(Int32)

SharpZipCompressionLibrary

Testanarchiveforintegrity/validity

publicboolTestArchive(

booltestData

);

ParameterstestData

PerformlowleveldataCrccheck

ReturnValuetrueiffthetestpasses,falseotherwise

SeeAlsoZipFileClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipFile.TestArchiveMethod

SharpZipCompressionLibrary

Delegateforhandlingkeys/passwordsettingduringcompresion/decompression.

publicdelegatevoidZipFile.KeysRequiredEventHandler(

objectsender,

KeysRequiredEventArgse

);

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.ZipNamespace

ZipFile.KeysRequiredEventHandlerDelegate

SharpZipCompressionLibrary

ThisisanInflaterInputStreamthatreadsthefilesbaseInputStreamanziparchiveoneafteranother.Ithasaspecialmethodtogetthezipentryofthenextfile.Thezipentrycontainsinformationaboutthefilenamesize,compressedsize,Crc,etc.ItincludessupportforStoredandDeflatedentries.

Authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeZipInputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStreamICSharpCode.SharpZipLib.Zip.ZipInputStream

publicclassZipInputStream:

InflaterInputStream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

ExampleThissampleshowshowtoreadazipfile

[C#]

usingSystem;

usingSystem.Text;

usingSystem.IO;

usingICSharpCode.SharpZipLib.Zip;

classMainClass

{

publicstaticvoidMain(string[]args)

ZipInputStreamClass

{

ZipInputStreams=newZipInputStream(File.OpenRead(args[0]));

ZipEntrytheEntry;

while((theEntry=s.GetNextEntry())!=null){

intsize=2048;

byte[]data=newbyte[2048];

Console.Write("Showcontents(y/n)?");

if(Console.ReadLine()=="y"){

while(true){

size=s.Read(data,0,data.Length);

if(size>0){

Console.Write(newASCIIEncoding().GetString(data,0,size));

}else{

break;

}

}

}

}

s.Close();

}

}

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipInputStreamMembers|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

ZipInputStreamoverview

PublicInstanceConstructorsZipInputStreamConstructor CreatesanewZipinputstream,

forreadingaziparchive.

PublicInstancePropertiesAvailable Returns1ifthereisanentry

availableOtherwisereturns0.

CanDecompressEntry Getsavalueindicatingiftheentrycanbedecompressed

CanRead(inheritedfromInflaterInputStream)

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

CanWrite(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

IsStreamOwner(inheritedfromInflaterInputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromInflaterInputStream)

Avaluerepresentingthelengthofthestreaminbytes.

Password Optionalpasswordusedforencryptionwhennon-null

Position(inheritedfromInflaterInputStream)

Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

ZipInputStreamMembers

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromInflaterInputStream)

Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

BodyRead Readsablockofbytesfromthecurrentzipentry.

Close Closesthezipinputstream

CloseEntry Closesthecurrentzipentryandmovestothenextone.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush(inheritedfromInflaterInputStream)

FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthe

lifetimepolicyforthisinstance.

GetNextEntry Advancestothenextentryinthearchive

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytesfromthestream.

ReadByte Readsabytefromthecurrentzipentry.

Seek(inheritedfromInflaterInputStream)

SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength(inheritedfromInflaterInputStream)

SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip(inheritedfromInflaterInputStream)

Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write(inheritedfromInflaterInputStream)

WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte(inheritedfromInflaterInputStream)

WritesonebytetothecurrentstreamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceFields

baseInputStream(inheritedfromInflaterInputStream)

Basestreamtheinflaterreadsfrom.

csize(inheritedfromInflaterInputStream)

Thecompressedsize

inf(inheritedfromInflaterInputStream)

Decompressorforthisstream

inputBuffer(inheritedfromInflaterInputStream)

Inputbufferforthisstream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill(inheritedfromInflaterInputStream)

Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting(inheritedfromInflaterInputStream)

Clearanycryptographicstate.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

CreatesanewZipinputstream,forreadingaziparchive.

publicZipInputStream(

StreambaseInputStream

);

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStreamConstructor

SharpZipCompressionLibrary

ThepropertiesoftheZipInputStreamclassarelistedbelow.ForacompletelistofZipInputStreamclassmembers,seetheZipInputStreamMemberstopic.

PublicInstancePropertiesAvailable Returns1ifthereisanentry

availableOtherwisereturns0.

CanDecompressEntry Getsavalueindicatingiftheentrycanbedecompressed

CanRead(inheritedfromInflaterInputStream)

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

CanWrite(inheritedfromInflaterInputStream)

Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

IsStreamOwner(inheritedfromInflaterInputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromInflaterInputStream)

Avaluerepresentingthelengthofthestreaminbytes.

Password Optionalpasswordusedforencryptionwhennon-null

Position(inheritedfromInflaterInputStream)

Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

SeeAlso

ZipInputStreamProperties

ZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Returns1ifthereisanentryavailableOtherwisereturns0.

publicoverrideintAvailable{get;}

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.AvailableProperty

SharpZipCompressionLibrary

Getsavalueindicatingiftheentrycanbedecompressed

publicboolCanDecompressEntry{get;}

RemarksTheentrycanonlybedecompressedifthelibrarysupportsthezipfeaturesrequiredtoextractit.SeetheZipEntryVersionpropertyformoredetails.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.CanDecompressEntryProperty

SharpZipCompressionLibrary

Optionalpasswordusedforencryptionwhennon-null

publicstringPassword{get;set;}

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.PasswordProperty

SharpZipCompressionLibrary

ThemethodsoftheZipInputStreamclassarelistedbelow.ForacompletelistofZipInputStreamclassmembers,seetheZipInputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite(inheritedfromInflaterInputStream)

Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

BodyRead Readsablockofbytesfromthecurrentzipentry.

Close Closesthezipinputstream

CloseEntry Closesthecurrentzipentryandmovestothenextone.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush(inheritedfromInflaterInputStream)

FlushesthebaseInputStream

GetHashCode(inheritedfrom Servesasahashfunctionfora

ZipInputStreamMethods

Object) particulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetNextEntry Advancestothenextentryinthearchive

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytesfromthestream.

ReadByte Readsabytefromthecurrentzipentry.

Seek(inheritedfromInflaterInputStream)

SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength(inheritedfromInflaterInputStream)

SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip(inheritedfromInflaterInputStream)

Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write(inheritedfromInflaterInputStream)

WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte(inheritedfrom Writesonebytetothecurrent

InflaterInputStream) streamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill(inheritedfromInflaterInputStream)

Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting(inheritedfromInflaterInputStream)

Clearanycryptographicstate.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Readsablockofbytesfromthecurrentzipentry.

publicintBodyRead(

byte[]b,

intoff,

intlen

);

ReturnValueThenumberofbytesread(thismaybelessthanthelengthrequested,evenbeforetheendofstream),or0onendofstream.

ExceptionsExceptionType ConditionZipException Thedeflatedstreamis

corrupted.

InvalidOperationException Thestreamisnotopen.

Ani/oerroroccured.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.BodyReadMethod

SharpZipCompressionLibrary

Closesthezipinputstream

publicoverridevoidClose();

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.CloseMethod

SharpZipCompressionLibrary

Closesthecurrentzipentryandmovestothenextone.

publicvoidCloseEntry();

ExceptionsExceptionType ConditionInvalidOperationException Thestreamisclosed

ZipException TheZipstreamendsearly

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.CloseEntryMethod

SharpZipCompressionLibrary

Advancestothenextentryinthearchive

publicZipEntryGetNextEntry();

ReturnValueThenextentryinthearchiveornulliftherearenomoreentries.

RemarksIfthepreviousentryisstillopenCloseEntryiscalled.

ExceptionsExceptionType ConditionInvalidOperationException Inputstreamisclosed

ZipException Passwordisnotset,passwordisinvalid,compressionmethodisinvalid,versionrequiredtoextractisnotsupported

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.GetNextEntryMethod

SharpZipCompressionLibrary

Readablockofbytesfromthestream.

publicoverrideintRead(

byte[]destination,

intindex,

intcount

);

Parametersdestination

Thedestinationforthebytes.

indexTheindextostartstoringdata.

countThenumberofbytestoattempttoread.

ReturnValueReturnsthenumberofbytesread.

RemarksZerobytesreadmeansendofstream.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.ReadMethod

SharpZipCompressionLibrary

Readsabytefromthecurrentzipentry.

publicoverrideintReadByte();

ReturnValueThebyteor-1ifendofstreamisreached.

ExceptionsExceptionType Condition

Thedeflatedstreamiscorrupted.

Ani/oerroroccured.

SeeAlsoZipInputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipInputStream.ReadByteMethod

SharpZipCompressionLibrary

ZipNameTransformtransformsnameaspertheZipfileconvention.

Foralistofallmembersofthistype,seeZipNameTransformMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.ZipNameTransform

publicclassZipNameTransform:

INameTransform

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipNameTransformMembers|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransformClass

SharpZipCompressionLibrary

ZipNameTransformoverview

PublicInstanceConstructorsZipNameTransform Overloaded.Initializesanew

instanceoftheZipNameTransformclass.

PublicInstancePropertiesTrimPrefix Get/setthepathprefixtobe

trimmedfrompathsifpresent.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

TransformDirectory TransformadirectorynameaccordingtotheZipfilenamingconventions.

TransformFile TransformafilenameaccordingtotheZipfilenamingconventions.

ProtectedInstanceMethodsFinalize(inheritedfrom AllowsanObjecttoattemptto

ZipNameTransformMembers

Object) freeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

InitializeanewinstanceofZipNameTransform

OverloadListInitializeanewinstanceofZipNameTransform

publicZipNameTransform();

InitializeanewinstanceofZipNameTransform

publicZipNameTransform(bool);

InitializeanewinstanceofZipNameTransform

publicZipNameTransform(bool,string);

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransformConstructor

SharpZipCompressionLibrary

InitializeanewinstanceofZipNameTransform

publicZipNameTransform();

RemarksRelativepathsdefaulttotruewiththisconstructor.

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipNameTransformConstructorOverloadList

ZipNameTransformConstructor()

SharpZipCompressionLibrary

InitializeanewinstanceofZipNameTransform

publicZipNameTransform(

booluseRelativePaths

);

ParametersuseRelativePaths

Iftruerelativepathsarecreated,iffalseabsolutepathsarecreated.

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipNameTransformConstructorOverloadList

ZipNameTransformConstructor(Boolean)

SharpZipCompressionLibrary

InitializeanewinstanceofZipNameTransform

publicZipNameTransform(

booluseRelativePaths,

stringtrimPrefix

);

ParametersuseRelativePaths

Iftruerelativepathsarecreated,iffalseabsolutepathsarecreated.

trimPrefixThestringtotrimfromfrontofpathsiffound.

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace|ZipNameTransformConstructorOverloadList

ZipNameTransformConstructor(Boolean,String)

SharpZipCompressionLibrary

ThepropertiesoftheZipNameTransformclassarelistedbelow.ForacompletelistofZipNameTransformclassmembers,seetheZipNameTransformMemberstopic.

PublicInstancePropertiesTrimPrefix Get/setthepathprefixtobe

trimmedfrompathsifpresent.

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransformProperties

SharpZipCompressionLibrary

Get/setthepathprefixtobetrimmedfrompathsifpresent.

publicstringTrimPrefix{get;set;}

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransform.TrimPrefixProperty

SharpZipCompressionLibrary

ThemethodsoftheZipNameTransformclassarelistedbelow.ForacompletelistofZipNameTransformclassmembers,seetheZipNameTransformMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

TransformDirectory TransformadirectorynameaccordingtotheZipfilenamingconventions.

TransformFile TransformafilenameaccordingtotheZipfilenamingconventions.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlso

ZipNameTransformMethods

ZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

TransformadirectorynameaccordingtotheZipfilenamingconventions.

publicstringTransformDirectory(

stringname

);

Parametersname

Thedirectorynametotransform.

ReturnValueThetransformedname.

ImplementsINameTransform.TransformDirectory

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransform.TransformDirectoryMethod

SharpZipCompressionLibrary

TransformafilenameaccordingtotheZipfilenamingconventions.

publicstringTransformFile(

stringname

);

Parametersname

Thefilenametotransform.

ReturnValueThetransformedname.

ImplementsINameTransform.TransformFile

SeeAlsoZipNameTransformClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipNameTransform.TransformFileMethod

SharpZipCompressionLibrary

ThisisaDeflaterOutputStreamthatwritesthefilesintoaziparchiveoneafteranother.Ithasaspecialmethodtostartanewzipentry.Thezipentriescontainsinformationaboutthefilenamesize,compressedsize,CRC,etc.ItincludessupportforStoredandDeflatedentries.Thisclassisnotthreadsafe.

Authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeZipOutputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStreamICSharpCode.SharpZipLib.Zip.ZipOutputStream

publicclassZipOutputStream:

DeflaterOutputStream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

ExampleThissampleshowshowtocreateazipfile

usingSystem;

usingSystem.IO;

usingICSharpCode.SharpZipLib.Zip;

classMainClass

{

publicstaticvoidMain(string[]args)

{

ZipOutputStreamClass

string[]filenames=Directory.GetFiles(args[0]);

ZipOutputStreams=newZipOutputStream(File.Create(args[1]));

s.SetLevel(5);//0-storeonlyto9-meansbestcompression

foreach(stringfileinfilenames){

FileStreamfs=File.OpenRead(file);

byte[]buffer=newbyte[fs.Length];

fs.Read(buffer,0,buffer.Length);

ZipEntryentry=newZipEntry(file);

s.PutNextEntry(entry);

s.Write(buffer,0,buffer.Length);

}

s.Finish();

s.Close();

}

}

RequirementsNamespace:ICSharpCode.SharpZipLib.ZipAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoZipOutputStreamMembers|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

ZipOutputStreamoverview

PublicInstanceConstructorsZipOutputStreamConstructor CreatesanewZipoutput

stream,writingaziparchive.

PublicInstancePropertiesCanPatchEntries

(inheritedfromDeflaterOutputStream)

Allowsclienttodetermineifanentrycanbepatchedafteritsadded

CanRead(inheritedfromDeflaterOutputStream)

Getsvalueindicatingstreamcanbereadfrom

CanSeek(inheritedfromDeflaterOutputStream)

GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

CanWrite(inheritedfromDeflaterOutputStream)

Getvalueindicatingifthisstreamsupportswriting

IsFinished Getsbooleanindicatingcentralheaderhasbeenaddedforthisarchive...Nofurtherentriescanbeaddedoncethishasbeendone.

IsStreamOwner(inheritedfromDeflaterOutputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromDeflaterOutputStream)

Getcurrentlengthofstream

Password(inheritedfromDeflaterOutputStream)

Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

Position(inheritedfrom

Thecurrentpositionwithinthestream.Alwaysthrowsa

ZipOutputStreamMembers

DeflaterOutputStream) NotSupportedExceptionNotSupportedException

PublicInstanceMethodsBeginRead(inheritedfrom

DeflaterOutputStream)AsynchronousreadsarenotsupportedaNotSupportedExceptionisalwaysthrown

BeginWrite(inheritedfromDeflaterOutputStream)

Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close(inheritedfromDeflaterOutputStream)

Callsfinish()andclosestheunderlyingstreamwhenIsStreamOwneristrue.

CloseEntry Closesthecurrententry,updatingheaderandfooterinformationasrequired

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthestream.Thiswillwritethecentraldirectoryattheendofthezipfileandflushthestream.

Flush(inheritedfrom Flushesthestreambycalling

DeflaterOutputStream) flush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getthecurrentdeflatecompressionlevel

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

PutNextEntry StartsanewZipentry.Itautomaticallyclosesthepreviousentryifpresent.Allentryelementsbarnameareoptional,butmustbecorrectifpresent.Ifthecompressionmethodisstoredandtheoutputisnotpatchablethecompressionforthatentryisautomaticallychangedtodeflatelevel0

Read(inheritedfromDeflaterOutputStream)

Readablockofbytesfromstream

ReadByte(inheritedfromDeflaterOutputStream)

Readabytefromstreamadvancingpositionbyone

Seek(inheritedfrom Setsthecurrentpositionofthis

DeflaterOutputStream) streamtothegivenvalue.Notsupportedbythisclass!

SetComment Setthezipfilecomment.

SetLength(inheritedfromDeflaterOutputStream)

Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLevel Setsdefaultcompressionlevel.Thenewlevelwillbeactivatedimmediately.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesthegivenbuffertothecurrententry.

WriteByte(inheritedfromDeflaterOutputStream)

Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceFieldsbaseOutputStream(inherited

fromDeflaterOutputStream)Basestreamthedeflaterdependson.

buf(inheritedfromDeflaterOutputStream)

Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

def(inheritedfromDeflaterOutputStream)

Thedeflaterwhichisusedtodeflatethestream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Deflate(inheritedfromDeflaterOutputStream)

Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock(inheritedfromDeflaterOutputStream)

Encryptablockofdata

EncryptByte(inheritedfromDeflaterOutputStream)

Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword(inheritedfromDeflaterOutputStream)

Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys(inheritedfromDeflaterOutputStream)

Updateencryptionkeys

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

CreatesanewZipoutputstream,writingaziparchive.

publicZipOutputStream(

StreambaseOutputStream

);

ParametersbaseOutputStream

Theoutputstreamtowhichthearchivecontentsarewritten.

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStreamConstructor

SharpZipCompressionLibrary

ThepropertiesoftheZipOutputStreamclassarelistedbelow.ForacompletelistofZipOutputStreamclassmembers,seetheZipOutputStreamMemberstopic.

PublicInstancePropertiesCanPatchEntries

(inheritedfromDeflaterOutputStream)

Allowsclienttodetermineifanentrycanbepatchedafteritsadded

CanRead(inheritedfromDeflaterOutputStream)

Getsvalueindicatingstreamcanbereadfrom

CanSeek(inheritedfromDeflaterOutputStream)

GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

CanWrite(inheritedfromDeflaterOutputStream)

Getvalueindicatingifthisstreamsupportswriting

IsFinished Getsbooleanindicatingcentralheaderhasbeenaddedforthisarchive...Nofurtherentriescanbeaddedoncethishasbeendone.

IsStreamOwner(inheritedfromDeflaterOutputStream)

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length(inheritedfromDeflaterOutputStream)

Getcurrentlengthofstream

Password(inheritedfromDeflaterOutputStream)

Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

Position(inheritedfromDeflaterOutputStream)

Thecurrentpositionwithinthestream.AlwaysthrowsaNotSupportedExceptionNotSupportedException

ZipOutputStreamProperties

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Getsbooleanindicatingcentralheaderhasbeenaddedforthisarchive...Nofurtherentriescanbeaddedoncethishasbeendone.

publicboolIsFinished{get;}

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.IsFinishedProperty

SharpZipCompressionLibrary

ThemethodsoftheZipOutputStreamclassarelistedbelow.ForacompletelistofZipOutputStreamclassmembers,seetheZipOutputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

DeflaterOutputStream)AsynchronousreadsarenotsupportedaNotSupportedExceptionisalwaysthrown

BeginWrite(inheritedfromDeflaterOutputStream)

Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close(inheritedfromDeflaterOutputStream)

Callsfinish()andclosestheunderlyingstreamwhenIsStreamOwneristrue.

CloseEntry Closesthecurrententry,updatingheaderandfooterinformationasrequired

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthestream.Thiswill

ZipOutputStreamMethods

writethecentraldirectoryattheendofthezipfileandflushthestream.

Flush(inheritedfromDeflaterOutputStream)

Flushesthestreambycallingflush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getthecurrentdeflatecompressionlevel

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

PutNextEntry StartsanewZipentry.Itautomaticallyclosesthepreviousentryifpresent.Allentryelementsbarnameareoptional,butmustbecorrectifpresent.Ifthecompressionmethodisstoredandtheoutputisnotpatchablethecompressionforthatentryisautomaticallychangedtodeflatelevel0

Read(inheritedfromDeflaterOutputStream)

Readablockofbytesfromstream

ReadByte(inheritedfromDeflaterOutputStream)

Readabytefromstreamadvancingpositionbyone

Seek(inheritedfromDeflaterOutputStream)

Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetComment Setthezipfilecomment.

SetLength(inheritedfromDeflaterOutputStream)

Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLevel Setsdefaultcompressionlevel.Thenewlevelwillbeactivatedimmediately.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesthegivenbuffertothecurrententry.

WriteByte(inheritedfromDeflaterOutputStream)

Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Deflate(inheritedfromDeflaterOutputStream)

Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock(inheritedfromDeflaterOutputStream)

Encryptablockofdata

EncryptByte(inheritedfromDeflaterOutputStream)

Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword(inheritedfromDeflaterOutputStream)

Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys(inheritedfromDeflaterOutputStream)

Updateencryptionkeys

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

Closesthecurrententry,updatingheaderandfooterinformationasrequired

publicvoidCloseEntry();

ExceptionsExceptionType ConditionIOException AnI/Oerroroccurs.

InvalidOperationException Noentryisactive.

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.CloseEntryMethod

SharpZipCompressionLibrary

Finishesthestream.Thiswillwritethecentraldirectoryattheendofthezipfileandflushthestream.

publicoverridevoidFinish();

RemarksThisisautomaticallycalledwhenthestreamisclosed.

ExceptionsExceptionType ConditionIOException AnI/Oerroroccurs.

ZipException CommentexceedsthemaximumlengthEntrynameexceedsthemaximumlength

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.FinishMethod

SharpZipCompressionLibrary

Getthecurrentdeflatecompressionlevel

publicintGetLevel();

ReturnValueThecurrentcompressionlevel

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.GetLevelMethod

SharpZipCompressionLibrary

StartsanewZipentry.Itautomaticallyclosesthepreviousentryifpresent.Allentryelementsbarnameareoptional,butmustbecorrectifpresent.Ifthecompressionmethodisstoredandtheoutputisnotpatchablethecompressionforthatentryisautomaticallychangedtodeflatelevel0

publicvoidPutNextEntry(

ZipEntryentry

);

Parametersentry

theentry.

ExceptionsExceptionType ConditionIOException ifanI/Oerroroccured.

InvalidOperationException ifstreamwasfinished

ZipException ToomanyentriesintheZipfileEntrynameistoolongFinishhasalreadybeencalled

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.PutNextEntryMethod

SharpZipCompressionLibrary

Setthezipfilecomment.

publicvoidSetComment(

stringcomment

);

Parameterscomment

Thecommentstring

ExceptionsExceptionType Condition

Encodingofcommentislongerthan0xffffbytes.

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.SetCommentMethod

SharpZipCompressionLibrary

Setsdefaultcompressionlevel.Thenewlevelwillbeactivatedimmediately.

publicvoidSetLevel(

intlevel

);

ExceptionsExceptionType ConditionArgumentOutOfRangeException Levelspecifiedisnotsupported.

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.SetLevelMethod

SharpZipCompressionLibrary

Writesthegivenbuffertothecurrententry.

publicoverridevoidWrite(

byte[]b,

intoff,

intlen

);

ExceptionsExceptionType ConditionZipException Archivesizeisinvalid

InvalidOperationException Noentryisactive.

SeeAlsoZipOutputStreamClass|ICSharpCode.SharpZipLib.ZipNamespace

ZipOutputStream.WriteMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionDeflater ThisistheDeflaterclass.Thedeflater

classcompressesinputwiththedeflatealgorithmdescribedinRFC1951.Ithasseveralcompressionlevelsandthreedifferentstrategiesdescribedbelow.Thisclassisnotthreadsafe.ThisisinherentintheAPI,duetothesplitofdeflateandsetInput.authoroftheoriginaljavaversion:JochenHoenicke

DeflaterConstants Thisclasscontainsconstantsusedfordeflation.

DeflaterEngine Lowlevelcompressionenginefordeflatealgorithmwhichusesa32KslidingwindowwithsecondarycompressionfromHuffman/Shannon-Fanocodes.

DeflaterHuffman ThisistheDeflaterHuffmanclass.Thisclassisnotthreadsafe.ThisisinherentintheAPI,duetothesplitofdeflateandsetInput.authoroftheoriginaljavaversion:JochenHoenicke

DeflaterHuffman.Tree Notdocumented

DeflaterPending ThisclassstoresthependingoutputoftheDeflater.authoroftheoriginaljavaversion:JochenHoenicke

Inflater Inflaterisusedtodecompressdatathathasbeencompressedaccordingtothe"deflate"standarddescribedinrfc1951.BydefaultZlib(rfc1950)headersandfootersareexpectedintheinput.Youcan

ICSharpCode.SharpZipLib.Zip.CompressionNamespace

useconstructor

publicInflater(boolnoHeader)

passingtrueifthereisnoZlibheaderinformationTheusageisasfollowing.Firstyouhavetosetsomeinputwith

setInput()

,theninflate()it.Ifinflatedoesn'tinflateanybytestheremaybethreereasons:

needsInput()returnstruebecausetheinputbufferisempty.Youhavetoprovidemoreinputwith

setInput()

.NOTE:needsInput()alsoreturnstruewhen,thestreamisfinished.

needsDictionary()returnstrue,youhavetoprovideapresetdictionarywith

setDictionary()

.

finished()returnstrue,theinflaterhasfinished.

Oncethefirstoutputbyteisproduced,adictionarywillnotbeneededatalaterstage.authoroftheoriginaljavaversion:JohnLeuner,JochenHoenicke

InflaterHuffmanTree Huffmantreeusedforinflation

PendingBuffer Thisclassisgeneralpurposeclassforwritingdatatoabuffer.ItallowsyoutowritebitsaswellasbytesBasedon

DeflaterPending.javaauthoroftheoriginaljavaversion:JochenHoenicke

EnumerationsEnumeration DescriptionDeflateStrategy Strategiesfordeflater

SharpZipCompressionLibrary

ThisistheDeflaterclass.ThedeflaterclasscompressesinputwiththedeflatealgorithmdescribedinRFC1951.Ithasseveralcompressionlevelsandthreedifferentstrategiesdescribedbelow.Thisclassisnotthreadsafe.ThisisinherentintheAPI,duetothesplitofdeflateandsetInput.authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeDeflaterMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.Deflater

publicclassDeflater

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterClass

SharpZipCompressionLibrary

Deflateroverview

PublicStaticFieldsBEST_COMPRESSION Thebestandslowest

compressionlevel.Thistriestofindverylonganddistantstringrepetitions.

BEST_SPEED Theworstbutfastestcompressionlevel.

DEFAULT_COMPRESSION Thedefaultcompressionlevel.

DEFLATED Thecompressionmethod.Thisistheonlymethodsupportedsofar.Thereisnoneedtousethisconstantatall.

NO_COMPRESSION Thislevelwon'tcompressatallbutoutputuncompressedblocks.

PublicInstanceConstructorsDeflater Overloaded.Initializesanew

instanceoftheDeflaterclass.

PublicInstancePropertiesAdler Getsthecurrentadler

checksumofthedatathatwasprocessedsofar.

IsFinished Returnstrueifthestreamwasfinishedandnomoreoutputbytesareavailable.

IsNeedingInput Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethod

DeflaterMembers

canalsoreturntruewhenthestreamwasfinished.

TotalIn Getsthenumberofinputbytesprocessedsofar.

TotalOut Getsthenumberofoutputbytessofar.

PublicInstanceMethodsDeflate Overloaded.Deflatesthecurrentinputblockwith

tothegivenarray.

Equals(inheritedfromObject)

DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthedeflaterwiththecurrentinputblock.Itisanerrortogivemoreinputafterthismethodwascalled.Thismethodmustbecalledtoforceallbytestobeflushed.

Flush Flushesthecurrentinputblock.Furthercallstodeflate()willproduceenoughoutputtoinflateeverythinginthecurrentinputblock.ThisisnotpartofSun'sJDKsoIhavemadeitpackageprivate.ItisusedbyDeflaterOutputStreamtoimplementflush().

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getcurrentcompressionlevel

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Resetsthedeflater.Thedeflateractsafterwardsasifitwasjustcreatedwiththesamecompressionlevelandstrategyasithadbefore.

SetDictionary Overloaded.Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thiscallisequivalentto

setDictionary(dict,0,dict.Length)

.

SetInput Overloaded.Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.IfyoucallsetInputwhenneedsInput()returnsfalse,thepreviousinputthatisstillpendingwillbethrownaway.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.Thiscallisequivalentto

setInput(input,0,input.length)

.

SetLevel Setsthecompressionlevel.Thereisnoguaranteeoftheexactpositionofthechange,butifyoucallthiswhenneedsInputistruethechangeofcompressionlevelwilloccursomewherenearbeforetheendofthesofargiveninput.

SetStrategy Setsthecompressionstrategy.StrategyisoneofDEFAULT_STRATEGY,HUFFMAN_ONLYandFILTERED.Fortheexactpositionwherethestrategyischanged,thesameasforsetLevel()applies.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperform

othercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Createsanewdeflaterwithdefaultcompressionlevel.

OverloadListCreatesanewdeflaterwithdefaultcompressionlevel.

publicDeflater();

Createsanewdeflaterwithgivencompressionlevel.

publicDeflater(int);

Createsanewdeflaterwithgivencompressionlevel.

publicDeflater(int,bool);

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstructor

SharpZipCompressionLibrary

Createsanewdeflaterwithdefaultcompressionlevel.

publicDeflater();

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|DeflaterConstructorOverloadList

DeflaterConstructor()

SharpZipCompressionLibrary

Createsanewdeflaterwithgivencompressionlevel.

publicDeflater(

intlvl

);

Parameterslvl

thecompressionlevel,avaluebetweenNO_COMPRESSIONandBEST_COMPRESSION,orDEFAULT_COMPRESSION.

ExceptionsExceptionType ConditionArgumentOutOfRangeException iflvlisoutofrange.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|DeflaterConstructorOverloadList

DeflaterConstructor(Int32)

SharpZipCompressionLibrary

Createsanewdeflaterwithgivencompressionlevel.

publicDeflater(

intlevel,

boolnoZlibHeaderOrFooter

);

Parameterslevel

thecompressionlevel,avaluebetweenNO_COMPRESSIONandBEST_COMPRESSION.

noZlibHeaderOrFootertrue,ifweshouldsuppresstheZlib/RFC1950headeratthebeginningandtheadlerchecksumattheendoftheoutput.ThisisusefulfortheGZIP/PKZIPformats.

ExceptionsExceptionType ConditionArgumentOutOfRangeException iflvlisoutofrange.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|DeflaterConstructorOverloadList

DeflaterConstructor(Int32,Boolean)

SharpZipCompressionLibrary

ThefieldsoftheDeflaterclassarelistedbelow.ForacompletelistofDeflaterclassmembers,seetheDeflaterMemberstopic.

PublicStaticFieldsBEST_COMPRESSION Thebestandslowest

compressionlevel.Thistriestofindverylonganddistantstringrepetitions.

BEST_SPEED Theworstbutfastestcompressionlevel.

DEFAULT_COMPRESSION Thedefaultcompressionlevel.

DEFLATED Thecompressionmethod.Thisistheonlymethodsupportedsofar.Thereisnoneedtousethisconstantatall.

NO_COMPRESSION Thislevelwon'tcompressatallbutoutputuncompressedblocks.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterFields

SharpZipCompressionLibrary

Thebestandslowestcompressionlevel.Thistriestofindverylonganddistantstringrepetitions.

publicstaticintBEST_COMPRESSION;

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.BEST_COMPRESSIONField

SharpZipCompressionLibrary

Theworstbutfastestcompressionlevel.

publicstaticintBEST_SPEED;

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.BEST_SPEEDField

SharpZipCompressionLibrary

Thedefaultcompressionlevel.

publicstaticintDEFAULT_COMPRESSION;

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.DEFAULT_COMPRESSIONField

SharpZipCompressionLibrary

Thecompressionmethod.Thisistheonlymethodsupportedsofar.Thereisnoneedtousethisconstantatall.

publicstaticintDEFLATED;

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.DEFLATEDField

SharpZipCompressionLibrary

Thislevelwon'tcompressatallbutoutputuncompressedblocks.

publicstaticintNO_COMPRESSION;

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.NO_COMPRESSIONField

SharpZipCompressionLibrary

ThepropertiesoftheDeflaterclassarelistedbelow.ForacompletelistofDeflaterclassmembers,seetheDeflaterMemberstopic.

PublicInstancePropertiesAdler Getsthecurrentadler

checksumofthedatathatwasprocessedsofar.

IsFinished Returnstrueifthestreamwasfinishedandnomoreoutputbytesareavailable.

IsNeedingInput Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethodcanalsoreturntruewhenthestreamwasfinished.

TotalIn Getsthenumberofinputbytesprocessedsofar.

TotalOut Getsthenumberofoutputbytessofar.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterProperties

SharpZipCompressionLibrary

Getsthecurrentadlerchecksumofthedatathatwasprocessedsofar.

publicintAdler{get;}

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.AdlerProperty

SharpZipCompressionLibrary

Returnstrueifthestreamwasfinishedandnomoreoutputbytesareavailable.

publicboolIsFinished{get;}

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.IsFinishedProperty

SharpZipCompressionLibrary

Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethodcanalsoreturntruewhenthestreamwasfinished.

publicboolIsNeedingInput{get;}

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.IsNeedingInputProperty

SharpZipCompressionLibrary

Getsthenumberofinputbytesprocessedsofar.

publicintTotalIn{get;}

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.TotalInProperty

SharpZipCompressionLibrary

Getsthenumberofoutputbytessofar.

publiclongTotalOut{get;}

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.TotalOutProperty

SharpZipCompressionLibrary

ThemethodsoftheDeflaterclassarelistedbelow.ForacompletelistofDeflaterclassmembers,seetheDeflaterMemberstopic.

PublicInstanceMethodsDeflate Overloaded.Deflatesthecurrentinputblockwith

tothegivenarray.

Equals(inheritedfromObject)

DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthedeflaterwiththecurrentinputblock.Itisanerrortogivemoreinputafterthismethodwascalled.Thismethodmustbecalledtoforceallbytestobeflushed.

Flush Flushesthecurrentinputblock.Furthercallstodeflate()willproduceenoughoutputtoinflateeverythinginthecurrentinputblock.ThisisnotpartofSun'sJDKsoIhavemadeitpackageprivate.ItisusedbyDeflaterOutputStreamtoimplementflush().

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLevel Getcurrentcompressionlevel

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Resetsthedeflater.Thedeflateractsafterwardsasifitwasjustcreatedwiththesamecompressionlevelandstrategyasithadbefore.

SetDictionary Overloaded.Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thiscallisequivalentto

DeflaterMethods

setDictionary(dict,0,dict.Length)

.

SetInput Overloaded.Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.IfyoucallsetInputwhenneedsInput()returnsfalse,thepreviousinputthatisstillpendingwillbethrownaway.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.Thiscallisequivalentto

setInput(input,0,input.length)

.

SetLevel Setsthecompressionlevel.Thereisnoguaranteeoftheexactpositionofthechange,butifyoucallthiswhenneedsInputistruethechangeofcompressionlevelwilloccursomewherenearbeforetheendofthesofargiveninput.

SetStrategy Setsthecompressionstrategy.StrategyisoneofDEFAULT_STRATEGY,HUFFMAN_ONLYandFILTERED.Fortheexactpositionwherethestrategyischanged,thesameasforsetLevel()applies.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Deflatesthecurrentinputblockwithtothegivenarray.

OverloadListDeflatesthecurrentinputblockwithtothegivenarray.

publicintDeflate(byte[]);

Deflatesthecurrentinputblocktothegivenarray.

publicintDeflate(byte[],int,int);

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.DeflateMethod

SharpZipCompressionLibrary

Deflatesthecurrentinputblockwithtothegivenarray.

publicintDeflate(

byte[]output

);

Parametersoutput

Thebufferwherecompresseddataisstored

ReturnValueThenumberofcompressedbytesaddedtotheoutput,or0ifeitherneedsInput()orfinished()returnstrueorlengthiszero.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.DeflateOverloadList

Deflater.DeflateMethod(Byte[])

SharpZipCompressionLibrary

Deflatesthecurrentinputblocktothegivenarray.

publicintDeflate(

byte[]output,

intoffset,

intlength

);

Parametersoutput

Buffertostorethecompresseddata.

offsetOffsetintotheoutputarray.

lengthThemaximumnumberofbytesthatmaybestored.

ReturnValueThenumberofcompressedbytesaddedtotheoutput,or0ifeitherneedsInput()orfinished()returnstrueorlengthiszero.

ExceptionsExceptionType ConditionInvalidOperationException Ifend()waspreviouslycalled.

ArgumentOutOfRangeException Ifoffsetand/orlengthdon'tmatchthearraylength.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.DeflateOverloadList

Deflater.DeflateMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Finishesthedeflaterwiththecurrentinputblock.Itisanerrortogivemoreinputafterthismethodwascalled.Thismethodmustbecalledtoforceallbytestobeflushed.

publicvoidFinish();

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.FinishMethod

SharpZipCompressionLibrary

Flushesthecurrentinputblock.Furthercallstodeflate()willproduceenoughoutputtoinflateeverythinginthecurrentinputblock.ThisisnotpartofSun'sJDKsoIhavemadeitpackageprivate.ItisusedbyDeflaterOutputStreamtoimplementflush().

publicvoidFlush();

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.FlushMethod

SharpZipCompressionLibrary

Getcurrentcompressionlevel

publicintGetLevel();

ReturnValueReturnsthecurrentcompressionlevel

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.GetLevelMethod

SharpZipCompressionLibrary

Resetsthedeflater.Thedeflateractsafterwardsasifitwasjustcreatedwiththesamecompressionlevelandstrategyasithadbefore.

publicvoidReset();

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.ResetMethod

SharpZipCompressionLibrary

Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thiscallisequivalentto

setDictionary(dict,0,dict.Length)

.

OverloadListSetsthedictionarywhichshouldbeusedinthedeflateprocess.Thiscallisequivalentto

setDictionary(dict,0,dict.Length)

.

publicvoidSetDictionary(byte[]);

Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thedictionaryisabytearraycontainingstringsthatarelikelytooccurinthedatawhichshouldbecompressed.Thedictionaryisnotstoredinthecompressedoutput,onlyachecksum.Todecompresstheoutputyouneedtosupplythesamedictionaryagain.

publicvoidSetDictionary(byte[],int,int);

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.SetDictionaryMethod

SharpZipCompressionLibrary

Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thiscallisequivalentto

setDictionary(dict,0,dict.Length)

.

publicvoidSetDictionary(

byte[]dict

);

Parametersdict

thedictionary.

ExceptionsExceptionType ConditionInvalidOperationException ifsetInput()ordeflate()were

alreadycalledoranotherdictionarywasalreadyset.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.SetDictionaryOverloadList

Deflater.SetDictionaryMethod(Byte[])

SharpZipCompressionLibrary

Setsthedictionarywhichshouldbeusedinthedeflateprocess.Thedictionaryisabytearraycontainingstringsthatarelikelytooccurinthedatawhichshouldbecompressed.Thedictionaryisnotstoredinthecompressedoutput,onlyachecksum.Todecompresstheoutputyouneedtosupplythesamedictionaryagain.

publicvoidSetDictionary(

byte[]dict,

intoffset,

intlength

);

Parametersdict

Thedictionarydata

offsetAnoffsetintothedictionary.

lengthThelengthofthedictionarydatatouse

ExceptionsExceptionType ConditionInvalidOperationException IfsetInput()ordeflate()were

alreadycalledoranotherdictionarywasalreadyset.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.SetDictionaryOverloadList

Deflater.SetDictionaryMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.IfyoucallsetInputwhenneedsInput()returnsfalse,thepreviousinputthatisstillpendingwillbethrownaway.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.Thiscallisequivalentto

setInput(input,0,input.length)

.

OverloadListSetsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.IfyoucallsetInputwhenneedsInput()returnsfalse,thepreviousinputthatisstillpendingwillbethrownaway.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.Thiscallisequivalentto

setInput(input,0,input.length)

.

publicvoidSetInput(byte[]);

Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.

publicvoidSetInput(byte[],int,int);

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.SetInputMethod

SharpZipCompressionLibrary

Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.IfyoucallsetInputwhenneedsInput()returnsfalse,thepreviousinputthatisstillpendingwillbethrownaway.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.Thiscallisequivalentto

setInput(input,0,input.length)

.

publicvoidSetInput(

byte[]input

);

Parametersinput

thebuffercontainingtheinputdata.

ExceptionsExceptionType ConditionInvalidOperationException ifthebufferwasfinished()or

ended().

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.SetInputOverloadList

Deflater.SetInputMethod(Byte[])

SharpZipCompressionLibrary

Setsthedatawhichshouldbecompressednext.ThisshouldbeonlycalledwhenneedsInputindicatesthatmoreinputisneeded.Thegivenbytearrayshouldnotbechanged,beforeneedsInput()returnstrueagain.

publicvoidSetInput(

byte[]input,

intoff,

intlen

);

Parametersinput

thebuffercontainingtheinputdata.

offthestartofthedata.

lenthelengthofthedata.

ExceptionsExceptionType ConditionInvalidOperationException ifthebufferwasfinished()or

ended()orifpreviousinputisstillpending.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Deflater.SetInputOverloadList

Deflater.SetInputMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Setsthecompressionlevel.Thereisnoguaranteeoftheexactpositionofthechange,butifyoucallthiswhenneedsInputistruethechangeofcompressionlevelwilloccursomewherenearbeforetheendofthesofargiveninput.

publicvoidSetLevel(

intlvl

);

Parameterslvl

thenewcompressionlevel.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.SetLevelMethod

SharpZipCompressionLibrary

Setsthecompressionstrategy.StrategyisoneofDEFAULT_STRATEGY,HUFFMAN_ONLYandFILTERED.Fortheexactpositionwherethestrategyischanged,thesameasforsetLevel()applies.

publicvoidSetStrategy(

DeflateStrategystrategy

);

Parametersstrategy

Thenewcompressionstrategy.

SeeAlsoDeflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Deflater.SetStrategyMethod

SharpZipCompressionLibrary

Thisclasscontainsconstantsusedfordeflation.

Foralistofallmembersofthistype,seeDeflaterConstantsMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.DeflaterConstantsICSharpCode.SharpZipLib.Zip.Compression.DeflaterEngine

publicclassDeflaterConstants

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterConstantsMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstantsClass

SharpZipCompressionLibrary

DeflaterConstantsoverview

PublicStaticFieldsCOMPR_FUNC Internalcompressionengine

constant

DEBUGGING Settotruetoenabledebugging

DEFAULT_MEM_LEVEL SetsinternalbuffersizesforHuffmanencoding

DEFLATE_FAST Internalcompressionengineconstant

DEFLATE_SLOW Internalcompressionengineconstant

DEFLATE_STORED Internalcompressionengineconstant

DYN_TREES IdentifiesdynamictreeinZipfile

GOOD_LENGTH Internalcompressionengineconstant

HASH_BITS Internalcompressionengineconstant

HASH_MASK Internalcompressionengineconstant

HASH_SHIFT Internalcompressionengineconstant

HASH_SIZE Internalcompressionengineconstant

MAX_BLOCK_SIZE Internalcompressionengineconstant

MAX_CHAIN Internalcompressionengineconstant

MAX_DIST Internalcompressionengine

DeflaterConstantsMembers

constant

MAX_LAZY Internalcompressionengineconstant

MAX_MATCH Internalcompressionengineconstant

MAX_WBITS Internalcompressionengineconstant

MIN_LOOKAHEAD Internalcompressionengineconstant

MIN_MATCH Internalcompressionengineconstant

NICE_LENGTH Internalcompressionengineconstant

PENDING_BUF_SIZE Internalcompressionengineconstant

PRESET_DICT Headerflagindicatingapresetdictionaryfordeflation

STATIC_TREES IdentifiesstatictreeinZipfile

STORED_BLOCK WrittentoZipfiletoidentifyastoredblock

WMASK Internalcompressionengineconstant

WSIZE Internalcompressionengineconstant

PublicInstanceConstructorsDeflaterConstants

ConstructorInitializesanewinstanceoftheDeflaterConstantsclass.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothe

currentObject.GetHashCode(inheritedfrom

Object)Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheDeflaterConstantsclass.

publicDeflaterConstants();

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstantsConstructor

SharpZipCompressionLibrary

ThefieldsoftheDeflaterConstantsclassarelistedbelow.ForacompletelistofDeflaterConstantsclassmembers,seetheDeflaterConstantsMemberstopic.

PublicStaticFieldsCOMPR_FUNC Internalcompressionengine

constant

DEBUGGING Settotruetoenabledebugging

DEFAULT_MEM_LEVEL SetsinternalbuffersizesforHuffmanencoding

DEFLATE_FAST Internalcompressionengineconstant

DEFLATE_SLOW Internalcompressionengineconstant

DEFLATE_STORED Internalcompressionengineconstant

DYN_TREES IdentifiesdynamictreeinZipfile

GOOD_LENGTH Internalcompressionengineconstant

HASH_BITS Internalcompressionengineconstant

HASH_MASK Internalcompressionengineconstant

HASH_SHIFT Internalcompressionengineconstant

HASH_SIZE Internalcompressionengineconstant

MAX_BLOCK_SIZE Internalcompressionengineconstant

MAX_CHAIN Internalcompressionengine

DeflaterConstantsFields

constant

MAX_DIST Internalcompressionengineconstant

MAX_LAZY Internalcompressionengineconstant

MAX_MATCH Internalcompressionengineconstant

MAX_WBITS Internalcompressionengineconstant

MIN_LOOKAHEAD Internalcompressionengineconstant

MIN_MATCH Internalcompressionengineconstant

NICE_LENGTH Internalcompressionengineconstant

PENDING_BUF_SIZE Internalcompressionengineconstant

PRESET_DICT Headerflagindicatingapresetdictionaryfordeflation

STATIC_TREES IdentifiesstatictreeinZipfile

STORED_BLOCK WrittentoZipfiletoidentifyastoredblock

WMASK Internalcompressionengineconstant

WSIZE Internalcompressionengineconstant

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticint[]COMPR_FUNC;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.COMPR_FUNCField

SharpZipCompressionLibrary

Settotruetoenabledebugging

publicconstboolDEBUGGING=False;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DEBUGGINGField

SharpZipCompressionLibrary

SetsinternalbuffersizesforHuffmanencoding

publicconstintDEFAULT_MEM_LEVEL=8;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DEFAULT_MEM_LEVELField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintDEFLATE_FAST=1;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DEFLATE_FASTField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintDEFLATE_SLOW=2;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DEFLATE_SLOWField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintDEFLATE_STORED=0;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DEFLATE_STOREDField

SharpZipCompressionLibrary

IdentifiesdynamictreeinZipfile

publicconstintDYN_TREES=2;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.DYN_TREESField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticint[]GOOD_LENGTH;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.GOOD_LENGTHField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintHASH_BITS=15;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.HASH_BITSField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintHASH_MASK=32767;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.HASH_MASKField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintHASH_SHIFT=5;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.HASH_SHIFTField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintHASH_SIZE=32768;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.HASH_SIZEField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticintMAX_BLOCK_SIZE;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_BLOCK_SIZEField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticint[]MAX_CHAIN;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_CHAINField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintMAX_DIST=32506;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_DISTField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticint[]MAX_LAZY;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_LAZYField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintMAX_MATCH=258;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_MATCHField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintMAX_WBITS=15;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MAX_WBITSField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintMIN_LOOKAHEAD=262;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MIN_LOOKAHEADField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintMIN_MATCH=3;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.MIN_MATCHField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicstaticint[]NICE_LENGTH;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.NICE_LENGTHField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintPENDING_BUF_SIZE=65536;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.PENDING_BUF_SIZEField

SharpZipCompressionLibrary

Headerflagindicatingapresetdictionaryfordeflation

publicconstintPRESET_DICT=32;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.PRESET_DICTField

SharpZipCompressionLibrary

IdentifiesstatictreeinZipfile

publicconstintSTATIC_TREES=1;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.STATIC_TREESField

SharpZipCompressionLibrary

WrittentoZipfiletoidentifyastoredblock

publicconstintSTORED_BLOCK=0;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.STORED_BLOCKField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintWMASK=32767;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.WMASKField

SharpZipCompressionLibrary

Internalcompressionengineconstant

publicconstintWSIZE=32768;

SeeAlsoDeflaterConstantsClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterConstants.WSIZEField

SharpZipCompressionLibrary

Lowlevelcompressionenginefordeflatealgorithmwhichusesa32KslidingwindowwithsecondarycompressionfromHuffman/Shannon-Fanocodes.

Foralistofallmembersofthistype,seeDeflaterEngineMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.DeflaterConstantsICSharpCode.SharpZipLib.Zip.Compression.DeflaterEngine

publicclassDeflaterEngine:

DeflaterConstants

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterEngineMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngineClass

SharpZipCompressionLibrary

DeflaterEngineoverview

PublicInstanceConstructorsDeflaterEngineConstructor Constructinstancewithpending

buffer

PublicInstancePropertiesAdler GetcurrentvalueofAdler

checksum

Strategy Get/setthedeflatestrategy

TotalIn Totaldataprocessed

PublicInstanceMethodsDeflate Deflatedrivesactual

compressionofdata

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FillWindow Fillthewindow

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

NeedsInput ReturntrueifinputisneededviaSetInput

Reset Resetinternalstate

ResetAdler ResetAdlerchecksum

SetDictionary Setcompressiondictionary

DeflaterEngineMembers

SetInput Setsinputdatatobedeflated.Shouldonlybecalledwhen

NeedsInput()

returnstrue

SetLevel Setthedeflatelevel(0-9)

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Constructinstancewithpendingbuffer

publicDeflaterEngine(

DeflaterPendingpending

);

Parameterspending

Pendingbuffertouse

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngineConstructor

SharpZipCompressionLibrary

ThepropertiesoftheDeflaterEngineclassarelistedbelow.ForacompletelistofDeflaterEngineclassmembers,seetheDeflaterEngineMemberstopic.

PublicInstancePropertiesAdler GetcurrentvalueofAdler

checksum

Strategy Get/setthedeflatestrategy

TotalIn Totaldataprocessed

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngineProperties

SharpZipCompressionLibrary

GetcurrentvalueofAdlerchecksum

publicintAdler{get;}

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.AdlerProperty

SharpZipCompressionLibrary

Get/setthedeflatestrategy

publicDeflateStrategyStrategy{get;set;}

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.StrategyProperty

SharpZipCompressionLibrary

Totaldataprocessed

publicintTotalIn{get;}

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.TotalInProperty

SharpZipCompressionLibrary

ThemethodsoftheDeflaterEngineclassarelistedbelow.ForacompletelistofDeflaterEngineclassmembers,seetheDeflaterEngineMemberstopic.

PublicInstanceMethodsDeflate Deflatedrivesactual

compressionofdata

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FillWindow Fillthewindow

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

NeedsInput ReturntrueifinputisneededviaSetInput

Reset Resetinternalstate

ResetAdler ResetAdlerchecksum

SetDictionary Setcompressiondictionary

SetInput Setsinputdatatobedeflated.Shouldonlybecalledwhen

NeedsInput()

returnstrue

SetLevel Setthedeflatelevel(0-9)

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

DeflaterEngineMethods

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Deflatedrivesactualcompressionofdata

publicboolDeflate(

boolflush,

boolfinish

);

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.DeflateMethod

SharpZipCompressionLibrary

Fillthewindow

publicvoidFillWindow();

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.FillWindowMethod

SharpZipCompressionLibrary

ReturntrueifinputisneededviaSetInput

publicboolNeedsInput();

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.NeedsInputMethod

SharpZipCompressionLibrary

Resetinternalstate

publicvoidReset();

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.ResetMethod

SharpZipCompressionLibrary

ResetAdlerchecksum

publicvoidResetAdler();

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.ResetAdlerMethod

SharpZipCompressionLibrary

Setcompressiondictionary

publicvoidSetDictionary(

byte[]buffer,

intoffset,

intlength

);

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.SetDictionaryMethod

SharpZipCompressionLibrary

Setsinputdatatobedeflated.Shouldonlybecalledwhen

NeedsInput()

returnstrue

publicvoidSetInput(

byte[]buf,

intoff,

intlen

);

Parametersbuf

Thebuffercontaininginputdata.

offTheindexofthefirstbyteofdata.

lenThenumberofbytesofdatatouseasinput.

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.SetInputMethod

SharpZipCompressionLibrary

Setthedeflatelevel(0-9)

publicvoidSetLevel(

intlvl

);

SeeAlsoDeflaterEngineClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterEngine.SetLevelMethod

SharpZipCompressionLibrary

ThisistheDeflaterHuffmanclass.Thisclassisnotthreadsafe.ThisisinherentintheAPI,duetothesplitofdeflateandsetInput.authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeDeflaterHuffmanMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.DeflaterHuffman

publicclassDeflaterHuffman

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterHuffmanMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffmanClass

SharpZipCompressionLibrary

DeflaterHuffmanoverview

PublicStaticMethodsBitReverse Reversethebitsofa16bit

value.

PublicInstanceConstructorsDeflaterHuffmanConstructor Constructinstancewithpending

buffer

PublicInstanceFieldspending Pendingbuffertouse

PublicInstanceMethodsCompressBlock Compresscurrentbufferwriting

datatopendingbuffer

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FlushBlock Flushblocktooutputwithcompression

FlushStoredBlock Flushblocktooutputwithnocompression

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsFull Getvalueindicatingifinternalbufferisfull

DeflaterHuffmanMembers

Reset Resetinternalstate

SendAllTrees Writealltreestopendingbuffer

TallyDist Adddistancecodeandlengthtoliteralanddistancetrees

TallyLit Addliteraltobuffer

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Constructinstancewithpendingbuffer

publicDeflaterHuffman(

DeflaterPendingpending

);

Parameterspending

Pendingbuffertouse

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffmanConstructor

SharpZipCompressionLibrary

ThefieldsoftheDeflaterHuffmanclassarelistedbelow.ForacompletelistofDeflaterHuffmanclassmembers,seetheDeflaterHuffmanMemberstopic.

PublicInstanceFieldspending Pendingbuffertouse

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffmanFields

SharpZipCompressionLibrary

Pendingbuffertouse

publicDeflaterPendingpending;

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.pendingField

SharpZipCompressionLibrary

ThemethodsoftheDeflaterHuffmanclassarelistedbelow.ForacompletelistofDeflaterHuffmanclassmembers,seetheDeflaterHuffmanMemberstopic.

PublicStaticMethodsBitReverse Reversethebitsofa16bit

value.

PublicInstanceMethodsCompressBlock Compresscurrentbufferwriting

datatopendingbuffer

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

FlushBlock Flushblocktooutputwithcompression

FlushStoredBlock Flushblocktooutputwithnocompression

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

IsFull Getvalueindicatingifinternalbufferisfull

Reset Resetinternalstate

SendAllTrees Writealltreestopendingbuffer

TallyDist Adddistancecodeandlengthtoliteralanddistancetrees

TallyLit Addliteraltobuffer

DeflaterHuffmanMethods

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Reversethebitsofa16bitvalue.

publicstaticshortBitReverse(

inttoReverse

);

ParameterstoReverse

Valuetoreversebits

ReturnValueValuewithbitsreversed

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.BitReverseMethod

SharpZipCompressionLibrary

Compresscurrentbufferwritingdatatopendingbuffer

publicvoidCompressBlock();

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.CompressBlockMethod

SharpZipCompressionLibrary

Flushblocktooutputwithcompression

publicvoidFlushBlock(

byte[]stored,

intstoredOffset,

intstoredLength,

boollastBlock

);

Parametersstored

Datatoflush

storedOffsetIndexoffirstbytetoflush

storedLengthCountofbytestoflush

lastBlockTrueifthisisthelastblock

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.FlushBlockMethod

SharpZipCompressionLibrary

Flushblocktooutputwithnocompression

publicvoidFlushStoredBlock(

byte[]stored,

intstoredOffset,

intstoredLength,

boollastBlock

);

Parametersstored

Datatowrite

storedOffsetIndexoffirstbytetowrite

storedLengthCountofbytestowrite

lastBlockTrueifthisisthelastblock

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.FlushStoredBlockMethod

SharpZipCompressionLibrary

Getvalueindicatingifinternalbufferisfull

publicboolIsFull();

ReturnValuetrueifbufferisfull

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.IsFullMethod

SharpZipCompressionLibrary

Resetinternalstate

publicvoidReset();

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.ResetMethod

SharpZipCompressionLibrary

Writealltreestopendingbuffer

publicvoidSendAllTrees(

intblTreeCodes

);

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.SendAllTreesMethod

SharpZipCompressionLibrary

Adddistancecodeandlengthtoliteralanddistancetrees

publicboolTallyDist(

intdist,

intlen

);

Parametersdist

Distancecode

lenLength

ReturnValueValueindicatingifinternalbufferisfull

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.TallyDistMethod

SharpZipCompressionLibrary

Addliteraltobuffer

publicboolTallyLit(

intlit

);

Parameterslit

ReturnValueValueindicatinginternalbufferisfull

SeeAlsoDeflaterHuffmanClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.TallyLitMethod

SharpZipCompressionLibrary

Notdocumented

Foralistofallmembersofthistype,seeDeflaterHuffman.TreeMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.DeflaterHuffman.Tree

publicclassDeflaterHuffman.Tree

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterHuffman.TreeMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.TreeClass

SharpZipCompressionLibrary

DeflaterHuffman.Treeoverview

PublicInstanceConstructorsDeflaterHuffman.Tree

ConstructorNotdocumented

PublicInstanceFieldsfreqs Notdocumented

length Notdocumented

minNumCodes Notdocumented

numCodes Notdocumented

PublicInstanceMethodsBuildCodes Builddynamiccodesand

lengths

BuildTree Notdocumented

CalcBLFreq Notdocumented

CheckEmpty Checkthatatleastonefrequencyisnon-zero

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetEncodedLength Getencodedlength

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Resetstheinternalstateofthe

DeflaterHuffman.TreeMembers

tree

SetStaticCodes Setstaticcodesandlength

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteSymbol Notdocumented

WriteTree Writetreevalues

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Notdocumented

publicDeflaterHuffman.Tree(

DeflaterHuffmandh,

intelems,

intminCodes,

intmaxLength

);

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.TreeConstructor

SharpZipCompressionLibrary

ThefieldsoftheDeflaterHuffman.Treeclassarelistedbelow.ForacompletelistofDeflaterHuffman.Treeclassmembers,seetheDeflaterHuffman.TreeMemberstopic.

PublicInstanceFieldsfreqs Notdocumented

length Notdocumented

minNumCodes Notdocumented

numCodes Notdocumented

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.TreeFields

SharpZipCompressionLibrary

Notdocumented

publicshort[]freqs;

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.freqsField

SharpZipCompressionLibrary

Notdocumented

publicbyte[]length;

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.lengthField

SharpZipCompressionLibrary

Notdocumented

publicintminNumCodes;

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.minNumCodesField

SharpZipCompressionLibrary

Notdocumented

publicintnumCodes;

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.numCodesField

SharpZipCompressionLibrary

ThemethodsoftheDeflaterHuffman.Treeclassarelistedbelow.ForacompletelistofDeflaterHuffman.Treeclassmembers,seetheDeflaterHuffman.TreeMemberstopic.

PublicInstanceMethodsBuildCodes Builddynamiccodesand

lengths

BuildTree Notdocumented

CalcBLFreq Notdocumented

CheckEmpty Checkthatatleastonefrequencyisnon-zero

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetEncodedLength Getencodedlength

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Resetstheinternalstateofthetree

SetStaticCodes Setstaticcodesandlength

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteSymbol Notdocumented

WriteTree Writetreevalues

ProtectedInstanceMethods

DeflaterHuffman.TreeMethods

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Builddynamiccodesandlengths

publicvoidBuildCodes();

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.BuildCodesMethod

SharpZipCompressionLibrary

Notdocumented

publicvoidBuildTree();

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.BuildTreeMethod

SharpZipCompressionLibrary

Notdocumented

publicvoidCalcBLFreq(

TreeblTree

);

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.CalcBLFreqMethod

SharpZipCompressionLibrary

Checkthatatleastonefrequencyisnon-zero

publicvoidCheckEmpty();

ExceptionsExceptionType ConditionSharpZipBaseException Nofrequenciesarenon-zero

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.CheckEmptyMethod

SharpZipCompressionLibrary

Getencodedlength

publicintGetEncodedLength();

ReturnValueEncodedlength,thesumoffrequencies*lengths

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.GetEncodedLengthMethod

SharpZipCompressionLibrary

Resetstheinternalstateofthetree

publicvoidReset();

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.ResetMethod

SharpZipCompressionLibrary

Setstaticcodesandlength

publicvoidSetStaticCodes(

short[]stCodes,

byte[]stLength

);

ParametersstCodes

newcodes

stLengthlengthfornewcodes

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.SetStaticCodesMethod

SharpZipCompressionLibrary

Notdocumented

publicvoidWriteSymbol(

intcode

);

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.WriteSymbolMethod

SharpZipCompressionLibrary

Writetreevalues

publicvoidWriteTree(

TreeblTree

);

ParametersblTree

Treetowrite

SeeAlsoDeflaterHuffman.TreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterHuffman.Tree.WriteTreeMethod

SharpZipCompressionLibrary

ThisclassstoresthependingoutputoftheDeflater.authoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seeDeflaterPendingMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.PendingBufferICSharpCode.SharpZipLib.Zip.Compression.DeflaterPending

publicclassDeflaterPending:

PendingBuffer

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterPendingMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterPendingClass

SharpZipCompressionLibrary

DeflaterPendingoverview

PublicInstanceConstructorsDeflaterPendingConstructor Constructinstancewithdefault

buffersize

PublicInstancePropertiesBitCount(inheritedfrom

PendingBuffer)Thenumberofbitswrittentothebuffer

IsFlushed(inheritedfromPendingBuffer)

Indicatesifbufferhasbeenflushed

PublicInstanceMethodsAlignToByte(inheritedfrom

PendingBuffer)Aligninternalbufferonabyteboundary

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush(inheritedfromPendingBuffer)

Flushesthependingbufferintothegivenoutputarray.Iftheoutputarrayistosmall,onlyapartialflushisdone.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset(inheritedfromPendingBuffer)

Clearinternalstate/buffers

ToByteArray(inheritedfromPendingBuffer)

Convertinternalbuffertobytearray.Bufferisemptyon

DeflaterPendingMembers

completion

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteBits(inheritedfromPendingBuffer)

Writebitstointernalbuffer

WriteBlock(inheritedfromPendingBuffer)

Writeablockofdatatobuffer

WriteByte(inheritedfromPendingBuffer)

writeabytetobuffer

WriteInt(inheritedfromPendingBuffer)

writeanintegerLSBfirst

WriteShort(inheritedfromPendingBuffer)

WriteashortvaluetobufferLSBfirst

WriteShortMSB(inheritedfromPendingBuffer)

Writeashortvaluetointernalbuffermostsignificantbytefirst

ProtectedInstanceFieldsbuf(inheritedfrom

PendingBuffer)Internalworkbuffer

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoDeflaterPendingClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Constructinstancewithdefaultbuffersize

publicDeflaterPending();

SeeAlsoDeflaterPendingClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflaterPendingConstructor

SharpZipCompressionLibrary

Strategiesfordeflater

publicenumDeflateStrategy

MembersMemberName DescriptionDefault Thedefaultstrategy

Filtered Thisstrategywillonlyallowlongerstringrepetitions.Itisusefulforrandomdatawithasmallcharacterset.

HuffmanOnly Thisstrategywillnotlookforstringrepetitionsatall.ItonlyencodeswithHuffmantrees(whichmeans,thatmorecommoncharactersgetasmallerencoding.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoICSharpCode.SharpZipLib.Zip.CompressionNamespace

DeflateStrategyEnumeration

SharpZipCompressionLibrary

Inflaterisusedtodecompressdatathathasbeencompressedaccordingtothe"deflate"standarddescribedinrfc1951.BydefaultZlib(rfc1950)headersandfootersareexpectedintheinput.Youcanuseconstructor

publicInflater(boolnoHeader)

passingtrueifthereisnoZlibheaderinformationTheusageisasfollowing.Firstyouhavetosetsomeinputwith

setInput()

,theninflate()it.Ifinflatedoesn'tinflateanybytestheremaybethreereasons:

needsInput()returnstruebecausetheinputbufferisempty.Youhavetoprovidemoreinputwith

setInput()

.NOTE:needsInput()alsoreturnstruewhen,thestreamisfinished.

needsDictionary()returnstrue,youhavetoprovideapresetdictionarywith

setDictionary()

.

finished()returnstrue,theinflaterhasfinished.

Oncethefirstoutputbyteisproduced,adictionarywillnotbeneededatalaterstage.authoroftheoriginaljavaversion:JohnLeuner,JochenHoenicke

Foralistofallmembersofthistype,seeInflaterMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.Inflater

publicclassInflater

InflaterClass

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoInflaterMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Inflateroverview

PublicInstanceConstructorsInflater Overloaded.Initializesanew

instanceoftheInflaterclass.

PublicInstancePropertiesAdler Getstheadlerchecksum.This

iseitherthechecksumofalluncompressedbytesreturnedbyinflate(),orifneedsDictionary()returnstrue(andthusnooutputwasyetproduced)thisistheadlerchecksumoftheexpecteddictionary.

IsFinished Returnstrue,iftheinflaterhasfinished.Thismeans,thatnoinputisneededandnooutputcanbeproduced.

IsNeedingDictionary Returnstrue,ifapresetdictionaryisneededtoinflatetheinput.

IsNeedingInput Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethodalsoreturnstruewhenthestreamisfinished.

RemainingInput Getsthenumberofunprocessedinputbytes.Useful,iftheendofthestreamisreachedandyouwanttofurtherprocessthebytesafterthedeflatestream.

InflaterMembers

TotalIn Getsthetotalnumberofprocessedcompressedinputbytes.

TotalOut Getsthetotalnumberofoutputbytesreturnedbyinflate().

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Inflate Overloaded.Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

Reset Resetstheinflatersothatanewstreamcanbedecompressed.Allpendinginputandoutputwillbediscarded.

SetDictionary Overloaded.Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksum

ofthedictionaryneeded.

SetInput Overloaded.Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

CreatesanewinflaterorRFC1951decompressorRFC1950/Zlibheadersandfooterswillbeexpectedintheinputdata

OverloadListCreatesanewinflaterorRFC1951decompressorRFC1950/Zlibheadersandfooterswillbeexpectedintheinputdata

publicInflater();

Createsanewinflater.

publicInflater(bool);

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterConstructor

SharpZipCompressionLibrary

CreatesanewinflaterorRFC1951decompressorRFC1950/Zlibheadersandfooterswillbeexpectedintheinputdata

publicInflater();

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|InflaterConstructorOverloadList

InflaterConstructor()

SharpZipCompressionLibrary

Createsanewinflater.

publicInflater(

boolnoHeader

);

ParametersnoHeader

TrueifnoRFC1950/ZlibheaderandfooterfieldsareexpectedintheinputdataThisisusedforGZIPed/Zippedinput.ForcompatibilitywithSunJDKyoushouldprovideonebyteofinputmorethanneededinthiscase.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|InflaterConstructorOverloadList

InflaterConstructor(Boolean)

SharpZipCompressionLibrary

ThepropertiesoftheInflaterclassarelistedbelow.ForacompletelistofInflaterclassmembers,seetheInflaterMemberstopic.

PublicInstancePropertiesAdler Getstheadlerchecksum.This

iseitherthechecksumofalluncompressedbytesreturnedbyinflate(),orifneedsDictionary()returnstrue(andthusnooutputwasyetproduced)thisistheadlerchecksumoftheexpecteddictionary.

IsFinished Returnstrue,iftheinflaterhasfinished.Thismeans,thatnoinputisneededandnooutputcanbeproduced.

IsNeedingDictionary Returnstrue,ifapresetdictionaryisneededtoinflatetheinput.

IsNeedingInput Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethodalsoreturnstruewhenthestreamisfinished.

RemainingInput Getsthenumberofunprocessedinputbytes.Useful,iftheendofthestreamisreachedandyouwanttofurtherprocessthebytesafterthedeflatestream.

TotalIn Getsthetotalnumberofprocessedcompressedinputbytes.

InflaterProperties

TotalOut Getsthetotalnumberofoutputbytesreturnedbyinflate().

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Getstheadlerchecksum.Thisiseitherthechecksumofalluncompressedbytesreturnedbyinflate(),orifneedsDictionary()returnstrue(andthusnooutputwasyetproduced)thisistheadlerchecksumoftheexpecteddictionary.

publicintAdler{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.AdlerProperty

SharpZipCompressionLibrary

Returnstrue,iftheinflaterhasfinished.Thismeans,thatnoinputisneededandnooutputcanbeproduced.

publicboolIsFinished{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.IsFinishedProperty

SharpZipCompressionLibrary

Returnstrue,ifapresetdictionaryisneededtoinflatetheinput.

publicboolIsNeedingDictionary{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.IsNeedingDictionaryProperty

SharpZipCompressionLibrary

Returnstrue,iftheinputbufferisempty.YoushouldthencallsetInput().NOTE:Thismethodalsoreturnstruewhenthestreamisfinished.

publicboolIsNeedingInput{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.IsNeedingInputProperty

SharpZipCompressionLibrary

Getsthenumberofunprocessedinputbytes.Useful,iftheendofthestreamisreachedandyouwanttofurtherprocessthebytesafterthedeflatestream.

publicintRemainingInput{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.RemainingInputProperty

SharpZipCompressionLibrary

Getsthetotalnumberofprocessedcompressedinputbytes.

publicintTotalIn{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.TotalInProperty

SharpZipCompressionLibrary

Getsthetotalnumberofoutputbytesreturnedbyinflate().

publicintTotalOut{get;}

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.TotalOutProperty

SharpZipCompressionLibrary

ThemethodsoftheInflaterclassarelistedbelow.ForacompletelistofInflaterclassmembers,seetheInflaterMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Inflate Overloaded.Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

Reset Resetstheinflatersothatanewstreamcanbedecompressed.Allpendinginputandoutputwillbediscarded.

SetDictionary Overloaded.Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

InflaterMethods

SetInput Overloaded.Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

OverloadListInflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

publicintInflate(byte[]);

Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

publicintInflate(byte[],int,int);

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.InflateMethod

SharpZipCompressionLibrary

Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

publicintInflate(

byte[]buf

);

Parametersbuf

theoutputbuffer.

ReturnValuethenumberofbyteswrittentothebuffer,0ifnofurtheroutputcanbeproduced.

ExceptionsExceptionType ConditionArgumentOutOfRangeException ifbufhaslength0.

FormatException ifdeflatedstreamisinvalid.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Inflater.InflateOverloadList

Inflater.InflateMethod(Byte[])

SharpZipCompressionLibrary

Inflatesthecompressedstreamtotheoutputbuffer.Ifthisreturns0,youshouldcheck,whetherneedsDictionary(),needsInput()orfinished()returnstrue,todeterminewhynofurtheroutputisproduced.

publicintInflate(

byte[]buf,

intoffset,

intlen

);

Parametersbuf

theoutputbuffer.

offsettheoffsetintobufferwheretheoutputshouldstart.

lenthemaximumlengthoftheoutput.

ReturnValuethenumberofbyteswrittentothebuffer,0ifnofurtheroutputcanbeproduced.

ExceptionsExceptionType ConditionArgumentOutOfRangeException iflenis<=0.

ArgumentOutOfRangeException iftheoffsetand/orlenarewrong.

FormatException ifdeflatedstreamisinvalid.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.Compression

Inflater.InflateMethod(Byte[],Int32,Int32)

Namespace|Inflater.InflateOverloadList

SharpZipCompressionLibrary

Resetstheinflatersothatanewstreamcanbedecompressed.Allpendinginputandoutputwillbediscarded.

publicvoidReset();

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.ResetMethod

SharpZipCompressionLibrary

Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

OverloadListSetsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

publicvoidSetDictionary(byte[]);

Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

publicvoidSetDictionary(byte[],int,int);

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.SetDictionaryMethod

SharpZipCompressionLibrary

Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

publicvoidSetDictionary(

byte[]buffer

);

Parametersbuffer

Thedictionary.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Inflater.SetDictionaryOverloadList

Inflater.SetDictionaryMethod(Byte[])

SharpZipCompressionLibrary

Setsthepresetdictionary.Thisshouldonlybecalled,ifneedsDictionary()returnstrueanditshouldsetthesamedictionary,thatwasusedfordeflating.ThegetAdler()functionreturnsthechecksumofthedictionaryneeded.

publicvoidSetDictionary(

byte[]buffer,

intoffset,

intlen

);

Parametersbuffer

Thedictionary.

offsetTheoffsetintobufferwherethedictionarystarts.

lenThelengthofthedictionary.

ExceptionsExceptionType ConditionInvalidOperationException Nodictionaryisneeded.

SharpZipBaseException Theadlerchecksumforthebufferisinvalid

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Inflater.SetDictionaryOverloadList

Inflater.SetDictionaryMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

OverloadListSetstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

publicvoidSetInput(byte[]);

Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

publicvoidSetInput(byte[],int,int);

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

Inflater.SetInputMethod

SharpZipCompressionLibrary

Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

publicvoidSetInput(

byte[]buf

);

Parametersbuf

theinput.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Inflater.SetInputOverloadList

Inflater.SetInputMethod(Byte[])

SharpZipCompressionLibrary

Setstheinput.Thisshouldonlybecalled,ifneedsInput()returnstrue.

publicvoidSetInput(

byte[]buffer,

intoffset,

intlength

);

Parametersbuffer

Thesourceofinputdata

offsetTheoffsetintobufferwheretheinputstarts.

lengthThenumberofbytesofinputtouse.

ExceptionsExceptionType ConditionInvalidOperationException Noinputisneeded.

ArgumentOutOfRangeException Theoffand/orlenarewrong.

SeeAlsoInflaterClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|Inflater.SetInputOverloadList

Inflater.SetInputMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

Huffmantreeusedforinflation

Foralistofallmembersofthistype,seeInflaterHuffmanTreeMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.InflaterHuffmanTree

publicclassInflaterHuffmanTree

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoInflaterHuffmanTreeMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTreeClass

SharpZipCompressionLibrary

InflaterHuffmanTreeoverview

PublicStaticFieldsdefDistTree Distancetree

defLitLenTree Literallengthtree

PublicInstanceConstructorsInflaterHuffmanTree

ConstructorConstructsaHuffmantreefromthearrayofcodelengths.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetSymbol Readsthenextsymbolfrominput.Thesymbolisencodedusingthehuffmantree.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InflaterHuffmanTreeMembers

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

ConstructsaHuffmantreefromthearrayofcodelengths.

publicInflaterHuffmanTree(

byte[]codeLengths

);

ParameterscodeLengths

thearrayofcodelengths

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTreeConstructor

SharpZipCompressionLibrary

ThefieldsoftheInflaterHuffmanTreeclassarelistedbelow.ForacompletelistofInflaterHuffmanTreeclassmembers,seetheInflaterHuffmanTreeMemberstopic.

PublicStaticFieldsdefDistTree Distancetree

defLitLenTree Literallengthtree

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTreeFields

SharpZipCompressionLibrary

Distancetree

publicstaticInflaterHuffmanTreedefDistTree;

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTree.defDistTreeField

SharpZipCompressionLibrary

Literallengthtree

publicstaticInflaterHuffmanTreedefLitLenTree;

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTree.defLitLenTreeField

SharpZipCompressionLibrary

ThemethodsoftheInflaterHuffmanTreeclassarelistedbelow.ForacompletelistofInflaterHuffmanTreeclassmembers,seetheInflaterHuffmanTreeMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetSymbol Readsthenextsymbolfrominput.Thesymbolisencodedusingthehuffmantree.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTreeMethods

SharpZipCompressionLibrary

Readsthenextsymbolfrominput.Thesymbolisencodedusingthehuffmantree.

publicintGetSymbol(

StreamManipulatorinput

);

Parametersinput

inputtheinputsource.

ReturnValuethenextsymbol,or-1ifnotenoughinputisavailable.

SeeAlsoInflaterHuffmanTreeClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

InflaterHuffmanTree.GetSymbolMethod

SharpZipCompressionLibrary

Thisclassisgeneralpurposeclassforwritingdatatoabuffer.ItallowsyoutowritebitsaswellasbytesBasedonDeflaterPending.javaauthoroftheoriginaljavaversion:JochenHoenicke

Foralistofallmembersofthistype,seePendingBufferMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.PendingBufferICSharpCode.SharpZipLib.Zip.Compression.DeflaterPending

publicclassPendingBuffer

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.CompressionAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoPendingBufferMembers|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBufferClass

SharpZipCompressionLibrary

PendingBufferoverview

PublicInstanceConstructorsPendingBuffer Overloaded.Initializesanew

instanceofthePendingBufferclass.

PublicInstancePropertiesBitCount Thenumberofbitswrittentothe

buffer

IsFlushed Indicatesifbufferhasbeenflushed

PublicInstanceMethodsAlignToByte Aligninternalbufferonabyte

boundary

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushesthependingbufferintothegivenoutputarray.Iftheoutputarrayistosmall,onlyapartialflushisdone.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Clearinternalstate/buffers

ToByteArray Convertinternalbuffertobytearray.Bufferisemptyon

PendingBufferMembers

completion

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteBits Writebitstointernalbuffer

WriteBlock Writeablockofdatatobuffer

WriteByte writeabytetobuffer

WriteInt writeanintegerLSBfirst

WriteShort WriteashortvaluetobufferLSBfirst

WriteShortMSB Writeashortvaluetointernalbuffermostsignificantbytefirst

ProtectedInstanceFieldsbuf Internalworkbuffer

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

constructinstanceusingdefaultbuffersizeof4096

OverloadListconstructinstanceusingdefaultbuffersizeof4096

publicPendingBuffer();

constructinstanceusingspecifiedbuffersize

publicPendingBuffer(int);

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBufferConstructor

SharpZipCompressionLibrary

constructinstanceusingdefaultbuffersizeof4096

publicPendingBuffer();

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|PendingBufferConstructorOverloadList

PendingBufferConstructor()

SharpZipCompressionLibrary

constructinstanceusingspecifiedbuffersize

publicPendingBuffer(

intbufsize

);

Parametersbufsize

sizetouseforinternalbuffer

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace|PendingBufferConstructorOverloadList

PendingBufferConstructor(Int32)

SharpZipCompressionLibrary

ThefieldsofthePendingBufferclassarelistedbelow.ForacompletelistofPendingBufferclassmembers,seethePendingBufferMemberstopic.

ProtectedInstanceFieldsbuf Internalworkbuffer

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBufferFields

SharpZipCompressionLibrary

Internalworkbuffer

protectedbyte[]buf;

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.bufField

SharpZipCompressionLibrary

ThepropertiesofthePendingBufferclassarelistedbelow.ForacompletelistofPendingBufferclassmembers,seethePendingBufferMemberstopic.

PublicInstancePropertiesBitCount Thenumberofbitswrittentothe

buffer

IsFlushed Indicatesifbufferhasbeenflushed

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBufferProperties

SharpZipCompressionLibrary

Thenumberofbitswrittentothebuffer

publicintBitCount{get;}

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.BitCountProperty

SharpZipCompressionLibrary

Indicatesifbufferhasbeenflushed

publicboolIsFlushed{get;}

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.IsFlushedProperty

SharpZipCompressionLibrary

ThemethodsofthePendingBufferclassarelistedbelow.ForacompletelistofPendingBufferclassmembers,seethePendingBufferMemberstopic.

PublicInstanceMethodsAlignToByte Aligninternalbufferonabyte

boundary

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush Flushesthependingbufferintothegivenoutputarray.Iftheoutputarrayistosmall,onlyapartialflushisdone.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Reset Clearinternalstate/buffers

ToByteArray Convertinternalbuffertobytearray.Bufferisemptyoncompletion

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

WriteBits Writebitstointernalbuffer

WriteBlock Writeablockofdatatobuffer

WriteByte writeabytetobuffer

WriteInt writeanintegerLSBfirst

PendingBufferMethods

WriteShort WriteashortvaluetobufferLSBfirst

WriteShortMSB Writeashortvaluetointernalbuffermostsignificantbytefirst

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

SharpZipCompressionLibrary

Aligninternalbufferonabyteboundary

publicvoidAlignToByte();

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.AlignToByteMethod

SharpZipCompressionLibrary

Flushesthependingbufferintothegivenoutputarray.Iftheoutputarrayistosmall,onlyapartialflushisdone.

publicintFlush(

byte[]output,

intoffset,

intlength

);

Parametersoutput

theoutputarray;

offsettheoffsetintooutputarray;

lengthlengththemaximumnumberofbytestostore;

ExceptionsExceptionType Condition

IndexOutOfBoundsExceptionifoffsetorlengthareinvalid.

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.FlushMethod

SharpZipCompressionLibrary

Clearinternalstate/buffers

publicvoidReset();

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.ResetMethod

SharpZipCompressionLibrary

Convertinternalbuffertobytearray.Bufferisemptyoncompletion

publicbyte[]ToByteArray();

ReturnValueconvertedbuffercontentscontents

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.ToByteArrayMethod

SharpZipCompressionLibrary

Writebitstointernalbuffer

publicvoidWriteBits(

intb,

intcount

);

Parametersb

sourceofbits

countnumberofbitstowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteBitsMethod

SharpZipCompressionLibrary

Writeablockofdatatobuffer

publicvoidWriteBlock(

byte[]block,

intoffset,

intlen

);

Parametersblock

datatowrite

offsetoffsetoffirstbytetowrite

lennumberofbytestowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteBlockMethod

SharpZipCompressionLibrary

writeabytetobuffer

publicvoidWriteByte(

intb

);

Parametersb

valuetowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteByteMethod

SharpZipCompressionLibrary

writeanintegerLSBfirst

publicvoidWriteInt(

ints

);

Parameterss

valuetowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteIntMethod

SharpZipCompressionLibrary

WriteashortvaluetobufferLSBfirst

publicvoidWriteShort(

ints

);

Parameterss

valuetowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteShortMethod

SharpZipCompressionLibrary

Writeashortvaluetointernalbuffermostsignificantbytefirst

publicvoidWriteShortMSB(

ints

);

Parameterss

valuetowrite

SeeAlsoPendingBufferClass|ICSharpCode.SharpZipLib.Zip.CompressionNamespace

PendingBuffer.WriteShortMSBMethod

SharpZipCompressionLibrary

Namespacehierarchy

ClassesClass DescriptionDeflaterOutputStream Aspecialstreamdeflatingor

compressingthebytesthatarewrittentoit.ItusesaDeflatertoperformactualdeflating.Authorsoftheoriginaljavaversion:TomTromey,JochenHoenicke

InflaterInputBuffer AninputbuffercustomisedforusebyInflaterInputStream

InflaterInputStream Thisfilterstreamisusedtodecompressdatacompressedusingthe"deflate"format.The"deflate"formatisdescribedinRFC1951.Thisstreammayformthebasisforotherdecompressionfilters,suchastheGZipInputStream.Authoroftheoriginaljavaversion:JohnLeuner.

OutputWindow ContainstheoutputfromtheInflationprocess.Weneedtohaveawindowsothatwecanreferbackwardsintotheoutputstreamtorepeatstuff.Authoroftheoriginaljavaversion:JohnLeuner

StreamManipulator Thisclassallowsustoretrieveaspecifiednumberofbitsfrom

ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

theinputbuffer,aswellascopybigbyteblocks.Itusesanintbuffertostoreupto31bitsfordirectmanipulation.Thisguaranteesthatwecangetatleast16bits,butweonlyneedatmost15,sothisisallsafe.Therearesomeoptimizationsinthisclass,forexample,youmustneverpeekmorethan8bitsmorethanneeded,andyoumustfirstpeekbitsbeforeyoumaydropthem.ThisisnotageneralpurposeclassbutoptimizedforthebehaviouroftheInflater.authorsoftheoriginaljavaversion:JohnLeuner,JochenHoenicke

SharpZipCompressionLibrary

Aspecialstreamdeflatingorcompressingthebytesthatarewrittentoit.ItusesaDeflatertoperformactualdeflating.Authorsoftheoriginaljavaversion:TomTromey,JochenHoenicke

Foralistofallmembersofthistype,seeDeflaterOutputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStreamICSharpCode.SharpZipLib.GZip.GZipOutputStreamICSharpCode.SharpZipLib.Zip.ZipOutputStream

publicclassDeflaterOutputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.Compression.StreamsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoDeflaterOutputStreamMembers|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStreamClass

SharpZipCompressionLibrary

DeflaterOutputStreamoverview

PublicInstanceConstructorsDeflaterOutputStream Overloaded.Initializesanew

instanceoftheDeflaterOutputStreamclass.

PublicInstanceProperties

CanPatchEntriesAllowsclienttodetermineifanentrycanbepatchedafteritsadded

CanRead Getsvalueindicatingstreamcanbereadfrom

CanSeek GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

CanWrite Getvalueindicatingifthisstreamsupportswriting

IsStreamOwnerGet/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length Getcurrentlengthofstream

Password Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

Position Thecurrentpositionwithinthestream.AlwaysthrowsaNotSupportedExceptionNotSupportedException

PublicInstanceMethodsBeginRead Asynchronousreadsarenot

supportedaNotSupportedExceptionisalwaysthrown

DeflaterOutputStreamMembers

BeginWrite Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close Callsfinish()andclosestheunderlyingstreamwhenIsStreamOwneristrue.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthestreambycallingfinish()onthedeflater.

Flush Flushesthestreambycallingflush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfrom GetstheTypeofthecurrent

Object) instance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytesfromstream

ReadByte Readabytefromstreamadvancingpositionbyone

Seek Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLength Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesbytesfromanarraytothecompressedstream.

WriteByte Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceFieldsbaseOutputStream Basestreamthedeflater

dependson.

buf Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

def Thedeflaterwhichisusedtodeflatethestream.

ProtectedInstanceMethodsCreateWaitHandle(inherited AllocatesaWaitHandleobject.

fromStream)

Deflate Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock Encryptablockofdata

EncryptByte Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys Updateencryptionkeys

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

CreatesanewDeflaterOutputStreamwithadefaultDeflateranddefaultbuffersize.

OverloadListCreatesanewDeflaterOutputStreamwithadefaultDeflateranddefaultbuffersize.

publicDeflaterOutputStream(Stream);

CreatesanewDeflaterOutputStreamwiththegivenDeflateranddefaultbuffersize.

publicDeflaterOutputStream(Stream,Deflater);

CreatesanewDeflaterOutputStreamwiththegivenDeflaterandbuffersize.

publicDeflaterOutputStream(Stream,Deflater,int);

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStreamConstructor

SharpZipCompressionLibrary

CreatesanewDeflaterOutputStreamwithadefaultDeflateranddefaultbuffersize.

publicDeflaterOutputStream(

StreambaseOutputStream

);

ParametersbaseOutputStream

theoutputstreamwheredeflatedoutputshouldbewritten.

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|DeflaterOutputStreamConstructorOverloadList

DeflaterOutputStreamConstructor(Stream)

SharpZipCompressionLibrary

CreatesanewDeflaterOutputStreamwiththegivenDeflateranddefaultbuffersize.

publicDeflaterOutputStream(

StreambaseOutputStream,

Deflaterdefl

);

ParametersbaseOutputStream

theoutputstreamwheredeflatedoutputshouldbewritten.

defltheunderlyingdeflater.

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|DeflaterOutputStreamConstructorOverloadList

DeflaterOutputStreamConstructor(Stream,Deflater)

SharpZipCompressionLibrary

CreatesanewDeflaterOutputStreamwiththegivenDeflaterandbuffersize.

publicDeflaterOutputStream(

StreambaseOutputStream,

Deflaterdeflater,

intbufsize

);

ParametersbaseOutputStream

Theoutputstreamwheredeflatedoutputiswritten.

deflaterTheunderlyingdeflatertouse

bufsizeThebuffersizetousewhendeflating

ExceptionsExceptionType ConditionArgumentOutOfRangeException bufsizeislessthanorequalto

zero.

ArgumentException baseOutputStreamdoesnotsupportwriting

ArgumentNullException deflaterinstanceisnull

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|DeflaterOutputStreamConstructorOverloadList

DeflaterOutputStreamConstructor(Stream,Deflater,Int32)

SharpZipCompressionLibrary

ThefieldsoftheDeflaterOutputStreamclassarelistedbelow.ForacompletelistofDeflaterOutputStreamclassmembers,seetheDeflaterOutputStreamMemberstopic.

ProtectedInstanceFieldsbaseOutputStream Basestreamthedeflater

dependson.

buf Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

def Thedeflaterwhichisusedtodeflatethestream.

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStreamFields

SharpZipCompressionLibrary

Basestreamthedeflaterdependson.

protectedStreambaseOutputStream;

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.baseOutputStreamField

SharpZipCompressionLibrary

Thisbufferisusedtemporarilytoretrievethebytesfromthedeflaterandwritethemtotheunderlyingoutputstream.

protectedbyte[]buf;

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.bufField

SharpZipCompressionLibrary

Thedeflaterwhichisusedtodeflatethestream.

protectedDeflaterdef;

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.defField

SharpZipCompressionLibrary

ThepropertiesoftheDeflaterOutputStreamclassarelistedbelow.ForacompletelistofDeflaterOutputStreamclassmembers,seetheDeflaterOutputStreamMemberstopic.

PublicInstanceProperties

CanPatchEntriesAllowsclienttodetermineifanentrycanbepatchedafteritsadded

CanRead Getsvalueindicatingstreamcanbereadfrom

CanSeek GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

CanWrite Getvalueindicatingifthisstreamsupportswriting

IsStreamOwnerGet/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length Getcurrentlengthofstream

Password Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

Position Thecurrentpositionwithinthestream.AlwaysthrowsaNotSupportedExceptionNotSupportedException

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStreamProperties

SharpZipCompressionLibrary

Allowsclienttodetermineifanentrycanbepatchedafteritsadded

publicboolCanPatchEntries{get;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.CanPatchEntriesProperty

SharpZipCompressionLibrary

Getsvalueindicatingstreamcanbereadfrom

publicoverrideboolCanRead{get;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.CanReadProperty

SharpZipCompressionLibrary

GetsavalueindicatingifseekingissupportedforthisstreamThispropertyalwaysreturnsfalse

publicoverrideboolCanSeek{get;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.CanSeekProperty

SharpZipCompressionLibrary

Getvalueindicatingifthisstreamsupportswriting

publicoverrideboolCanWrite{get;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.CanWriteProperty

SharpZipCompressionLibrary

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

publicboolIsStreamOwner{get;set;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.IsStreamOwnerProperty

SharpZipCompressionLibrary

Getcurrentlengthofstream

publicoverridelongLength{get;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.LengthProperty

SharpZipCompressionLibrary

Get/setthepasswordusedforencryption.Whennullnoencryptionisperformed

publicstringPassword{get;set;}

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.PasswordProperty

SharpZipCompressionLibrary

Thecurrentpositionwithinthestream.AlwaysthrowsaNotSupportedExceptionNotSupportedException

publicoverridelongPosition{get;set;}

ExceptionsExceptionType ConditionNotSupportedException Anyattempttosetposition

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheDeflaterOutputStreamclassarelistedbelow.ForacompletelistofDeflaterOutputStreamclassmembers,seetheDeflaterOutputStreamMemberstopic.

PublicInstanceMethodsBeginRead Asynchronousreadsarenot

supportedaNotSupportedExceptionisalwaysthrown

BeginWrite Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

Close Callsfinish()andclosestheunderlyingstreamwhenIsStreamOwneristrue.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Finish Finishesthestreambycallingfinish()onthedeflater.

Flush Flushesthestreambycallingflush()onthedeflaterandthen

DeflaterOutputStreamMethods

ontheunderlyingstream.Thisensuresthatallbytesareflushed.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Readablockofbytesfromstream

ReadByte Readabytefromstreamadvancingpositionbyone

Seek Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

SetLength Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writesbytesfromanarraytothecompressedstream.

WriteByte Writesasinglebytetothecompressedoutputstream.

ProtectedInstanceMethods

CreateWaitHandle(inheritedfromStream)

AllocatesaWaitHandleobject.

Deflate Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

EncryptBlock Encryptablockofdata

EncryptByte Encryptasinglebyte

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

InitializePassword Initializesencryptionkeysbasedongivenpassword

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

UpdateKeys Updateencryptionkeys

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

AsynchronousreadsarenotsupportedaNotSupportedExceptionisalwaysthrown

publicoverrideIAsyncResultBeginRead(

byte[]buffer,

intoffset,

intcount,

AsyncCallbackcallback,

objectstate

);

Parametersbuffer

offset

count

callback

state

ReturnValue

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.BeginReadMethod

SharpZipCompressionLibrary

Asynchronouswritesarentsupported,aNotSupportedExceptionisalwaysthrown

publicoverrideIAsyncResultBeginWrite(

byte[]buffer,

intoffset,

intcount,

AsyncCallbackcallback,

objectstate

);

Parametersbuffer

offset

count

callback

state

ReturnValue

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.BeginWriteMethod

SharpZipCompressionLibrary

Callsfinish()andclosestheunderlyingstreamwhenIsStreamOwneristrue.

publicoverridevoidClose();

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.CloseMethod

SharpZipCompressionLibrary

Deflateseverythingintheinputbuffers.Thiswillcall

def.deflate()

untilallbytesfromtheinputbuffersareprocessed.

protectedvoidDeflate();

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.DeflateMethod

SharpZipCompressionLibrary

Encryptablockofdata

protectedvoidEncryptBlock(

byte[]buffer,

intoffset,

intlength

);

Parametersbuffer

Datatoencrypt.NOTEtheoriginalcontentsofthebufferarelost

offsetOffsetoffirstbyteinbuffertoencrypt

lengthNumberofbytesinbuffertoencrypt

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.EncryptBlockMethod

SharpZipCompressionLibrary

Encryptasinglebyte

protectedbyteEncryptByte();

ReturnValueTheencryptedvalue

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.EncryptByteMethod

SharpZipCompressionLibrary

Finishesthestreambycallingfinish()onthedeflater.

publicvirtualvoidFinish();

ExceptionsExceptionType ConditionSharpZipBaseException Notallinputisdeflated

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.FinishMethod

SharpZipCompressionLibrary

Flushesthestreambycallingflush()onthedeflaterandthenontheunderlyingstream.Thisensuresthatallbytesareflushed.

publicoverridevoidFlush();

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.FlushMethod

SharpZipCompressionLibrary

Initializesencryptionkeysbasedongivenpassword

protectedvoidInitializePassword(

stringpassword

);

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.InitializePasswordMethod

SharpZipCompressionLibrary

Readablockofbytesfromstream

publicoverrideintRead(

byte[]b,

intoff,

intlen

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.ReadMethod

SharpZipCompressionLibrary

Readabytefromstreamadvancingpositionbyone

publicoverrideintReadByte();

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.ReadByteMethod

SharpZipCompressionLibrary

Setsthecurrentpositionofthisstreamtothegivenvalue.Notsupportedbythisclass!

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.SeekMethod

SharpZipCompressionLibrary

Setsthelengthofthisstreamtothegivenvalue.Notsupportedbythisclass!

publicoverridevoidSetLength(

longval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.SetLengthMethod

SharpZipCompressionLibrary

Updateencryptionkeys

protectedvoidUpdateKeys(

bytech

);

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.UpdateKeysMethod

SharpZipCompressionLibrary

Writesbytesfromanarraytothecompressedstream.

publicoverridevoidWrite(

byte[]buf,

intoff,

intlen

);

Parametersbuf

Thebytearray

offTheoffsetintothebytearraywheretostart.

lenThenumberofbytestowrite.

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.WriteMethod

SharpZipCompressionLibrary

Writesasinglebytetothecompressedoutputstream.

publicoverridevoidWriteByte(

bytebval

);

Parametersbval

Thebytevalue.

SeeAlsoDeflaterOutputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

DeflaterOutputStream.WriteByteMethod

SharpZipCompressionLibrary

AninputbuffercustomisedforusebyInflaterInputStream

Foralistofallmembersofthistype,seeInflaterInputBufferMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputBuffer

publicclassInflaterInputBuffer

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RemarksThebuffersupportsdecryptionofincomingdata.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.Compression.StreamsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoInflaterInputBufferMembers|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBufferClass

SharpZipCompressionLibrary

InflaterInputBufferoverview

PublicInstanceConstructorsInflaterInputBuffer

ConstructorInitialiseanewinstanceofInflaterInputBuffer

PublicInstancePropertiesAvailable Get/setthenumberofbytes

available

ClearText Getthecontentsofthecleartextbuffer.

ClearTextLength GetthenumberofuseablebytesinClearText

CryptoTransform Get/settheICryptoTransformtoapplytoanydata.

RawData Getthecontentsoftherawdatabuffer.

RawLength GetthelengthofbytesbytesintheRawData

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

Fill Fillthebufferfromtheunderlyinginputstream.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfrom GetstheTypeofthecurrent

InflaterInputBufferMembers

Object) instance.

ReadClearTextBuffer Readcleartextdatafromtheinputstream.

ReadLeByte Readabytefromtheinputstream.

ReadLeInt Readanintinlittleendianbyteorder.

ReadLeLong ReadanintbaseInputStreamlittleendianbyteorder.

ReadLeShort Readanunsignedshortinlittleendianbyteorder.

ReadRawBuffer Overloaded.Readabufferdirectlyfromtheinputstream

SetInflaterInput CallSetInputpassingthecurrentcleartextbuffercontents.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

InitialiseanewinstanceofInflaterInputBuffer

publicInflaterInputBuffer(

Streamstream

);

Parametersstream

Thestreamtobuffer.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBufferConstructor

SharpZipCompressionLibrary

ThepropertiesoftheInflaterInputBufferclassarelistedbelow.ForacompletelistofInflaterInputBufferclassmembers,seetheInflaterInputBufferMemberstopic.

PublicInstancePropertiesAvailable Get/setthenumberofbytes

available

ClearText Getthecontentsofthecleartextbuffer.

ClearTextLength GetthenumberofuseablebytesinClearText

CryptoTransform Get/settheICryptoTransformtoapplytoanydata.

RawData Getthecontentsoftherawdatabuffer.

RawLength GetthelengthofbytesbytesintheRawData

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBufferProperties

SharpZipCompressionLibrary

Get/setthenumberofbytesavailable

publicintAvailable{get;set;}

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.AvailableProperty

SharpZipCompressionLibrary

Getthecontentsofthecleartextbuffer.

publicbyte[]ClearText{get;}

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ClearTextProperty

SharpZipCompressionLibrary

GetthenumberofuseablebytesinClearText

publicintClearTextLength{get;}

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ClearTextLengthProperty

SharpZipCompressionLibrary

Get/settheICryptoTransformtoapplytoanydata.

publicSystem.Security.Cryptography.ICryptoTransform

RemarksSetthisvaluetonulltohavenotransformapplied.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.CryptoTransformProperty

SharpZipCompressionLibrary

Getthecontentsoftherawdatabuffer.

publicbyte[]RawData{get;}

RemarksThismaycontainencrypteddata.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.RawDataProperty

SharpZipCompressionLibrary

GetthelengthofbytesbytesintheRawData

publicintRawLength{get;}

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.RawLengthProperty

SharpZipCompressionLibrary

ThemethodsoftheInflaterInputBufferclassarelistedbelow.ForacompletelistofInflaterInputBufferclassmembers,seetheInflaterInputBufferMemberstopic.

PublicInstanceMethodsEquals(inheritedfromObject) Determineswhetherthe

specifiedObjectisequaltothecurrentObject.

Fill Fillthebufferfromtheunderlyinginputstream.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

ReadClearTextBuffer Readcleartextdatafromtheinputstream.

ReadLeByte Readabytefromtheinputstream.

ReadLeInt Readanintinlittleendianbyteorder.

ReadLeLong ReadanintbaseInputStreamlittleendianbyteorder.

ReadLeShort Readanunsignedshortinlittleendianbyteorder.

ReadRawBuffer Overloaded.Readabufferdirectlyfromtheinputstream

SetInflaterInput CallSetInputpassingthecurrentcleartextbuffercontents.

InflaterInputBufferMethods

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

Fillthebufferfromtheunderlyinginputstream.

publicvoidFill();

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.FillMethod

SharpZipCompressionLibrary

Readcleartextdatafromtheinputstream.

publicintReadClearTextBuffer(

byte[]outBuffer,

intoffset,

intlength

);

ParametersoutBuffer

Thebuffertoadddatato.

offsetTheoffsettostartaddingdataat.

lengthThenumberofbytestoread.

ReturnValueReturnsthenumberofbytesactuallyread.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadClearTextBufferMethod

SharpZipCompressionLibrary

Readabytefromtheinputstream.

publicintReadLeByte();

ReturnValueReturnsthebyteread.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadLeByteMethod

SharpZipCompressionLibrary

Readanintinlittleendianbyteorder.

publicintReadLeInt();

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadLeIntMethod

SharpZipCompressionLibrary

ReadanintbaseInputStreamlittleendianbyteorder.

publiclongReadLeLong();

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadLeLongMethod

SharpZipCompressionLibrary

Readanunsignedshortinlittleendianbyteorder.

publicintReadLeShort();

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadLeShortMethod

SharpZipCompressionLibrary

Readabufferdirectlyfromtheinputstream

OverloadListReadabufferdirectlyfromtheinputstream

publicintReadRawBuffer(byte[]);

Readabufferdirectlyfromtheinputstream

publicintReadRawBuffer(byte[],int,int);

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.ReadRawBufferMethod

SharpZipCompressionLibrary

Readabufferdirectlyfromtheinputstream

publicintReadRawBuffer(

byte[]buffer

);

Parametersbuffer

Thebuffertofill

ReturnValueReturnsthenumberofbytesread.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|InflaterInputBuffer.ReadRawBufferOverloadList

InflaterInputBuffer.ReadRawBufferMethod(Byte[])

SharpZipCompressionLibrary

Readabufferdirectlyfromtheinputstream

publicintReadRawBuffer(

byte[]outBuffer,

intoffset,

intlength

);

ParametersoutBuffer

Thebuffertoreadinto

offsetTheoffsettostartreadingdatainto.

lengthThenumberofbytestoread.

ReturnValueReturnsthenumberofbytesread.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|InflaterInputBuffer.ReadRawBufferOverloadList

InflaterInputBuffer.ReadRawBufferMethod(Byte[],Int32,Int32)

SharpZipCompressionLibrary

CallSetInputpassingthecurrentcleartextbuffercontents.

publicvoidSetInflaterInput(

Inflaterinflater

);

Parametersinflater

Theinflatertosetinputfor.

SeeAlsoInflaterInputBufferClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputBuffer.SetInflaterInputMethod

SharpZipCompressionLibrary

Thisfilterstreamisusedtodecompressdatacompressedusingthe"deflate"format.The"deflate"formatisdescribedinRFC1951.Thisstreammayformthebasisforotherdecompressionfilters,suchastheGZipInputStream.Authoroftheoriginaljavaversion:JohnLeuner.

Foralistofallmembersofthistype,seeInflaterInputStreamMembers.

System.ObjectSystem.MarshalByRefObjectSystem.IO.StreamICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStreamICSharpCode.SharpZipLib.GZip.GZipInputStreamICSharpCode.SharpZipLib.Zip.ZipInputStream

publicclassInflaterInputStream:Stream

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.Compression.StreamsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoInflaterInputStreamMembers|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStreamClass

SharpZipCompressionLibrary

InflaterInputStreamoverview

PublicInstanceConstructorsInflaterInputStream Overloaded.Initializesanew

instanceoftheInflaterInputStreamclass.

PublicInstancePropertiesAvailable Returns0oncetheendofthe

stream(EOF)hasbeenreached.Otherwisereturns1.

CanRead Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

CanWrite Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

IsStreamOwner Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length Avaluerepresentingthelengthofthestreaminbytes.

Position Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

PublicInstanceMethods

InflaterInputStreamMembers

BeginRead(inheritedfromStream)

Beginsanasynchronousreadoperation.

BeginWrite Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

Close Closestheinputstream.WhenIsStreamOwneristruetheunderlyingstreamisalsoclosed.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService Obtainsalifetimeserviceobject

(inheritedfromMarshalByRefObject)

tocontrolthelifetimepolicyforthisinstance.

Read Decompressesdataintothebytearray

ReadByte(inheritedfromStream)

Readsabytefromthestreamandadvancesthepositionwithinthestreambyonebyte,orreturns-1ifattheendofthestream.

Seek SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte WritesonebytetothecurrentstreamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceFieldsbaseInputStream Basestreamtheinflaterreads

from.

csize Thecompressedsize

inf Decompressorforthisstream

inputBuffer Inputbufferforthisstream.

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting Clearanycryptographicstate.

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

CreateanInflaterInputStreamwiththedefaultdecompressorandadefaultbuffersizeof4KB.

OverloadListCreateanInflaterInputStreamwiththedefaultdecompressorandadefaultbuffersizeof4KB.

publicInflaterInputStream(Stream);

CreateanInflaterInputStreamwiththespecifieddecompressorandadefaultbuffersizeof4KB.

publicInflaterInputStream(Stream,Inflater);

CreateanInflaterInputStreamwiththespecifieddecompressorandthespecifiedbuffersize.

publicInflaterInputStream(Stream,Inflater,int);

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStreamConstructor

SharpZipCompressionLibrary

CreateanInflaterInputStreamwiththedefaultdecompressorandadefaultbuffersizeof4KB.

publicInflaterInputStream(

StreambaseInputStream

);

ParametersbaseInputStream

TheInputStreamtoreadbytesfrom

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|InflaterInputStreamConstructorOverloadList

InflaterInputStreamConstructor(Stream)

SharpZipCompressionLibrary

CreateanInflaterInputStreamwiththespecifieddecompressorandadefaultbuffersizeof4KB.

publicInflaterInputStream(

StreambaseInputStream,

Inflaterinf

);

ParametersbaseInputStream

Thesourceofinputdata

infThedecompressorusedtodecompressdatareadfrombaseInputStream

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|InflaterInputStreamConstructorOverloadList

InflaterInputStreamConstructor(Stream,Inflater)

SharpZipCompressionLibrary

CreateanInflaterInputStreamwiththespecifieddecompressorandthespecifiedbuffersize.

publicInflaterInputStream(

StreambaseInputStream,

Inflaterinflater,

intbufferSize

);

ParametersbaseInputStream

TheInputStreamtoreadbytesfrom

inflaterThedecompressortouse

bufferSizeSizeofthebuffertouse

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace|InflaterInputStreamConstructorOverloadList

InflaterInputStreamConstructor(Stream,Inflater,Int32)

SharpZipCompressionLibrary

ThefieldsoftheInflaterInputStreamclassarelistedbelow.ForacompletelistofInflaterInputStreamclassmembers,seetheInflaterInputStreamMemberstopic.

ProtectedInstanceFieldsbaseInputStream Basestreamtheinflaterreads

from.

csize Thecompressedsize

inf Decompressorforthisstream

inputBuffer Inputbufferforthisstream.

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStreamFields

SharpZipCompressionLibrary

Basestreamtheinflaterreadsfrom.

protectedStreambaseInputStream;

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.baseInputStreamField

SharpZipCompressionLibrary

Thecompressedsize

protectedlongcsize;

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.csizeField

SharpZipCompressionLibrary

Decompressorforthisstream

protectedInflaterinf;

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.infField

SharpZipCompressionLibrary

Inputbufferforthisstream.

protectedInflaterInputBufferinputBuffer;

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.inputBufferField

SharpZipCompressionLibrary

ThepropertiesoftheInflaterInputStreamclassarelistedbelow.ForacompletelistofInflaterInputStreamclassmembers,seetheInflaterInputStreamMemberstopic.

PublicInstancePropertiesAvailable Returns0oncetheendofthe

stream(EOF)hasbeenreached.Otherwisereturns1.

CanRead Getsavalueindicatingwhetherthecurrentstreamsupportsreading

CanSeek Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

CanWrite Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

IsStreamOwner Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

Length Avaluerepresentingthelengthofthestreaminbytes.

Position Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStreamProperties

SharpZipCompressionLibrary

Returns0oncetheendofthestream(EOF)hasbeenreached.Otherwisereturns1.

publicvirtualintAvailable{get;}

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.AvailableProperty

SharpZipCompressionLibrary

Getsavalueindicatingwhetherthecurrentstreamsupportsreading

publicoverrideboolCanRead{get;}

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.CanReadProperty

SharpZipCompressionLibrary

Getsavalueoffalseindicatingseekingisnotsupportedforthisstream.

publicoverrideboolCanSeek{get;}

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.CanSeekProperty

SharpZipCompressionLibrary

Getsavalueoffalseindicatingthatthisstreamisnotwriteable.

publicoverrideboolCanWrite{get;}

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.CanWriteProperty

SharpZipCompressionLibrary

Get/setflagindicatingownershipofunderlyingstream.WhentheflagistrueClosewillclosetheunderlyingstreamalso.

publicboolIsStreamOwner{get;set;}

RemarksThedefaultvalueistrue.

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.IsStreamOwnerProperty

SharpZipCompressionLibrary

Avaluerepresentingthelengthofthestreaminbytes.

publicoverridelongLength{get;}

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.LengthProperty

SharpZipCompressionLibrary

Thecurrentpositionwithinthestream.ThrowsaNotSupportedExceptionwhenattemptingtosettheposition

publicoverridelongPosition{get;set;}

ExceptionsExceptionType ConditionNotSupportedException Attemptingtosettheposition

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.PositionProperty

SharpZipCompressionLibrary

ThemethodsoftheInflaterInputStreamclassarelistedbelow.ForacompletelistofInflaterInputStreamclassmembers,seetheInflaterInputStreamMemberstopic.

PublicInstanceMethodsBeginRead(inheritedfrom

Stream)Beginsanasynchronousreadoperation.

BeginWrite Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

Close Closestheinputstream.WhenIsStreamOwneristruetheunderlyingstreamisalsoclosed.

CreateObjRef(inheritedfromMarshalByRefObject)

Createsanobjectthatcontainsalltherelevantinformationrequiredtogenerateaproxyusedtocommunicatewitharemoteobject.

EndRead(inheritedfromStream)

Waitsforthependingasynchronousreadtocomplete.

EndWrite(inheritedfromStream)

Endsanasynchronouswriteoperation.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

Flush FlushesthebaseInputStream

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

InflaterInputStreamMethods

GetLifetimeService(inheritedfromMarshalByRefObject)

Retrievesthecurrentlifetimeserviceobjectthatcontrolsthelifetimepolicyforthisinstance.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

InitializeLifetimeService(inheritedfromMarshalByRefObject)

Obtainsalifetimeserviceobjecttocontrolthelifetimepolicyforthisinstance.

Read Decompressesdataintothebytearray

ReadByte(inheritedfromStream)

Readsabytefromthestreamandadvancesthepositionwithinthestreambyonebyte,orreturns-1ifattheendofthestream.

Seek SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

SetLength SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

Skip Skipspecifiednumberofbytesofuncompresseddata

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

WriteByte WritesonebytetothecurrentstreamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

ProtectedInstanceMethodsCreateWaitHandle(inherited

fromStream)AllocatesaWaitHandleobject.

Fill Fillsthebufferwithmoredatatodecompress.

Finalize(inheritedfromObject)

AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

StopDecrypting Clearanycryptographicstate.

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

Entrypointtobeginanasynchronouswrite.AlwaysthrowsaNotSupportedException.

publicoverrideIAsyncResultBeginWrite(

byte[]buffer,

intoffset,

intcount,

AsyncCallbackcallback,

objectstate

);

Parametersbuffer

Thebuffertowritedatafrom

offsetOffsetoffirstbytetowrite

countThemaximumnumberofbytestowrite

callbackThemethodtobecalledwhentheasynchronouswriteoperationiscompleted

stateAuser-providedobjectthatdistinguishesthisparticularasynchronouswriterequestfromotherrequests

ReturnValueAnIAsyncResultthatreferencestheasynchronouswrite

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlso

InflaterInputStream.BeginWriteMethod

InflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

Closestheinputstream.WhenIsStreamOwneristruetheunderlyingstreamisalsoclosed.

publicoverridevoidClose();

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.CloseMethod

SharpZipCompressionLibrary

Fillsthebufferwithmoredatatodecompress.

protectedvoidFill();

ExceptionsExceptionType ConditionSharpZipBaseException Streamendsearly

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.FillMethod

SharpZipCompressionLibrary

FlushesthebaseInputStream

publicoverridevoidFlush();

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.FlushMethod

SharpZipCompressionLibrary

Decompressesdataintothebytearray

publicoverrideintRead(

byte[]b,

intoff,

intlen

);

Parametersb

Thearraytoreadanddecompressdatainto

offTheoffsetindicatingwherethedatashouldbeplaced

lenThenumberofbytestodecompress

ReturnValueThenumberofbytesread.Zerosignalstheendofstream

ExceptionsExceptionType ConditionSharpZipBaseException Inflaterneedsadictionary

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.ReadMethod

SharpZipCompressionLibrary

SetsthepositionwithinthecurrentstreamAlwaysthrowsaNotSupportedException

publicoverridelongSeek(

longoffset,

SeekOriginorigin

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.SeekMethod

SharpZipCompressionLibrary

SetthelengthofthecurrentstreamAlwaysthrowsaNotSupportedException

publicoverridevoidSetLength(

longval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.SetLengthMethod

SharpZipCompressionLibrary

Skipspecifiednumberofbytesofuncompresseddata

publiclongSkip(

longn

);

Parametersn

Numberofbytestoskip

ReturnValueThenumberofbytesskipped,zeroiftheendofstreamhasbeenreached

ExceptionsExceptionType ConditionArgumentOutOfRangeException Numberofbytestoskipiszero

orless

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.SkipMethod

SharpZipCompressionLibrary

Clearanycryptographicstate.

protectedvoidStopDecrypting();

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.StopDecryptingMethod

SharpZipCompressionLibrary

WritesasequenceofbytestostreamandadvancesthecurrentpositionThismethodalwaysthrowsaNotSupportedException

publicoverridevoidWrite(

byte[]array,

intoffset,

intcount

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.WriteMethod

SharpZipCompressionLibrary

WritesonebytetothecurrentstreamandadvancesthecurrentpositionAlwaysthrowsaNotSupportedException

publicoverridevoidWriteByte(

byteval

);

ExceptionsExceptionType ConditionNotSupportedException Anyaccess

SeeAlsoInflaterInputStreamClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

InflaterInputStream.WriteByteMethod

SharpZipCompressionLibrary

ContainstheoutputfromtheInflationprocess.Weneedtohaveawindowsothatwecanreferbackwardsintotheoutputstreamtorepeatstuff.Authoroftheoriginaljavaversion:JohnLeuner

Foralistofallmembersofthistype,seeOutputWindowMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.Streams.OutputWindow

publicclassOutputWindow

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.Compression.StreamsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoOutputWindowMembers|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindowClass

SharpZipCompressionLibrary

OutputWindowoverview

PublicInstanceConstructorsOutputWindowConstructor Initializesanewinstanceofthe

OutputWindowclass.

PublicInstanceMethodsCopyDict Copydictionarytowindow

CopyOutput Copycontentsofwindowtooutput

CopyStored Copyfrominputmanipulatortointernalwindow

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetAvailable Getbytesavailableforoutputinwindow

GetFreeSpace Getremainingunfilledspaceinwindow

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Repeat Appendabytepatternalreadyinthewindowitself

Reset ResetbyclearingwindowsoGetAvailablereturns0

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

OutputWindowMembers

Write Writeabytetothisoutputwindow

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

InitializesanewinstanceoftheOutputWindowclass.

publicOutputWindow();

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindowConstructor

SharpZipCompressionLibrary

ThemethodsoftheOutputWindowclassarelistedbelow.ForacompletelistofOutputWindowclassmembers,seetheOutputWindowMemberstopic.

PublicInstanceMethodsCopyDict Copydictionarytowindow

CopyOutput Copycontentsofwindowtooutput

CopyStored Copyfrominputmanipulatortointernalwindow

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetAvailable Getbytesavailableforoutputinwindow

GetFreeSpace Getremainingunfilledspaceinwindow

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

Repeat Appendabytepatternalreadyinthewindowitself

Reset ResetbyclearingwindowsoGetAvailablereturns0

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

Write Writeabytetothisoutputwindow

OutputWindowMethods

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

Copydictionarytowindow

publicvoidCopyDict(

byte[]dict,

intoffset,

intlen

);

Parametersdict

sourcedictionary

offsetoffsetofstartinsourcedictionary

lenlengthofdictionary

ExceptionsExceptionType ConditionInvalidOperationException Ifwindowisntempty

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.CopyDictMethod

SharpZipCompressionLibrary

Copycontentsofwindowtooutput

publicintCopyOutput(

byte[]output,

intoffset,

intlen

);

Parametersoutput

buffertocopyto

offsetoffsettostartat

lennumberofbytestocount

ReturnValueThenumberofbytescopied

ExceptionsExceptionType ConditionInvalidOperationException Ifawindowunderflowoccurs

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.CopyOutputMethod

SharpZipCompressionLibrary

Copyfrominputmanipulatortointernalwindow

publicintCopyStored(

StreamManipulatorinput,

intlen

);

Parametersinput

sourceofdata

lenlengthofdatatocopy

ReturnValuethenumberofbytescopied

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.CopyStoredMethod

SharpZipCompressionLibrary

Getbytesavailableforoutputinwindow

publicintGetAvailable();

ReturnValueNumberofbytesfilled

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.GetAvailableMethod

SharpZipCompressionLibrary

Getremainingunfilledspaceinwindow

publicintGetFreeSpace();

ReturnValueNumberofbytesleftinwindow

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.GetFreeSpaceMethod

SharpZipCompressionLibrary

Appendabytepatternalreadyinthewindowitself

publicvoidRepeat(

intlen,

intdist

);

Parameterslen

lengthofpatterntocopy

distdistancefromendofwindowpatternoccurs

ExceptionsExceptionType ConditionInvalidOperationException Iftherepeateddataoverflows

thewindow

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.RepeatMethod

SharpZipCompressionLibrary

ResetbyclearingwindowsoGetAvailablereturns0

publicvoidReset();

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.ResetMethod

SharpZipCompressionLibrary

Writeabytetothisoutputwindow

publicvoidWrite(

intabyte

);

Parametersabyte

valuetowrite

ExceptionsExceptionType ConditionInvalidOperationException ifwindowisfull

SeeAlsoOutputWindowClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

OutputWindow.WriteMethod

SharpZipCompressionLibrary

Thisclassallowsustoretrieveaspecifiednumberofbitsfromtheinputbuffer,aswellascopybigbyteblocks.Itusesanintbuffertostoreupto31bitsfordirectmanipulation.Thisguaranteesthatwecangetatleast16bits,butweonlyneedatmost15,sothisisallsafe.Therearesomeoptimizationsinthisclass,forexample,youmustneverpeekmorethan8bitsmorethanneeded,andyoumustfirstpeekbitsbeforeyoumaydropthem.ThisisnotageneralpurposeclassbutoptimizedforthebehaviouroftheInflater.authorsoftheoriginaljavaversion:JohnLeuner,JochenHoenicke

Foralistofallmembersofthistype,seeStreamManipulatorMembers.

System.ObjectICSharpCode.SharpZipLib.Zip.Compression.Streams.StreamManipulator

publicclassStreamManipulator

ThreadSafetyPublicstatic(SharedinVisualBasic)membersofthistypearesafeformultithreadedoperations.Instancemembersarenotguaranteedtobethread-safe.

RequirementsNamespace:ICSharpCode.SharpZipLib.Zip.Compression.StreamsAssembly:ICSharpCode.SharpZipLib(inICSharpCode.SharpZipLib.dll)

SeeAlsoStreamManipulatorMembers|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulatorClass

SharpZipCompressionLibrary

StreamManipulatoroverview

PublicInstanceConstructorsStreamManipulator

ConstructorConstructsadefaultStreamManipulatorwithallbuffersempty

PublicInstancePropertiesAvailableBits Getsthenumberofbits

availableinthebitbuffer.ThismustbeonlycalledwhenapreviousPeekBits()returned-1.

AvailableBytes Getsthenumberofbytesavailable.

IsNeedingInput ReturnstruewhenSetInputcanbecalled

PublicInstanceMethodsCopyBytes Copieslengthbytesfrominput

buffertooutputbufferstartingatoutput[offset].Youhavetomakesure,thatthebufferisbytealigned.Ifnotenoughbytesareavailable,copiesfewerbytes.

DropBits Dropsthenextnbitsfromtheinput.YoushouldhavecalledPeekBitswithabiggerorequalnbefore,tomakesurethatenoughbitsareinthebitbuffer.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetBits Getsthenextnbitsand

StreamManipulatorMembers

increasesinputpointer.ThisisequivalenttoPeekBitsfollowedbydropBits,exceptforcorrecterrorhandling.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

PeekBits Getthenextnbitsbutdon'tincreaseinputpointer.nmustbelessorequal16andifthiscallsucceeds,youmustdropatleastn-8bitsinthenextcall.

Reset resetsstateandemptiesinternalbuffers

SetInput Addmoreinputforconsumption.OnlycallwhenIsNeedingInputreturnstrue

SkipToByteBoundary Skipstothenextbyteboundary.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlso

StreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

ConstructsadefaultStreamManipulatorwithallbuffersempty

publicStreamManipulator();

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulatorConstructor

SharpZipCompressionLibrary

ThepropertiesoftheStreamManipulatorclassarelistedbelow.ForacompletelistofStreamManipulatorclassmembers,seetheStreamManipulatorMemberstopic.

PublicInstancePropertiesAvailableBits Getsthenumberofbits

availableinthebitbuffer.ThismustbeonlycalledwhenapreviousPeekBits()returned-1.

AvailableBytes Getsthenumberofbytesavailable.

IsNeedingInput ReturnstruewhenSetInputcanbecalled

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulatorProperties

SharpZipCompressionLibrary

Getsthenumberofbitsavailableinthebitbuffer.ThismustbeonlycalledwhenapreviousPeekBits()returned-1.

publicintAvailableBits{get;}

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.AvailableBitsProperty

SharpZipCompressionLibrary

Getsthenumberofbytesavailable.

publicintAvailableBytes{get;}

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.AvailableBytesProperty

SharpZipCompressionLibrary

ReturnstruewhenSetInputcanbecalled

publicboolIsNeedingInput{get;}

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.IsNeedingInputProperty

SharpZipCompressionLibrary

ThemethodsoftheStreamManipulatorclassarelistedbelow.ForacompletelistofStreamManipulatorclassmembers,seetheStreamManipulatorMemberstopic.

PublicInstanceMethodsCopyBytes Copieslengthbytesfrominput

buffertooutputbufferstartingatoutput[offset].Youhavetomakesure,thatthebufferisbytealigned.Ifnotenoughbytesareavailable,copiesfewerbytes.

DropBits Dropsthenextnbitsfromtheinput.YoushouldhavecalledPeekBitswithabiggerorequalnbefore,tomakesurethatenoughbitsareinthebitbuffer.

Equals(inheritedfromObject) DetermineswhetherthespecifiedObjectisequaltothecurrentObject.

GetBits Getsthenextnbitsandincreasesinputpointer.ThisisequivalenttoPeekBitsfollowedbydropBits,exceptforcorrecterrorhandling.

GetHashCode(inheritedfromObject)

Servesasahashfunctionforaparticulartype,suitableforuseinhashingalgorithmsanddatastructureslikeahashtable.

GetType(inheritedfromObject)

GetstheTypeofthecurrentinstance.

PeekBits Getthenextnbitsbutdon'tincreaseinputpointer.nmustbelessorequal16andifthis

StreamManipulatorMethods

callsucceeds,youmustdropatleastn-8bitsinthenextcall.

Reset resetsstateandemptiesinternalbuffers

SetInput Addmoreinputforconsumption.OnlycallwhenIsNeedingInputreturnstrue

SkipToByteBoundary Skipstothenextbyteboundary.

ToString(inheritedfromObject)

ReturnsaStringthatrepresentsthecurrentObject.

ProtectedInstanceMethodsFinalize(inheritedfrom

Object)AllowsanObjecttoattempttofreeresourcesandperformothercleanupoperationsbeforetheObjectisreclaimedbygarbagecollection.

MemberwiseClone(inheritedfromObject)

CreatesashallowcopyofthecurrentObject.

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

SharpZipCompressionLibrary

Copieslengthbytesfrominputbuffertooutputbufferstartingatoutput[offset].Youhavetomakesure,thatthebufferisbytealigned.Ifnotenoughbytesareavailable,copiesfewerbytes.

publicintCopyBytes(

byte[]output,

intoffset,

intlength

);

Parametersoutput

Thebuffertocopybytesto.

offsetTheoffsetinthebufferatwhichcopyingstarts

lengthThelengthtocopy,0isallowed.

ReturnValueThenumberofbytescopied,0ifnobyteswereavailable.

ExceptionsExceptionType ConditionArgumentOutOfRangeException Lengthislessthanzero

InvalidOperationException Bitbufferisntbytealigned

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.CopyBytesMethod

SharpZipCompressionLibrary

Dropsthenextnbitsfromtheinput.YoushouldhavecalledPeekBitswithabiggerorequalnbefore,tomakesurethatenoughbitsareinthebitbuffer.

publicvoidDropBits(

intn

);

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.DropBitsMethod

SharpZipCompressionLibrary

Getsthenextnbitsandincreasesinputpointer.ThisisequivalenttoPeekBitsfollowedbydropBits,exceptforcorrecterrorhandling.

publicintGetBits(

intn

);

ReturnValuethevalueofthebits,or-1ifnotenoughbitsavailable.

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.GetBitsMethod

SharpZipCompressionLibrary

Getthenextnbitsbutdon'tincreaseinputpointer.nmustbelessorequal16andifthiscallsucceeds,youmustdropatleastn-8bitsinthenextcall.

publicintPeekBits(

intn

);

ReturnValuethevalueofthebits,or-1ifnotenoughbitsavailable.*/

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.PeekBitsMethod

SharpZipCompressionLibrary

resetsstateandemptiesinternalbuffers

publicvoidReset();

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.ResetMethod

SharpZipCompressionLibrary

Addmoreinputforconsumption.OnlycallwhenIsNeedingInputreturnstrue

publicvoidSetInput(

byte[]buf,

intoff,

intlen

);

Parametersbuf

datatobeinput

offoffsetoffirstbyteofinput

lenlengthofinput

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.SetInputMethod

SharpZipCompressionLibrary

Skipstothenextbyteboundary.

publicvoidSkipToByteBoundary();

SeeAlsoStreamManipulatorClass|ICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

StreamManipulator.SkipToByteBoundaryMethod

SharpZipCompressionLibrary

System.Object

System.Exception----System.Runtime.Serialization.ISerializable

System.ApplicationException

ICSharpCode.SharpZipLib.SharpZipBaseException

SeeAlsoICSharpCode.SharpZipLibNamespace

ICSharpCode.SharpZipLibHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.BZip2.BZip2

ICSharpCode.SharpZipLib.BZip2.BZip2Constants

System.Exception----System.Runtime.Serialization.ISerializable

System.ApplicationException

ICSharpCode.SharpZipLib.SharpZipBaseException

ICSharpCode.SharpZipLib.BZip2.BZip2Exception

System.MarshalByRefObject

System.IO.Stream----System.IDisposable

ICSharpCode.SharpZipLib.BZip2.BZip2InputStream

ICSharpCode.SharpZipLib.BZip2.BZip2OutputStream

SeeAlsoICSharpCode.SharpZipLib.BZip2Namespace

ICSharpCode.SharpZipLib.BZip2Hierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Checksums.Adler32----ICSharpCode.SharpZipLib.Checksums.IChecksum

ICSharpCode.SharpZipLib.Checksums.Crc32----ICSharpCode.SharpZipLib.Checksums.IChecksum

ICSharpCode.SharpZipLib.Checksums.IChecksum

ICSharpCode.SharpZipLib.Checksums.StrangeCRC----ICSharpCode.SharpZipLib.Checksums.IChecksum

SeeAlsoICSharpCode.SharpZipLib.ChecksumsNamespace

ICSharpCode.SharpZipLib.ChecksumsHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Core.FileSystemScanner

ICSharpCode.SharpZipLib.Core.INameTransform

ICSharpCode.SharpZipLib.Core.IScanFilter

ICSharpCode.SharpZipLib.Core.NameFilter

ICSharpCode.SharpZipLib.Core.PathFilter----ICSharpCode.SharpZipLib.Core.IScanFilter

ICSharpCode.SharpZipLib.Core.NameAndSizeFilter

ICSharpCode.SharpZipLib.Core.ScanFailureEventArgs

System.Delegate----System.ICloneable,System.Runtime.Serialization.ISerializable

System.MulticastDelegate

ICSharpCode.SharpZipLib.Core.DirectoryFailureDelegate

ICSharpCode.SharpZipLib.Core.FileFailureDelegate

ICSharpCode.SharpZipLib.Core.ProcessDirectoryDelegate

ICSharpCode.SharpZipLib.Core.ProcessFileDelegate

System.EventArgs

ICSharpCode.SharpZipLib.Core.ScanEventArgs

ICSharpCode.SharpZipLib.Core.DirectoryEventArgs

SeeAlsoICSharpCode.SharpZipLib.CoreNamespace

ICSharpCode.SharpZipLib.CoreHierarchy

SharpZipCompressionLibrary

System.Object

System.Security.Cryptography.SymmetricAlgorithm----System.IDisposable

ICSharpCode.SharpZipLib.Encryption.PkzipClassic

ICSharpCode.SharpZipLib.Encryption.PkzipClassicManaged

SeeAlsoICSharpCode.SharpZipLib.EncryptionNamespace

ICSharpCode.SharpZipLib.EncryptionHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.GZip.GZipConstants

System.Exception----System.Runtime.Serialization.ISerializable

System.ApplicationException

ICSharpCode.SharpZipLib.SharpZipBaseException

ICSharpCode.SharpZipLib.GZip.GZipException

System.MarshalByRefObject

System.IO.Stream----System.IDisposable

ICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStream

ICSharpCode.SharpZipLib.GZip.GZipOutputStream

ICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStream

ICSharpCode.SharpZipLib.GZip.GZipInputStream

SeeAlsoICSharpCode.SharpZipLib.GZipNamespace

ICSharpCode.SharpZipLib.GZipHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Tar.TarArchive

ICSharpCode.SharpZipLib.Tar.TarBuffer

ICSharpCode.SharpZipLib.Tar.TarEntry----System.ICloneable

ICSharpCode.SharpZipLib.Tar.TarHeader----System.ICloneable

ICSharpCode.SharpZipLib.Tar.TarInputStream.EntryFactoryAdapter----ICSharpCode.SharpZipLib.Tar.TarInputStream.IEntryFactory

ICSharpCode.SharpZipLib.Tar.TarInputStream.IEntryFactory

System.Delegate----System.ICloneable,System.Runtime.Serialization.ISerializable

System.MulticastDelegate

ICSharpCode.SharpZipLib.Tar.ProgressMessageHandler

System.Exception----System.Runtime.Serialization.ISerializable

System.ApplicationException

ICSharpCode.SharpZipLib.SharpZipBaseException

ICSharpCode.SharpZipLib.Tar.TarException

ICSharpCode.SharpZipLib.Tar.InvalidHeaderException

System.MarshalByRefObject

System.IO.Stream----System.IDisposable

ICSharpCode.SharpZipLib.Tar.TarInputStream

ICSharpCode.SharpZipLib.Tar.TarOutputStream

SeeAlsoICSharpCode.SharpZipLib.TarNamespace

ICSharpCode.SharpZipLib.TarHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Zip.FastZip

ICSharpCode.SharpZipLib.Zip.FastZipEvents

ICSharpCode.SharpZipLib.Zip.ZipConstants

ICSharpCode.SharpZipLib.Zip.ZipEntry----System.ICloneable

ICSharpCode.SharpZipLib.Zip.ZipFile----System.Collections.IEnumerable

ICSharpCode.SharpZipLib.Zip.ZipNameTransform----ICSharpCode.SharpZipLib.Core.INameTransform

System.Delegate----System.ICloneable,System.Runtime.Serialization.ISerializable

System.MulticastDelegate

ICSharpCode.SharpZipLib.Zip.FastZip.ConfirmOverwriteDelegate

ICSharpCode.SharpZipLib.Zip.ZipFile.KeysRequiredEventHandler

System.EventArgs

ICSharpCode.SharpZipLib.Zip.KeysRequiredEventArgs

System.Exception----System.Runtime.Serialization.ISerializable

System.ApplicationException

ICSharpCode.SharpZipLib.SharpZipBaseException

ICSharpCode.SharpZipLib.Zip.ZipException

System.MarshalByRefObject

System.IO.Stream----System.IDisposable

ICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStream

ICSharpCode.SharpZipLib.Zip.ZipOutputStream

ICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStream

ICSharpCode.SharpZipLib.Zip.ZipInputStream

System.ValueType

ICSharpCode.SharpZipLib.ZipHierarchy

System.Enum----System.IComparable,System.IConvertible,System.IFormattable

ICSharpCode.SharpZipLib.Zip.CompressionMethod

ICSharpCode.SharpZipLib.Zip.FastZip.Overwrite

SeeAlsoICSharpCode.SharpZipLib.ZipNamespace

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Zip.Compression.Deflater

ICSharpCode.SharpZipLib.Zip.Compression.DeflaterConstants

ICSharpCode.SharpZipLib.Zip.Compression.DeflaterEngine

ICSharpCode.SharpZipLib.Zip.Compression.DeflaterHuffman

ICSharpCode.SharpZipLib.Zip.Compression.DeflaterHuffman.Tree

ICSharpCode.SharpZipLib.Zip.Compression.Inflater

ICSharpCode.SharpZipLib.Zip.Compression.InflaterHuffmanTree

ICSharpCode.SharpZipLib.Zip.Compression.PendingBuffer

ICSharpCode.SharpZipLib.Zip.Compression.DeflaterPending

System.ValueType

System.Enum----System.IComparable,System.IConvertible,System.IFormattable

ICSharpCode.SharpZipLib.Zip.Compression.DeflateStrategy

SeeAlsoICSharpCode.SharpZipLib.Zip.CompressionNamespace

ICSharpCode.SharpZipLib.Zip.CompressionHierarchy

SharpZipCompressionLibrary

System.Object

ICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputBuffer

ICSharpCode.SharpZipLib.Zip.Compression.Streams.OutputWindow

ICSharpCode.SharpZipLib.Zip.Compression.Streams.StreamManipulator

System.MarshalByRefObject

System.IO.Stream----System.IDisposable

ICSharpCode.SharpZipLib.Zip.Compression.Streams.DeflaterOutputStream

ICSharpCode.SharpZipLib.Zip.Compression.Streams.InflaterInputStream

SeeAlsoICSharpCode.SharpZipLib.Zip.Compression.StreamsNamespace

ICSharpCode.SharpZipLib.Zip.Compression.StreamsHierarchy

Recommended