Fluent/Elements/VariableReference.pm

filter: Statementstmt 88.8% 8 / 9 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 66.6% 2 / 3 Podpod 100% 1 / 1 totaltotal 84.6% 11 / 13 CC 1 SCAR 2.9
CC
1
Cov
89%
__ANON__
2.0
BEGIN
1.0
translate
1.0
CRAP 1.3
« Fluent/Elements/StringLiteral.pm ↑ Summary Fluent/Elements/AttributeAccessor.pm »
1 package Translate::Fluent::Elements::VariableReference;
2  
3 6 ▶use Moo;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 6 extends 'Translate::Fluent::Elements::Base';
5  
6 has identifier => (
7 is => 'ro',
8 0 ▶ default => sub { undef },
Subroutine __ANON__: not called CC=1 SCAR=6.9
9 6 );
10  
11 12 ▶sub translate {
Subroutine translate: called CC=1 SCAR=0.0
Pod documented
12 12 my ($self, $variables) = @_;
13  
14 # use Data::Dumper;
15 # print STDERR Dumper($self, $variables);
16  
17 12 return $variables->{ $self->identifier };
18 }
19  
20 6 1;
21 __END__
« Fluent/Elements/StringLiteral.pm ↑ Summary Fluent/Elements/AttributeAccessor.pm »