-
-
19 Apr 2008 17:06:21 UTC
- Distribution: Egg-Release-Mail
- Module version: 0.01
- Source (raw)
- Browse (raw)
- Changes
- How to Contribute
- Issues
- Testers (4 / 0 / 1)
- Kwalitee
Bus factor: 0- License: perl_5
- Activity
24 month- Tools
- Download (33.33KB)
- MetaCPAN Explorer
- Permissions
- Subscribe to distribution
- Permalinks
- This version
- Latest version
and 1 contributors- Masatoshi Mizuno E<lt>lusheE<64>cpan.orgE<gt>
NAME
Egg::View::Mail::Plugin::PortCheck - The operation of the mail server is checked before Mail Sending.
SYNOPSIS
my $mail= $e->view('mail_label'); $mail->send( ........ ) || do { unless ($mail->scan->is_success) { .... The mail server is not operating. } };
DESCRIPTION
It is MAIL plugin that checks the operation of the mail server before Mail Sending.
When 'PortCheck' is passed to 'setup_plugin' method, it is built in.
package MyApp::View::Mail::MyComp; ......... __PACKAGE__->setup_plugin(qw/ PortCheck /);
It is necessary to set up it and Egg::Plugin::Net::Scan.
package MyApp; use Egg qw/ Net::Scan /;
CONFIGURATION
scan_host
Host name to be checked.
Default is 'localhost'.
scan_port
Port number to be checked.
Default is '25'.
scan_timeout
Time to wait for answer from check object.
Default is '3'.
METHODS
send ([MAIL_DATA_HASH])
Mail is transmitted.
If the check object is not operating, 0 is returned and processing is interrupted.
Please adjust the built-in order when competing with other components for which 'send' method is used.
__PACKAGE__->setup_plugin(qw/ Lot PortCheck /);
scan
The object returned from Egg::Plugin::Net::Scan is stored.
if (my $scan= $mail->scan) { $e->stash->{error_message}= $scan->is_error; }
SEE ALSO
Egg::Release, Egg::View::Mail, Egg::View::Mail::Base, Egg::Plugin::Net::Scan,
AUTHOR
Masatoshi Mizuno <lushe@cpan.org>
COPYRIGHT AND LICENSE
Copyright (C) 2008 Bee Flag, Corp. <http://egg.bomcity.com/>, All Rights Reserved.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself, either Perl version 5.8.6 or, at your option, any later version of Perl 5 you may have available.
Module Install Instructions
To install Egg::Release::Mail, copy and paste the appropriate command in to your terminal.
cpanm Egg::Release::Mail
perl -MCPAN -e shell install Egg::Release::Mail
For more information on module installation, please visit the detailed CPAN module installation guide.