The Perl and Raku Conference 2025: Greenville, South Carolina - June 27-29 Learn more
12345678910111213141516—171819202122 package HTTP::MobileAttribute::Attribute::CarrierMethod;use strict;use warnings;use base 'Class::Component::Attribute';sub register { my ( $class, $plugin, $c, $method, $carrier, $code ) = @_; if ($c->carrier_longname eq $carrier) { $c->register_method( $method => $plugin ); }}1;__END__HideShow 6 lines of Pod=head1 SYNOPSIS sub foo : MobileMethod('DoCoMo') { # your codes here }
package
HTTP::MobileAttribute::Attribute::CarrierMethod;
use
strict;
warnings;
base
'Class::Component::Attribute'
;
sub
register {
my
(
$class
,
$plugin
$c
$method
$carrier
$code
) =
@_
if
->carrier_longname eq
) {
->register_method(
=>
);
}
1;
__END__
=head1 SYNOPSIS
sub foo : MobileMethod('DoCoMo') {
# your codes here