line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
4
|
|
|
4
|
|
401995
|
use strict; |
|
4
|
|
|
|
|
9
|
|
|
4
|
|
|
|
|
148
|
|
2
|
4
|
|
|
4
|
|
16
|
use warnings; |
|
4
|
|
|
|
|
5
|
|
|
4
|
|
|
|
|
181
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
package Tiny::OpenSSL::Role::Entity; |
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
# ABSTRACT: Provides common tasks for Tiny::OpenSSL objects. |
7
|
|
|
|
|
|
|
our $VERSION = '0.1.1'; # VERSION |
8
|
|
|
|
|
|
|
|
9
|
4
|
|
|
4
|
|
16
|
use Moo::Role; |
|
4
|
|
|
|
|
4
|
|
|
4
|
|
|
|
|
48
|
|
10
|
4
|
|
|
4
|
|
1109
|
use Types::Standard qw( Str InstanceOf ); |
|
4
|
|
|
|
|
6
|
|
|
4
|
|
|
|
|
34
|
|
11
|
4
|
|
|
4
|
|
2019
|
use Path::Tiny; |
|
4
|
|
|
|
|
5
|
|
|
4
|
|
|
|
|
653
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
has ascii => ( is => 'rw', isa => Str ); |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
has file => ( |
16
|
|
|
|
|
|
|
is => 'rw', |
17
|
|
|
|
|
|
|
isa => InstanceOf ['Path::Tiny'], |
18
|
|
|
|
|
|
|
default => sub { return Path::Tiny->tempfile; } |
19
|
|
|
|
|
|
|
); |
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub write { |
22
|
1
|
|
|
1
|
1
|
6551
|
my $self = shift; |
23
|
|
|
|
|
|
|
|
24
|
1
|
50
|
|
|
|
5
|
if ( $self->file ) { |
25
|
1
|
|
|
|
|
52
|
$self->file->spew( $self->ascii ); |
26
|
|
|
|
|
|
|
} |
27
|
|
|
|
|
|
|
|
28
|
1
|
|
|
|
|
507
|
return 1; |
29
|
|
|
|
|
|
|
} |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
1; |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
__END__ |