SRS/Password.pm

filter: Statementstmt 100% 12 / 12 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 100% 4 / 4 Podpod n/a totaltotal 100% 16 / 16 SCAR 0.0
CC
1
Cov
100%
BEGIN
1.0
BEGIN
1.0
BEGIN
1.0
CRAP 1.0
« SRS/GetMessages/TypeFilter.pm ↑ Summary SRS/Query.pm »
1  
2 package XML::SRS::Password;
3  
4 1 ▶use Moose;
Subroutine BEGIN: called CC=1 SCAR=0.0
5 1 ▶use PRANG::Graph;
Subroutine BEGIN: called CC=1 SCAR=0.0
6 1 ▶use Crypt::Password;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 ▶use Moose::Util::TypeConstraints;
Subroutine BEGIN: called CC=1 SCAR=0.0
8  
9 class_type "Crypt::Password";
10  
11 has_attr 'crypted' =>
12 is => "ro",
13 isa => "Crypt::Password",
14 handles => [qw/check/],
15 xml_name => "Password",
16 required => 1,
17 coerce => 1,
18 ;
19  
20 coerce "Crypt::Password"
21 => from "Str"
22 => via {
23 password($_);
24 };
25  
26 with 'XML::SRS::Node';
27  
28 coerce __PACKAGE__
29 => from "Str"
30 => via {
31 __PACKAGE__->new(crypted => password($_));
32 },
33 => from "Crypt::Password"
34 => via {
35 __PACKAGE__->new(crypted => $_);
36 };
37 1;
« SRS/GetMessages/TypeFilter.pm ↑ Summary SRS/Query.pm »