Devel/IPerl/Display/Role/Bytestream.pm

filter: Statementstmt 65.0% 13 / 20 Branchbran 0.0% 0 / 2 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 60.0% 3 / 5 Podpod 0.0% 0 / 2 totaltotal 55.1% 16 / 29 CC 2 SCAR 10.4
CC
2
Cov
59%
BUILDARGS
6.0
iperl_data_representations
2.0
BEGIN
1.0
CRAP 2.8
« Devel/IPerl/Message/ZMQ.pm ↑ Summary Devel/IPerl/Kernel/Backend/DevelREPL.pm »
1 package Devel::IPerl::Display::Role::Bytestream;
2 2 $Devel::IPerl::Display::Role::Bytestream::VERSION = '0.012';
3 2 ▶use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
4 2 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
5  
6 2 ▶use Moo::Role;
Subroutine BEGIN: called CC=1 SCAR=0.0
7  
8 2 with qw(Devel::IPerl::Display::Role::MIMEType);
9  
10 2 has bytestream => ( is => 'rw' );
11  
12 0 ▶sub BUILDARGS {
Subroutine BUILDARGS: not called CC=2 SCAR=17.9
Pod undocumented
13 0 my ( $class, @args ) = @_;
14  
15 # if first arg is data that needs to be determined
16 0 ▶ if( @args % 2 == 1 ) {
Branch: 1 branch
BranchTrueFalseTotal
if (@args % 2 == 1) 0 0 0
17 0 my $data = shift @args;
18 0 unshift @args, bytestream => $data;
19 }
20  
21 0 return { @args };
22 };
23  
24 0 ▶sub iperl_data_representations {
Subroutine iperl_data_representations: not called CC=1 SCAR=6.9
Pod undocumented
25 0 my ($self) = @_;
26 return {
27 0 $self->mimetype => $self->bytestream,
28 };
29 }
30  
31 2 1;
32  
33 __END__
« Devel/IPerl/Message/ZMQ.pm ↑ Summary Devel/IPerl/Kernel/Backend/DevelREPL.pm »