| 1 | package CLDR::Number::Format::Decimal; | ||||||||||
| 2 | |||||||||||
| 3 | 13 | ▶ | use v5.8.1; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | 13 | ▶ | use utf8; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 5 | 13 | ▶ | use Carp; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 6 | |||||||||||
| 7 | 13 | ▶ | use Moo; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 8 | 13 | ▶ | use namespace::clean; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 9 | |||||||||||
| 10 | 13 | our $VERSION = '0.17'; | |||||||||
| 11 | |||||||||||
| 12 | 13 | with qw( CLDR::Number::Role::Format ); | |||||||||
| 13 | |||||||||||
| 14 | 13 | has _pattern_type => ( | |||||||||
| 15 | is => 'ro', | ||||||||||
| 16 | default => 'decimal', | ||||||||||
| 17 | ); | ||||||||||
| 18 | |||||||||||
| 19 | ▶ | sub BUILD {} | |||||||||
|
Subroutine
BUILD: called CC=1 SCAR=0.0
Pod
undocumented
| |||||||||||
| 20 | |||||||||||
| 21 | sub format { | ||||||||||
| 22 | 156 | ▶ | my ($self, $num) = @_; | ||||||||
|
Subroutine
format: called CC=2 SCAR=6.9
Pod
documented
| |||||||||||
| 23 | |||||||||||
| 24 | 156 | $num = $self->_validate_number(format => $num); | |||||||||
| 25 | 156 | ▶ | return undef unless defined $num; | ||||||||
|
Branch: 1 branch
| |||||||||||
| 26 | |||||||||||
| 27 | 155 | return $self->_format_number($num); | |||||||||
| 28 | } | ||||||||||
| 29 | |||||||||||
| 30 | 13 | 1; | |||||||||
| 31 | |||||||||||
| 32 | __END__ | ||||||||||