NAME

App::Framework::Feature::Mail - Send mail

SYNOPSIS

use App::Framework::Feature::Mail ;

DESCRIPTION

FIELDS

The following fields should be defined either in the call to 'new()', as part of a 'set()' call, or called by their accessor method (which is the same name as the field):

from - Mail sender (required)

Email sender

to - Mail recipient(s) (required)

Email recipient. Where there are multiple recipients, they should be set as a comma seperated list of email addresses

error_to - Error mail recipient(s)

Email recipient for errors. If set, program errors are sent to this email.

mail_level - Error level for mails

Set the minium error level that trigger an email. Level can be: note, warning, error

subject - Mail subject

Optional mail subject line

host - Mail host

Mailing host. If not specified uses 'localhost'

CONSTRUCTOR

new([%args])

Create a new Mail.

The %args are specified as they would be in the set method (see "Fields").

CLASS METHODS

init_class([%args])

Initialises the Mail object class variables.

OBJECT METHODS

send_mail($content [, %args])

Send some mail stored in $content. $content may either be a string (containing newlines), or an ARRAY ref.

Optionally %args may be specified (to set 'subject' etc)

catch_error_entry($error)

Send some mail stored in $content. $content may either be a string (containing newlines), or an ARRAY ref.

Optionally %args may be specified (to set 'subject' etc)

DIAGNOSTICS

Setting the debug flag to level 1 prints out (to STDOUT) some debug messages, setting it to level 2 prints out more verbose messages.

AUTHOR

Steve Price <sdprice at cpan.org>

BUGS

None that I know of!