File Coverage

blib/lib/Devel/IPerl/Plugin/WebDisplay.pm
Criterion Covered Total %
statement 27 31 87.1
branch n/a
condition n/a
subroutine 13 15 86.6
pod 0 5 0.0
total 40 51 78.4


line stmt bran cond sub pod time code
1             package Devel::IPerl::Plugin::WebDisplay;
2             $Devel::IPerl::Plugin::WebDisplay::VERSION = '0.007';
3 2     2   12 use strict;
  2         26  
  2         52  
4 2     2   19 use warnings;
  2         4  
  2         50  
5              
6 2     2   523 use Devel::IPerl::Display::HTML;
  2         5  
  2         61  
7 2     2   597 use Devel::IPerl::Display::JS;
  2         5  
  2         55  
8 2     2   594 use Devel::IPerl::Display::CSS;
  2         5  
  2         57  
9 2     2   561 use Devel::IPerl::Display::IFrame;
  2         6  
  2         382  
10              
11             sub register {
12 2     2 0 6 my ($self, $iperl) = @_;
13             # TODO generalise the plugin registration
14 2         6 for my $name (qw(html css js iframe)) {
15 8     4   37 $iperl->helper( $name => sub { shift; $self->$name(@_) } );
  4     4   6312  
  4     4   24  
        4      
16             }
17             }
18              
19 0     0 0 0 sub html { shift; Devel::IPerl::Display::HTML->new(@_) }
  0         0  
20 2     2 0 4 sub css { shift; Devel::IPerl::Display::CSS->new(@_) }
  2         37  
21 2     2 0 4 sub js { shift; Devel::IPerl::Display::JS->new(@_) }
  2         37  
22              
23 0     0 0   sub iframe { shift; Devel::IPerl::Display::IFrame->new(@_) }
  0            
24              
25             1;
26              
27             __END__
28              
29             =pod
30              
31             =encoding UTF-8
32              
33             =head1 NAME
34              
35             Devel::IPerl::Plugin::WebDisplay
36              
37             =head1 VERSION
38              
39             version 0.007
40              
41             =head1 AUTHOR
42              
43             Zakariyya Mughal <zmughal@cpan.org>
44              
45             =head1 COPYRIGHT AND LICENSE
46              
47             This software is copyright (c) 2014 by Zakariyya Mughal.
48              
49             This is free software; you can redistribute it and/or modify it under
50             the same terms as the Perl 5 programming language system itself.
51              
52             =cut