my Mail::Message $msg = ...; my $decoded = $msg->decoded; my $encoded = $msg->encode(mime_type => 'image/gif', transfer_encoding => 'base64'); my $body = $msg->body; my $decoded = $body->decoded; my $encoded = $body->encode(transfer_encoding => '7bit');
Manages the message's body encodings and decodings on request of the main program. This package adds functionality to the Mail::Message::Body class when the decoded() or encode() method is called.
Four types of encodings are handled (in the right order)
Various operating systems have different ideas about how to encode the line termination. UNIX uses a LF character, MacOS uses a CR, and Windows uses a CR/LF combination. Messages which are transported over Internet will always use the CRLF separator.
Messages transmitted over Internet have to be plain ASCII. Complicated characters and binary files (like images and archives) must be encoded during transmission to an ASCII representation.
The implementation of the required encoders and decoders is found in the Mail::Message::TransferEnc set of packages. The related manual page lists the transfer encodings which are supported.
NOT IMPLEMENTED YET
NOT IMPLEMENTED YET