| 1 | package JIP::Object; | ||||||||||||||||||||||||||||
| 2 | |||||||||||||||||||||||||||||
| 3 | 1 | ▶ | use 5.006; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 4 | 1 | ▶ | use strict; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 5 | 1 | ▶ | use warnings; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 6 | 1 | ▶ | use Carp qw(croak); | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 7 | 1 | ▶ | use Scalar::Util qw(blessed); | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 8 | 1 | ▶ | use English qw(-no_match_vars); | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 9 | |||||||||||||||||||||||||||||
| 10 | 1 | our $VERSION = '0.031'; | |||||||||||||||||||||||||||
| 11 | 1 | our $AUTOLOAD; | |||||||||||||||||||||||||||
| 12 | |||||||||||||||||||||||||||||
| 13 | 0 | ▶ | my $maybe_set_subname = sub { $ARG[1]; }; | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: not called CC=1 SCAR=1.2
| |||||||||||||||||||||||||||||
| 14 | |||||||||||||||||||||||||||||
| 15 | # Supported on Perl 5.22+ | ||||||||||||||||||||||||||||
| 16 | 1 | eval { | |||||||||||||||||||||||||||
| 17 | 1 | require Sub::Util; | |||||||||||||||||||||||||||
| 18 | |||||||||||||||||||||||||||||
| 19 | 1 | ▶ | if (my $set_subname = Sub::Util->can('set_subname')) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 20 | 1 | $maybe_set_subname = $set_subname; | |||||||||||||||||||||||||||
| 21 | } | ||||||||||||||||||||||||||||
| 22 | }; | ||||||||||||||||||||||||||||
| 23 | |||||||||||||||||||||||||||||
| 24 | 12 | ▶ | sub new { | ||||||||||||||||||||||||||
|
Subroutine
new: called CC=5 SCAR=16.1
Pod
documented
| |||||||||||||||||||||||||||||
| 25 | 12 | my ($class, %param) = @ARG; | |||||||||||||||||||||||||||
| 26 | |||||||||||||||||||||||||||||
| 27 | 12 | ▶ | croak q{Class already blessed} if blessed $class; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 28 | |||||||||||||||||||||||||||||
| 29 | 11 | my $proto; | |||||||||||||||||||||||||||
| 30 | 11 | ▶ | if (exists $param{'proto'}) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 31 | 2 | $proto = $param{'proto'}; | |||||||||||||||||||||||||||
| 32 | |||||||||||||||||||||||||||||
| 33 | 2 | ▶ | croak q{Bad argument "proto"} | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition100%2/2
builtin::blessed($proto) || ''
MC/DC100%1/1
builtin::blessed($proto) || ''
builtin::blessed($proto)
Truth table100%2/2
A
A= builtin::blessed($proto)
| |||||||||||||||||||||||||||||
| 34 | unless (blessed $proto || q{}) eq __PACKAGE__; | ||||||||||||||||||||||||||||
| 35 | } | ||||||||||||||||||||||||||||
| 36 | |||||||||||||||||||||||||||||
| 37 | 10 | return bless({}, $class) | |||||||||||||||||||||||||||
| 38 | ->_set_stash({}) | ||||||||||||||||||||||||||||
| 39 | ->_set_meta({}) | ||||||||||||||||||||||||||||
| 40 | ->set_proto($proto); | ||||||||||||||||||||||||||||
| 41 | } | ||||||||||||||||||||||||||||
| 42 | |||||||||||||||||||||||||||||
| 43 | 13 | ▶ | sub has { | ||||||||||||||||||||||||||
|
Subroutine
has: called CC=10 SCAR=23.0
Pod
documented
| |||||||||||||||||||||||||||||
| 44 | 13 | my ($self, $attr, %param) = @ARG; | |||||||||||||||||||||||||||
| 45 | |||||||||||||||||||||||||||||
| 46 | 13 | ▶ | croak q{Can't call "has" as a class method} unless blessed $self; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 47 | |||||||||||||||||||||||||||||
| 48 | 12 | ▶ | croak q{Attribute not defined} unless defined $attr and length $attr; | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition100%3/3
defined $attr and length $attr
MC/DC100%2/2
defined $attr and length $attr
defined $attr
length $attr
Truth table100%3/3
A and B
A= defined $attrB= length $attr
| |||||||||||||||||||||||||||||
| 49 | |||||||||||||||||||||||||||||
| 50 | 10 | my @patches; | |||||||||||||||||||||||||||
| 51 | |||||||||||||||||||||||||||||
| 52 | 10 | ▶ | for my $each_attr (@{ ref $attr eq 'ARRAY' ? $attr : [$attr] }) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 53 | 11 | ▶ | croak sprintf(q{Attribute "%s" invalid}, $each_attr) | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 54 | unless $each_attr =~ m{^[a-zA-Z_]\w*$}x; | ||||||||||||||||||||||||||||
| 55 | |||||||||||||||||||||||||||||
| 56 | 10 | my %patch; | |||||||||||||||||||||||||||
| 57 | |||||||||||||||||||||||||||||
| 58 | # getter | ||||||||||||||||||||||||||||
| 59 | 15 | ▶ | $patch{_define_name_of_getter($each_attr, \%param)} = sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 60 | 15 | my $self = shift; | |||||||||||||||||||||||||||
| 61 | 15 | return $self->_stash->{$attr}; | |||||||||||||||||||||||||||
| 62 | 10 | }; | |||||||||||||||||||||||||||
| 63 | |||||||||||||||||||||||||||||
| 64 | # setter | ||||||||||||||||||||||||||||
| 65 | { | ||||||||||||||||||||||||||||
| 66 | 10 | my $method_name = _define_name_of_setter($each_attr, \%param); | |||||||||||||||||||||||||||
| 67 | |||||||||||||||||||||||||||||
| 68 | 10 | ▶ | if (exists $param{'default'}) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 69 | 2 | my $default_value = $param{'default'}; | |||||||||||||||||||||||||||
| 70 | |||||||||||||||||||||||||||||
| 71 | 6 | ▶ | $patch{$method_name} = sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: called CC=3 SCAR=11.0
| |||||||||||||||||||||||||||||
| 72 | 6 | my $self = shift; | |||||||||||||||||||||||||||
| 73 | |||||||||||||||||||||||||||||
| 74 | 6 | ▶ | if (@ARG == 1) { | ||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||
| 75 | 4 | $self->_stash->{$attr} = shift; | |||||||||||||||||||||||||||
| 76 | } | ||||||||||||||||||||||||||||
| 77 | elsif (ref $default_value eq 'CODE') { | ||||||||||||||||||||||||||||
| 78 | 1 | $self->_stash->{$attr} = $maybe_set_subname->( | |||||||||||||||||||||||||||
| 79 | 'default_value', | ||||||||||||||||||||||||||||
| 80 | $default_value, | ||||||||||||||||||||||||||||
| 81 | )->($self); | ||||||||||||||||||||||||||||
| 82 | } | ||||||||||||||||||||||||||||
| 83 | else { | ||||||||||||||||||||||||||||
| 84 | 1 | $self->_stash->{$attr} = $default_value; | |||||||||||||||||||||||||||
| 85 | } | ||||||||||||||||||||||||||||
| 86 | |||||||||||||||||||||||||||||
| 87 | 6 | return $self; | |||||||||||||||||||||||||||
| 88 | 2 | }; | |||||||||||||||||||||||||||
| 89 | } | ||||||||||||||||||||||||||||
| 90 | else { | ||||||||||||||||||||||||||||
| 91 | 8 | ▶ | $patch{$method_name} = sub { | ||||||||||||||||||||||||||
|
Subroutine
__ANON__: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 92 | 8 | my ($self, $value) = @ARG; | |||||||||||||||||||||||||||
| 93 | 8 | $self->_stash->{$attr} = $value; | |||||||||||||||||||||||||||
| 94 | 8 | return $self; | |||||||||||||||||||||||||||
| 95 | 8 | }; | |||||||||||||||||||||||||||
| 96 | } | ||||||||||||||||||||||||||||
| 97 | } | ||||||||||||||||||||||||||||
| 98 | |||||||||||||||||||||||||||||
| 99 | 10 | push @patches, \%patch; | |||||||||||||||||||||||||||
| 100 | } | ||||||||||||||||||||||||||||
| 101 | |||||||||||||||||||||||||||||
| 102 | 9 | for my $each_patch (@patches) { | |||||||||||||||||||||||||||
| 103 | 10 | ▶ | while (my ($method_name, $code) = each %{ $each_patch }) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 104 | 20 | $self->_meta->{$method_name} = $maybe_set_subname->($method_name, $code); | |||||||||||||||||||||||||||
| 105 | } | ||||||||||||||||||||||||||||
| 106 | } | ||||||||||||||||||||||||||||
| 107 | |||||||||||||||||||||||||||||
| 108 | 9 | return $self; | |||||||||||||||||||||||||||
| 109 | } | ||||||||||||||||||||||||||||
| 110 | |||||||||||||||||||||||||||||
| 111 | 10 | ▶ | sub method { | ||||||||||||||||||||||||||
|
Subroutine
method: called CC=6 SCAR=17.9
Pod
documented
| |||||||||||||||||||||||||||||
| 112 | 10 | my ($self, $method_name, $code) = @ARG; | |||||||||||||||||||||||||||
| 113 | |||||||||||||||||||||||||||||
| 114 | 10 | ▶ | croak q{Can't call "method" as a class method} | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 115 | unless blessed $self; | ||||||||||||||||||||||||||||
| 116 | |||||||||||||||||||||||||||||
| 117 | 9 | ▶ | croak q{First argument must be a non empty string} | ||||||||||||||||||||||||||
|
Branch: 1 branch
Condition100%3/3
defined $method_name and length $method_name
MC/DC100%2/2
defined $method_name and length $method_name
defined $method_name
length $method_name
Truth table100%3/3
A and B
A= defined $method_nameB= length $method_name
| |||||||||||||||||||||||||||||
| 118 | unless defined $method_name and length $method_name; | ||||||||||||||||||||||||||||
| 119 | |||||||||||||||||||||||||||||
| 120 | 7 | ▶ | croak sprintf(q{First argument "%s" invalid}, $method_name) | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 121 | unless $method_name =~ m{^[a-zA-Z_]\w*$}x; | ||||||||||||||||||||||||||||
| 122 | |||||||||||||||||||||||||||||
| 123 | 6 | ▶ | croak q{Second argument must be a code ref} | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 124 | unless ref($code) eq 'CODE'; | ||||||||||||||||||||||||||||
| 125 | |||||||||||||||||||||||||||||
| 126 | 5 | $self->_meta->{$method_name} = $maybe_set_subname->($method_name, $code); | |||||||||||||||||||||||||||
| 127 | |||||||||||||||||||||||||||||
| 128 | 5 | return $self; | |||||||||||||||||||||||||||
| 129 | } | ||||||||||||||||||||||||||||
| 130 | |||||||||||||||||||||||||||||
| 131 | 45 | ▶ | sub own_method { | ||||||||||||||||||||||||||
|
Subroutine
own_method: called CC=2 SCAR=6.9
Pod
documented
| |||||||||||||||||||||||||||||
| 132 | 45 | my ($self, $method_name) = @ARG; | |||||||||||||||||||||||||||
| 133 | |||||||||||||||||||||||||||||
| 134 | 45 | ▶ | return unless exists $self->_meta->{$method_name}; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 135 | |||||||||||||||||||||||||||||
| 136 | 39 | return $self->_meta->{$method_name}; | |||||||||||||||||||||||||||
| 137 | } | ||||||||||||||||||||||||||||
| 138 | |||||||||||||||||||||||||||||
| 139 | # http://perldoc.perl.org/perlobj.html#Default-UNIVERSAL-methods | ||||||||||||||||||||||||||||
| 140 | 10 | ▶ | sub isa { | ||||||||||||||||||||||||||
|
Subroutine
isa: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||||||||||||||||||
| 141 | 1 | ▶ | no warnings 'misc'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 142 | 10 | goto &UNIVERSAL::isa; | |||||||||||||||||||||||||||
| 143 | } | ||||||||||||||||||||||||||||
| 144 | |||||||||||||||||||||||||||||
| 145 | 3 | ▶ | sub DOES { | ||||||||||||||||||||||||||
|
Subroutine
DOES: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||||||||||||||||||
| 146 | # DOES is equivalent to isa by default | ||||||||||||||||||||||||||||
| 147 | 3 | goto &isa; | |||||||||||||||||||||||||||
| 148 | } | ||||||||||||||||||||||||||||
| 149 | |||||||||||||||||||||||||||||
| 150 | 3 | ▶ | sub VERSION { | ||||||||||||||||||||||||||
|
Subroutine
VERSION: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||||||||||||||||||||
| 151 | 1 | ▶ | no warnings 'misc'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 152 | 3 | goto &UNIVERSAL::VERSION; | |||||||||||||||||||||||||||
| 153 | } | ||||||||||||||||||||||||||||
| 154 | |||||||||||||||||||||||||||||
| 155 | 17 | ▶ | sub can { | ||||||||||||||||||||||||||
|
Subroutine
can: called CC=2 SCAR=6.9
Pod
undocumented
| |||||||||||||||||||||||||||||
| 156 | 17 | my ($self, $method_name) = @ARG; | |||||||||||||||||||||||||||
| 157 | |||||||||||||||||||||||||||||
| 158 | 17 | ▶ | if (blessed $self) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 159 | 1 | ▶ | no warnings 'misc'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 160 | 10 | goto &UNIVERSAL::can; | |||||||||||||||||||||||||||
| 161 | } | ||||||||||||||||||||||||||||
| 162 | else { | ||||||||||||||||||||||||||||
| 163 | 7 | my $code; | |||||||||||||||||||||||||||
| 164 | 1 | ▶ | no warnings 'misc'; | ||||||||||||||||||||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 165 | 7 | $code = UNIVERSAL::can($self, $method_name); | |||||||||||||||||||||||||||
| 166 | |||||||||||||||||||||||||||||
| 167 | 7 | return $code; | |||||||||||||||||||||||||||
| 168 | } | ||||||||||||||||||||||||||||
| 169 | } | ||||||||||||||||||||||||||||
| 170 | |||||||||||||||||||||||||||||
| 171 | 0 | ▶ | sub DESTROY {} | ||||||||||||||||||||||||||
|
Subroutine
DESTROY: not called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 172 | |||||||||||||||||||||||||||||
| 173 | 38 | ▶ | sub AUTOLOAD { | ||||||||||||||||||||||||||
|
Subroutine
AUTOLOAD: called CC=4 SCAR=13.9
| |||||||||||||||||||||||||||||
| 174 | 38 | my ($self) = @ARG; | |||||||||||||||||||||||||||
| 175 | |||||||||||||||||||||||||||||
| 176 | 38 | ▶ | croak q{Can't call "AUTOLOAD" as a class method} unless blessed $self; | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 177 | |||||||||||||||||||||||||||||
| 178 | 37 | my ($package, $method_name) = ($AUTOLOAD =~ m{^(.+)::([^:]+)$}x); | |||||||||||||||||||||||||||
| 179 | 37 | undef $AUTOLOAD; | |||||||||||||||||||||||||||
| 180 | |||||||||||||||||||||||||||||
| 181 | 37 | ▶ | if (defined(my $code = $self->own_method($method_name))) { | ||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||
| 182 | 35 | goto &$code; | |||||||||||||||||||||||||||
| 183 | } | ||||||||||||||||||||||||||||
| 184 | elsif (defined(my $proto = $self->proto)) { | ||||||||||||||||||||||||||||
| 185 | 1 | shift @ARG; | |||||||||||||||||||||||||||
| 186 | 1 | $proto->$method_name(@ARG); | |||||||||||||||||||||||||||
| 187 | } | ||||||||||||||||||||||||||||
| 188 | else { | ||||||||||||||||||||||||||||
| 189 | 1 | croak(sprintf q{Can't locate object method "%s" in this instance}, $method_name); | |||||||||||||||||||||||||||
| 190 | } | ||||||||||||||||||||||||||||
| 191 | } | ||||||||||||||||||||||||||||
| 192 | |||||||||||||||||||||||||||||
| 193 | 4 | ▶ | sub proto { | ||||||||||||||||||||||||||
|
Subroutine
proto: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||||||||||||||||||||
| 194 | 4 | return $ARG[0]->{'proto'}; | |||||||||||||||||||||||||||
| 195 | } | ||||||||||||||||||||||||||||
| 196 | |||||||||||||||||||||||||||||
| 197 | 11 | ▶ | sub set_proto { | ||||||||||||||||||||||||||
|
Subroutine
set_proto: called CC=1 SCAR=0.0
Pod
documented
| |||||||||||||||||||||||||||||
| 198 | 11 | $ARG[0]->{'proto'} = $ARG[1]; | |||||||||||||||||||||||||||
| 199 | 11 | return $ARG[0]; | |||||||||||||||||||||||||||
| 200 | } | ||||||||||||||||||||||||||||
| 201 | |||||||||||||||||||||||||||||
| 202 | # private methods | ||||||||||||||||||||||||||||
| 203 | 14 | ▶ | sub _define_name_of_getter { | ||||||||||||||||||||||||||
|
Subroutine
_define_name_of_getter: called CC=4 SCAR=13.9
| |||||||||||||||||||||||||||||
| 204 | 14 | my ($attr, $param) = @ARG; | |||||||||||||||||||||||||||
| 205 | |||||||||||||||||||||||||||||
| 206 | 14 | my $method_name; | |||||||||||||||||||||||||||
| 207 | |||||||||||||||||||||||||||||
| 208 | 14 | ▶ | if (exists $param->{'get'}) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 209 | 13 | my $getter = $param->{'get'}; | |||||||||||||||||||||||||||
| 210 | |||||||||||||||||||||||||||||
| 211 | 13 | ▶ | if ($getter eq q{+}) { | ||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||
| 212 | 8 | $method_name = $attr; | |||||||||||||||||||||||||||
| 213 | } | ||||||||||||||||||||||||||||
| 214 | elsif ($getter eq q{-}) { | ||||||||||||||||||||||||||||
| 215 | 3 | $method_name = q{_}. $attr; | |||||||||||||||||||||||||||
| 216 | } | ||||||||||||||||||||||||||||
| 217 | else { | ||||||||||||||||||||||||||||
| 218 | 2 | $method_name = $getter; | |||||||||||||||||||||||||||
| 219 | } | ||||||||||||||||||||||||||||
| 220 | } | ||||||||||||||||||||||||||||
| 221 | else { | ||||||||||||||||||||||||||||
| 222 | 1 | $method_name = $attr; | |||||||||||||||||||||||||||
| 223 | } | ||||||||||||||||||||||||||||
| 224 | |||||||||||||||||||||||||||||
| 225 | 14 | return $method_name; | |||||||||||||||||||||||||||
| 226 | } | ||||||||||||||||||||||||||||
| 227 | |||||||||||||||||||||||||||||
| 228 | 14 | ▶ | sub _define_name_of_setter { | ||||||||||||||||||||||||||
|
Subroutine
_define_name_of_setter: called CC=4 SCAR=13.9
| |||||||||||||||||||||||||||||
| 229 | 14 | my ($attr, $param) = @ARG; | |||||||||||||||||||||||||||
| 230 | |||||||||||||||||||||||||||||
| 231 | 14 | my $method_name; | |||||||||||||||||||||||||||
| 232 | |||||||||||||||||||||||||||||
| 233 | 14 | ▶ | if (exists $param->{'set'}) { | ||||||||||||||||||||||||||
|
Branch: 1 branch
| |||||||||||||||||||||||||||||
| 234 | 13 | my $setter = $param->{'set'}; | |||||||||||||||||||||||||||
| 235 | |||||||||||||||||||||||||||||
| 236 | 13 | ▶ | if ($setter eq q{+}) { | ||||||||||||||||||||||||||
|
Branch: 2 branches
| |||||||||||||||||||||||||||||
| 237 | 8 | $method_name = q{set_}. $attr; | |||||||||||||||||||||||||||
| 238 | } | ||||||||||||||||||||||||||||
| 239 | elsif ($setter eq q{-}) { | ||||||||||||||||||||||||||||
| 240 | 3 | $method_name = q{_set_}. $attr; | |||||||||||||||||||||||||||
| 241 | } | ||||||||||||||||||||||||||||
| 242 | else { | ||||||||||||||||||||||||||||
| 243 | 2 | $method_name = $setter; | |||||||||||||||||||||||||||
| 244 | } | ||||||||||||||||||||||||||||
| 245 | } | ||||||||||||||||||||||||||||
| 246 | else { | ||||||||||||||||||||||||||||
| 247 | 1 | $method_name = q{set_}. $attr; | |||||||||||||||||||||||||||
| 248 | } | ||||||||||||||||||||||||||||
| 249 | |||||||||||||||||||||||||||||
| 250 | 14 | return $method_name; | |||||||||||||||||||||||||||
| 251 | } | ||||||||||||||||||||||||||||
| 252 | |||||||||||||||||||||||||||||
| 253 | 109 | ▶ | sub _meta { | ||||||||||||||||||||||||||
|
Subroutine
_meta: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 254 | 109 | return $ARG[0]->{'meta'}; | |||||||||||||||||||||||||||
| 255 | } | ||||||||||||||||||||||||||||
| 256 | 10 | ▶ | sub _set_meta { | ||||||||||||||||||||||||||
|
Subroutine
_set_meta: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 257 | 10 | $ARG[0]->{'meta'} = $ARG[1]; | |||||||||||||||||||||||||||
| 258 | 10 | return $ARG[0]; | |||||||||||||||||||||||||||
| 259 | } | ||||||||||||||||||||||||||||
| 260 | |||||||||||||||||||||||||||||
| 261 | 29 | ▶ | sub _stash { | ||||||||||||||||||||||||||
|
Subroutine
_stash: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 262 | 29 | return $ARG[0]->{'stash'}; | |||||||||||||||||||||||||||
| 263 | } | ||||||||||||||||||||||||||||
| 264 | 10 | ▶ | sub _set_stash { | ||||||||||||||||||||||||||
|
Subroutine
_set_stash: called CC=1 SCAR=0.0
| |||||||||||||||||||||||||||||
| 265 | 10 | $ARG[0]->{'stash'} = $ARG[1]; | |||||||||||||||||||||||||||
| 266 | 10 | return $ARG[0]; | |||||||||||||||||||||||||||
| 267 | } | ||||||||||||||||||||||||||||
| 268 | |||||||||||||||||||||||||||||
| 269 | 1 | 1; | |||||||||||||||||||||||||||
| 270 | |||||||||||||||||||||||||||||
| 271 | __END__ | ||||||||||||||||||||||||||||