line |
stmt |
bran |
cond |
sub |
code |
1
|
|
|
|
|
package List::Objects::WithUtils::Hash::Inflated::RW; |
2
|
1
|
|
|
1
|
use strictures 1; |
|
1
|
|
|
|
|
|
1
|
|
|
|
|
3
|
1
|
|
|
1
|
use Carp (); |
|
1
|
|
|
|
|
|
1
|
|
|
|
|
4
|
1
|
|
|
1
|
use Scalar::Util (); |
|
1
|
|
|
|
|
|
1
|
|
|
|
|
5
|
|
|
|
|
|
6
|
1
|
|
|
1
|
use parent 'List::Objects::WithUtils::Hash::Inflated'; |
|
1
|
|
|
|
|
|
1
|
|
|
|
|
7
|
|
|
|
|
|
8
|
|
|
|
|
our $AUTOLOAD; |
9
|
|
|
|
|
sub AUTOLOAD { |
10
|
6
|
|
|
6
|
my $self = shift; |
11
|
6
|
|
|
|
( my $method = $AUTOLOAD ) =~ s/.*:://; |
12
|
6
|
100
|
|
|
Scalar::Util::blessed($self) |
13
|
|
|
|
|
or Carp::confess "Not a class method: '$method'"; |
14
|
|
|
|
|
|
15
|
5
|
100
|
|
|
Carp::confess "Can't locate object method '$method'" |
16
|
|
|
|
|
unless exists $self->{$method}; |
17
|
4
|
100
|
|
|
return $self->{$method} unless @_; |
18
|
2
|
100
|
|
|
Carp::confess "Multiple arguments passed to setter '$method'" |
19
|
|
|
|
|
if @_ > 1; |
20
|
1
|
|
|
|
$self->{$method} = $_[0] |
21
|
|
|
|
|
} |
22
|
|
|
|
|
|
23
|
|
|
|
|
1; |
24
|
|
|
|
|
|
25
|
|
|
|
|
=pod |
26
|
|
|
|
|
|
27
|
|
|
|
|
=for Pod::Coverage AUTOLOAD |
28
|
|
|
|
|
|
29
|
|
|
|
|
=cut |
30
|
|
|
|
|
|