blib/lib/Lingua/IND/Nums2Words.pm

filter: Statementstmt 82.5% 33 / 40 Branchbran 0.0% 0 / 2 Conditioncond 0.0% 0 / 4 MC/DCmcdc 0.0% 0 / 2 Subroutinesub 80.0% 12 / 15 Podpod 100% 2 / 2 totaltotal 72.3% 47 / 65 CC 4 SCAR 16.6
CC
4
Cov
72%
parse
20.0
new
2.0
BEGIN
1.0
CRAP 5.3
↑ Summary
1 # For Emacs: -*- mode:cperl; eval: (folding-mode 1) -*-
2  
3 package Lingua::IND::Nums2Words;
4 # ABSTRACT: This module is deprecated. Please use Lingua::IND::Num2Word instead.
5  
6 1 ▶use 5.16.0;
Subroutine BEGIN: called CC=1 SCAR=0.0
7 1 ▶use utf8;
Subroutine BEGIN: called CC=1 SCAR=0.0
8 1 ▶use warnings;
Subroutine BEGIN: called CC=1 SCAR=0.0
9  
10 # {{{ use block
11  
12 1 ▶use Carp;
Subroutine BEGIN: called CC=1 SCAR=0.0
13 1 ▶use Export::Attrs;
Subroutine BEGIN: called CC=1 SCAR=0.0
14 1 ▶use Lingua::IND::Num2Word qw(num2ind_cardinal nums2words nums2words_simple);
Subroutine BEGIN: called CC=1 SCAR=0.0
15  
16 # }}}
17 # {{{ var block
18  
19 1 our $VERSION = '0.2603270';
20  
21 # }}}
22  
23 # {{{ re-export from Num2Word
24  
25 0 ▶sub num2ind_cardinal :Export { goto &Lingua::IND::Num2Word::num2ind_cardinal }
Subroutine BEGIN: called CC=1 SCAR=0.2
Subroutine num2ind_cardinal: not called CC=1 SCAR=0.2
26 1 ▶sub nums2words :Export { goto &Lingua::IND::Num2Word::nums2words }
Subroutine BEGIN: called CC=1 SCAR=0.0
Subroutine nums2words: called CC=1 SCAR=0.0
27 1 ▶sub nums2words_simple :Export { goto &Lingua::IND::Num2Word::nums2words_simple }
Subroutine BEGIN: called CC=1 SCAR=0.0
Subroutine nums2words_simple: called CC=1 SCAR=0.0
28  
29 # }}}
30 # {{{ new constructor (deprecated)
31  
32 0 ▶sub new {
Subroutine new: not called CC=1 SCAR=6.9
Pod documented
33 0 my $class = shift;
34 0 carp "Lingua::IND::Nums2Words is deprecated, use Lingua::IND::Num2Word instead";
35 0 return Lingua::IND::Num2Word->new(@_);
36 }
37  
38 # }}}
39 # {{{ parse delegate to Num2Word (deprecated)
40  
41 0 ▶sub parse :Export {
Subroutine parse: not called CC=4 SCAR=30.0
Pod documented
42 0 ▶ my $self = ref($_[0]) ? shift : __PACKAGE__->new();
Branch: 1 branch
BranchTrueFalseTotal
ref $_[0] ? : 0 0 0
43 0 ▶ my $number = shift // return '';
Condition0%0/2
shift() // (return "")
l!l
00
MC/DC0%0/1
shift() // (return "")
shift()
Truth table0%0/2
A
A= shift()
Aresult
11
00
44  
45 0 ▶ return num2ind_cardinal($number) // '';
Condition0%0/2
num2ind_cardinal($number) // ""
l!l
00
MC/DC0%0/1
num2ind_cardinal($number) // ""
num2ind_cardinal($number)
Truth table0%0/2
A
A= num2ind_cardinal($number)
Aresult
11
00
46 1 ▶}
Subroutine BEGIN: called CC=1 SCAR=0.0
47  
48 # }}}
49  
50 1 1;
51  
52 __END__
↑ Summary