File Coverage

blib/lib/Lingua/FR/Ladl/Exceptions.pm
Criterion Covered Total %
statement 10 12 83.3
branch n/a
condition n/a
subroutine 4 4 100.0
pod n/a
total 14 16 87.5


line stmt bran cond sub pod time code
1             package Lingua::FR::Ladl::Exceptions;
2              
3 1     1   2665 use warnings;
  1         3  
  1         43  
4 1     1   5 use strict;
  1         3  
  1         48  
5              
6 1     1   15 use version; our $VERSION = qv('0.0.3');
  1         2  
  1         8  
7              
8             use Exception::Class (
9 0           'X::NoTableData' => {
10             fields => [ 'table' ],
11             },
12             'X::NoGraphData' => {
13             fields => [ 'graph' ],
14             },
15 1     1   674 );
  0            
16              
17             sub X::NoTableData::full_message {
18             my ($self) = @_;
19              
20             my $msg = $self->message();
21            
22             return $msg.'Need table data for "'.$self->table()->get_name().q(").qq(, maybe you should call the load method first?\n);
23             };
24              
25             sub X::NoGraphData::full_message {
26             my ($self) = @_;
27              
28             my $msg = $self->message();
29            
30             return $msg.'Graph not initialized: "'.$self->graph()->get_name().q(").qq(, maybe you should call the load method first?\n);
31             };
32              
33              
34              
35             1;
36             __END__