MYDan::Util::MIO::UDP - Send multiple UPD datagrams in parallel.
use MYDan::Util::MIO::UDP; my $udp = MYDan::Util::MIO::UDP->new( qw( host1:port1 host1:port2 ... ) ); my $result = $udp->run( max => 128, log => \*STDERR, timeout => 300 ); my $mesg = $result->{mesg}; my $error = $result->{error};
Send UDP datagrams in parallel. The following parameters may be defined in %param:
max : ( default 128 ) number of datagrams sent in parallel. log : ( default STDERR ) a handle to report progress. timeout : ( default 300 ) number of seconds allotted for each response. input : ( default from STDIN ) input buffer. resp : ( default 1 ) want response.
Returns HASH of HASH of nodes. First level is indexed by type ( mesg or error ). Second level is indexed by message.
To install MYDan, copy and paste the appropriate command in to your terminal.
cpanm
cpanm MYDan
CPAN shell
perl -MCPAN -e shell install MYDan
For more information on module installation, please visit the detailed CPAN module installation guide.