Indy 9 | Content | Index | Reference

TIdEncoderUUEBase
Hierarchy, Properties, Methods, See Also, Unit: IdCoderUUE
Implements an encoder using the UUEncode algorithm.

    TIdEncoderUUEBase = class(TIdEncoder3to4)

Unit
IdCoderUUE
Description
TIdEncoderUUEBase is a TIdEncoder3to4 descendant that implements an encoder that uses the UUEncode algorithm. TIdEncoderUUEBase provides the basic facilities needed to encode binary data into a 7-bit US-ASCII representation.

TIdEncoderUUEBase uses the same 3-byte to 4-bytes encoding algorithm used in TIdEncoder3to4. TIdEncoderUUEBase adds the ability to calculate and encode UUEncode body line format, which consists of the encoded length followed by the encoded data.

TIdEncoderUUEBase is used by other Indy coder classes, such as TIdMessageEncoderUUE, that handles UUEncoded message streams in RFC 822-compliant mail messages.

TIdEncoderUUEBase.Encode
TIdEncoderUUEBase, See Also
Implements the UUEncode encoding algorithm with support for body line formatting.

    function Encode(ASrcStream: TStream; const ABytes: integer = MaxInt): string; override;

Parameters
ASrcStream: TStream
Stream containing values to UUEncoded.
const ABytes: integer = MaxInt
Number of bytes to be affected by the UUEncode algorithm.
Return Value
String - UUEncode length byte and data from the encoding algorithm.
Description
Encode is a overridden String function in TIdEncoderUUEBase that implements creation of UUEncoded result values that include the encoded length and content in the UUEncode body line format. Encode calls the inherited Encode method.

Created with Doc-O-Matic 2 donated to Project JEDI. Commercial license available from the Doc-O-Matic site.