NAME
Sisimai::MTA::UserDefined - User defined MTA module as an example
SYNOPSIS
use lib '/path/to/your/lib/dir';
use Your::Custom::MTA::Module;
use Sisimai::Mail;
use Sisimai::Data;
use Sisimai::Message;
my $file = '/path/to/mailbox';
my $mail = Sisimai::Mail->new( $file );
my $mesg = undef;
my $data = undef;
while( my $r = $mail->read ){
$mesg = Sisimai::Message->new(
'data' => $r,
'load' => [ 'Your::Custom::MTA::Module' ]
);
$data = Sisimai::Data->make( 'data' => $mesg );
...
}
DESCRIPTION
Sisimai::MTA::UserDefined is an example module as a template to implement your custom MTA module.
CLASS METHODS
version()
version()
returns the version number of this module.
print Your::Custom::MTA::Module->version;
description()
description()
returns description string of this module.
print Your::Custom::MTA::Module->description;
smtpagent()
smtpagent()
returns MTA name.
print Your::Custom::MTA::Module->smtpagent;
scan( header data, reference to body string)
scan()
method parses a bounced email and return results as a array reference. See Sisimai::Message for more details.
AUTHOR
azumakuniyuki
COPYRIGHT
Copyright (C) 2015 azumakuniyuki <perl.org@azumakuniyuki.org>, All Rights Reserved.
LICENSE
This software is distributed under The BSD 2-Clause License.