Sisimai::Mail::STDIN - Mailbox reader
use Sisimai::Mail::STDIN; my $mailbox = Sisimai::Mail::STDIN->new(); while( my $r = $mailbox->read ) { print $r; # print data read from STDIN } $mailbox->close;
Sisimai::Mail::STDIN read email data from STDIN.
new()
new() is a constructor of Sisimai::Mail::STDIN
my $mailbox = Sisimai::Mail::STDIN->new();
path()
path() returns "undef"
print $mailbox->path; # undef
name()
name() returns "undef"
print $mailbox->name; # undef
size()
size() returns "undef"
print $mailbox->size; # undef
offset()
offset() returns offset position for seeking the mbox. The value of "offset" is bytes which have already read.
print $mailbox->offset; # 0
handle()
handle() returns file handle object (IO::Handle) of the mbox.
$mailbox->handle->close;
read()
read() works as a iterator for reading each email in the mbox.
my $mailbox = Sisimai::Mail->new(); while( my $r = $mailbox->read ) { print $r; # print data read from STDIN }
azumakuniyuki
Copyright (C) 2014-2016 azumakuniyuki, All rights reserved.
This software is distributed under The BSD 2-Clause License.
To install Sisimai, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Sisimai
CPAN shell
perl -MCPAN -e shell install Sisimai
For more information on module installation, please visit the detailed CPAN module installation guide.