Indy 9 | Content | Index | Reference

TIdMessageDecoderUUE
Hierarchy, Properties, Methods, Events, See Also, Unit: IdMessageCoderUUE
Implements support for decoding RFC 822 message parts using the UUDecode algorithm.

    TIdMessageDecoderUUE = class(TIdMessageDecoder)

Unit
IdMessageCoderUUE
Description
TIdMessageDecoderUUE is a TIdMessageDecoder descendant that implements support for decoding RFC 822 message parts using the UUDecode algorithm. TIdMessageDecoderUUE extends the ancestor class to provide support for detecting both UUE- and XXE-encoded body lines, as well as the inconsistent use of FillChar at the end of the encoded data stream.

TIdMessageDecoderUUE.ReadBody
TIdMessageDecoderUUE, See Also
Implements reading and decoding the body of an RFC 822 message part using the UUDecode algorithm.

    function ReadBody(ADestStream: TStream; var AMsgEnd: Boolean): TIdMessageDecoder; override;

Parameters
ADestStream: TStream
Stream to receive the decoded contents of the message part.
Return Value
TIdMessageDecoder - Message decoder class used for the message part.
Description
ReadBody is an overridden TIdMessageDecoder function in TIdMessageDecoderUUE that implements reading and decoding of an RFC 822 message part using the UUDecode algorithm. ReadBody constructs an internal decoder class, either TIdDecoderUUE or TIdDecoderXXE, based on the value of the length byte in the encoded body line. If the body line does not contain a value expected for UUE- or XXE-encoded lines, an EIdException will be raised with the constant message RSUnrecognizedUUEEncodingScheme.

ReadBody calls ReadLn until the end of the encoded message stream is reached. Each line read from the input stream is processed using the DecodeToStream method for the decoder class instance.

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