File Coverage

blib/lib/WebService/IMDB/Goof.pm
Criterion Covered Total %
statement 22 22 100.0
branch 1 2 50.0
condition n/a
subroutine 5 5 100.0
pod n/a
total 28 29 96.5


line stmt bran cond sub pod time code
1             # $Id: Goof.pm 7370 2012-04-09 01:17:33Z chris $
2              
3             =head1 NAME
4              
5             WebService::IMDB::Goof
6              
7             =cut
8              
9             package WebService::IMDB::Goof;
10              
11 2     2   12 use strict;
  2         3  
  2         61  
12 2     2   10 use warnings;
  2         5  
  2         75  
13              
14             our $VERSION = '0.05';
15              
16 2     2   10 use base qw(Class::Accessor);
  2         3  
  2         135  
17              
18 2     2   20 use Carp;
  2         4  
  2         440  
19             our @CARP_NOT = qw(WebService::IMDB WebService::IMDB::Title);
20              
21             __PACKAGE__->mk_accessors(qw(
22             spoiler
23              
24             text
25             type
26             ));
27              
28              
29             =head1 METHODS
30              
31             =head2 spoiler
32              
33             =head2 text
34              
35             =head2 type
36              
37             =cut
38              
39             sub _new {
40 34     34   280 my $class = shift;
41 34         38 my $ws = shift;
42 34 50       67 my $data = shift or die;
43 34         41 my $spoiler = shift;
44              
45 34         45 my $self = {};
46              
47 34         68 bless $self, $class;
48              
49 34         89 $self->text($data->{'text'});
50 34         344 $self->type($data->{'type'});
51              
52 34         336 $self->spoiler($spoiler);
53              
54 34         340 return $self;
55             }
56              
57             1;