Mail::Builder::Attachment::Data |
Mail::Builder::Attachment - Helper module for handling attachments from data
use Mail::Builder; my $attachment = Mail::Builder::Attachment::Data($data,'invitation.pdf','application/pdf'); $attachment->name('party_invitation.pdf'); print $attachment->serialize; # Append the attachment to an Mail::Builder object $mb->attachment($attachment); # this removes all other attachments OR $mb->attachment->add($mail); =head1 DESCRIPTION
This module allows you to add attachments from data.
my $obj = Mail::Builder::Attachment::Data->new(CONTENT,NAME,MIME); Takes the data ,the file name as it should be diplayed in the e-mail message and a mime type.
$obj->compara(OBJECT); or $obj->compara(DATA);
Checks if two attachment objects contains the same data. Returns true or false. The compare method does not check if the mime types and name attributes of the two objects are identical.
Instead of a Mail::Builder::Attachment::Data
object you can also pass a
scalar value representing the data.
Returns the attachment as a MIME::Entity object.
Accessor which takes/returns the data.
Accessor which takes/returns the name of the file as displayed in the e-mail message.
Accessor which takes/returns the mime type of the file.
Maroš Kollár CPAN ID: MAROS maros [at] k-1.com http://www.k-1.com
Mail::Builder::Attachment::Data |