System.Security.Cryptography.ToBase64Transform.TransformBlock Method

Converts the specified region of the input byte array to base 64 and copies the result to the specified region of the output byte array.

Syntax

public int TransformBlock (byte[] inputBuffer, int inputOffset, int inputCount, byte[] outputBuffer, int outputOffset)

Parameters

inputBuffer
The input to compute to base 64.
inputOffset
The offset into the input byte array from which to begin using data.
inputCount
The number of bytes in the input byte array to use as data.
outputBuffer
The output to which to write the result.
outputOffset
The offset into the output byte array from which to begin writing data.

Returns

The number of bytes written.

Remarks

The System.Security.Cryptography.ToBase64Transform class is a block algorithm that processes input blocks of 3 bytes and creates output blocks of 4 bytes. The ToBase64Transform.TransformBlock(Byte[], int, int, Byte[], int) method transforms an input block of 24 bits into 32 bits of character data. You must maintain 3 byte input boundaries to 4 byte output boundaries in order to match the block transform.

Requirements

Namespace: System.Security.Cryptography
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0