Class BlockTransformBase
Base class for all block transformations.
Inheritance
Inherited Members
Namespace: Telerik.Windows.Zip
Assembly: Telerik.Windows.Zip.dll
Syntax
public abstract class BlockTransformBase : IBlockTransform, IDisposable
Constructors
BlockTransformBase()
Declaration
protected BlockTransformBase()
Properties
CanReuseTransform
Gets a value indicating whether the current transform can be reused.
Declaration
public abstract bool CanReuseTransform { get; }
Property Value
System. true if the current transform can be reused; otherwise, false. |
Implements
CanTransformMultipleBlocks
Gets a value indicating whether multiple blocks can be transformed.
Declaration
public abstract bool CanTransformMultipleBlocks { get; }
Property Value
System. true if multiple blocks can be transformed; otherwise, false. |
Implements
FixedInputBlockSize
Gets or sets value which indicates whether the transformation uses input buffer of the fixed size.
Declaration
protected bool FixedInputBlockSize { get; set; }
Property Value
System.
|
Footer
Header
Gets transformation header (if required).
Declaration
public TransformationHeader Header { get; }
Property Value
Implements
InputBlockSize
Gets the input block size.
Declaration
public abstract int InputBlockSize { get; }
Property Value
System. The size of the input data blocks in bytes. |
Implements
OutputBlockSize
Gets the output block size.
Declaration
public abstract int OutputBlockSize { get; }
Property Value
System. The size of the output data blocks in bytes. |
Implements
Methods
CreateHeader(CompressionSettings)
Creates transformation header to be written into the output stream.
Declaration
public virtual void CreateHeader(CompressionSettings compressionSettings = null)
Parameters
Compression
|
Implements
Dispose()
Releases the resources used by the current instance of the ZipArchive class.
Declaration
public void Dispose()
Implements
Dispose(Boolean)
Releases the unmanaged resources used by the transform and optionally releases the managed resources.
Declaration
protected abstract void Dispose(bool disposing)
Parameters
System. Value which indicates whether both managed and unmanaged resources (true) on only unmanaged resources (false) should be released. |
InitFooterReading(Int32)
InitHeaderReading(CompressionSettings)
Initialize reading of the transformation header.
Declaration
public virtual void InitHeaderReading(CompressionSettings settings = null)
Parameters
Compression
|
Implements
ProcessFooter()
ProcessHeader()
Process transformation header has been read.
Declaration
public virtual void ProcessHeader()
Implements
TransformBlock(Byte[], Int32, Int32, Byte[], Int32)
Transforms the specified region of the input byte array and copies the resulting transform to the specified region of the output byte array.
Declaration
public abstract int TransformBlock(byte[] inputBuffer, int inputOffset, int inputCount, byte[] outputBuffer, int outputOffset)
Parameters
System. The input for which to compute the transform. |
System. The offset into the input byte array from which to begin using data. |
System. The number of bytes in the input byte array to use as data. |
System. The output to which to write the transform. |
System. The offset into the output byte array from which to begin writing data. |
Returns
System. The number of bytes written. |
Implements
TransformFinalBlock(Byte[], Int32, Int32)
Transforms the specified region of the specified byte array.
Declaration
public abstract byte[] TransformFinalBlock(byte[] inputBuffer, int inputOffset, int inputCount)
Parameters
System. The input for which to compute the transform. |
System. The offset into the byte array from which to begin using data. |
System. The number of bytes in the byte array to use as data. |
Returns
System. The computed transform. |
Implements
TransformFinalBlock(Byte[], Int32, Int32, CancellationToken)
Transforms the specified region of the specified byte array.
Declaration
public abstract byte[] TransformFinalBlock(byte[] inputBuffer, int inputOffset, int inputCount, CancellationToken cancellationToken)
Parameters
System. The input for which to compute the transform. |
System. The offset into the byte array from which to begin using data. |
System. The number of bytes in the byte array to use as data. |
System. The token to monitor for cancellation requests. |
Returns
System. The computed transform. |
Implements
ValidateInputBufferParameters(Byte[], Int32, Int32, Boolean, Boolean)
Validates parameters of the input buffer.
Declaration
protected void ValidateInputBufferParameters(byte[] inputBuffer, int inputOffset, int inputCount, bool validateBlockSize, bool allowZeroCount)
Parameters
System. The input for which to compute the transform. |
System. The offset into the input byte array from which to begin using data. |
System. The number of bytes in the input byte array to use as data. |
System. Indicates whether buffer block size should be validated. Should be true for the TransformBlock and false for the TransformFinalBlock. |
System. Indicates whether count can be zero. |
ValidateParameters(Byte[], Int32, Int32, Byte[], Int32, Boolean)
Validates parameters of the transform operation.
Declaration
protected void ValidateParameters(byte[] inputBuffer, int inputOffset, int inputCount, byte[] outputBuffer, int outputOffset, bool allowZeroCount)
Parameters
System. The input for which to compute the transform. |
System. The offset into the input byte array from which to begin using data. |
System. The number of bytes in the input byte array to use as data. |
System. The output to which to write the transform. |
System. The offset into the output byte array from which to begin writing data. |
System. Indicates whether input count can be zero. |