File Coverage

blib/lib/Locale/CLDR/Locales/En/Any/Mt.pm
Criterion Covered Total %
statement 23 23 100.0
branch n/a
condition n/a
subroutine 8 8 100.0
pod n/a
total 31 31 100.0


line stmt bran cond sub pod time code
1             =head1
2              
3             Locale::CLDR::Locales::En::Any::Mt - Package for language English
4              
5             =cut
6              
7             package Locale::CLDR::Locales::En::Any::Mt;
8             # This file auto generated from Data\common\main\en_MT.xml
9             # on Sun 24 Apr 8:24:47 am GMT
10              
11 1     1   904 use version;
  1         1  
  1         5  
12              
13             our $VERSION = version->declare('v0.29.0');
14              
15 1     1   81 use v5.10.1;
  1         3  
16 1     1   3 use mro 'c3';
  1         1  
  1         5  
17 1     1   30 use utf8;
  1         1  
  1         6  
18 1     1   25 use if $^V ge v5.12.0, feature => 'unicode_strings';
  1         2  
  1         18  
19              
20 1     1   87 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         1  
  1         6  
21 1     1   648 use Moo;
  1         2  
  1         4  
22              
23             extends('Locale::CLDR::Locales::En::Any::001');
24             has 'currencies' => (
25             is => 'ro',
26             isa => HashRef,
27             init_arg => undef,
28             default => sub { {
29             'GBP' => {
30             symbol => 'GB£',
31             },
32             } },
33             );
34              
35              
36             has 'day_period_data' => (
37             is => 'ro',
38             isa => CodeRef,
39             init_arg => undef,
40             default => sub { sub {
41             # Time in hhmm format
42             my ($self, $type, $time, $day_period_type) = @_;
43             $day_period_type //= 'default';
44             SWITCH:
45             for ($type) {
46             if ($_ eq 'gregorian') {
47             if($day_period_type eq 'default') {
48             return 'noon' if $time == 1200;
49             return 'midnight' if $time == 0;
50             return 'evening1' if $time >= 1800
51             && $time < 2100;
52             return 'night1' if $time >= 2100;
53             return 'night1' if $time < 600;
54             return 'afternoon1' if $time >= 1200
55             && $time < 1800;
56             return 'morning1' if $time >= 600
57             && $time < 1200;
58             }
59             if($day_period_type eq 'selection') {
60             return 'afternoon1' if $time >= 1200
61             && $time < 1800;
62             return 'morning1' if $time >= 600
63             && $time < 1200;
64             return 'night1' if $time >= 2100;
65             return 'night1' if $time < 600;
66             return 'evening1' if $time >= 1800
67             && $time < 2100;
68             }
69             last SWITCH;
70             }
71             if ($_ eq 'generic') {
72             if($day_period_type eq 'default') {
73             return 'noon' if $time == 1200;
74             return 'midnight' if $time == 0;
75             return 'evening1' if $time >= 1800
76             && $time < 2100;
77             return 'night1' if $time >= 2100;
78             return 'night1' if $time < 600;
79             return 'afternoon1' if $time >= 1200
80             && $time < 1800;
81             return 'morning1' if $time >= 600
82             && $time < 1200;
83             }
84             if($day_period_type eq 'selection') {
85             return 'afternoon1' if $time >= 1200
86             && $time < 1800;
87             return 'morning1' if $time >= 600
88             && $time < 1200;
89             return 'night1' if $time >= 2100;
90             return 'night1' if $time < 600;
91             return 'evening1' if $time >= 1800
92             && $time < 2100;
93             }
94             last SWITCH;
95             }
96             }
97             } },
98             );
99              
100             around day_period_data => sub {
101             my ($orig, $self) = @_;
102             return $self->$orig;
103             };
104              
105             has 'eras' => (
106             is => 'ro',
107             isa => HashRef,
108             init_arg => undef,
109             default => sub { {
110             'generic' => {
111             },
112             'gregorian' => {
113             },
114             } },
115             );
116              
117             has 'date_formats' => (
118             is => 'ro',
119             isa => HashRef,
120             init_arg => undef,
121             default => sub { {
122             'generic' => {
123             'long' => q{dd MMMM y G},
124             'medium' => q{dd MMM y G},
125             },
126             'gregorian' => {
127             'long' => q{dd MMMM y},
128             'medium' => q{dd MMM y},
129             },
130             } },
131             );
132              
133             has 'time_formats' => (
134             is => 'ro',
135             isa => HashRef,
136             init_arg => undef,
137             default => sub { {
138             'generic' => {
139             },
140             'gregorian' => {
141             'full' => q{HH:mm:ss zzzz},
142             'long' => q{HH:mm:ss z},
143             'medium' => q{HH:mm:ss},
144             'short' => q{HH:mm},
145             },
146             } },
147             );
148              
149             has 'datetime_formats' => (
150             is => 'ro',
151             isa => HashRef,
152             init_arg => undef,
153             default => sub { {
154             'generic' => {
155             },
156             'gregorian' => {
157             },
158             } },
159             );
160              
161             has 'datetime_formats_available_formats' => (
162             is => 'ro',
163             isa => HashRef,
164             init_arg => undef,
165             default => sub { {
166             'generic' => {
167             MMMd => q{dd MMM},
168             yyyyMMMEd => q{E, dd MMM y G},
169             yyyyMMMd => q{dd MMM y G},
170             },
171             'gregorian' => {
172             MMMd => q{dd MMM},
173             yMMMEd => q{E, dd MMM y},
174             yMMMd => q{dd MMM y},
175             },
176             } },
177             );
178              
179             has 'datetime_formats_append_item' => (
180             is => 'ro',
181             isa => HashRef,
182             init_arg => undef,
183             default => sub { {
184             } },
185             );
186              
187             has 'datetime_formats_interval' => (
188             is => 'ro',
189             isa => HashRef,
190             init_arg => undef,
191             default => sub { {
192             'generic' => {
193             MEd => {
194             M => q{E, dd/MM – E, dd/MM},
195             d => q{E, dd/MM – E, dd/MM},
196             },
197             MMMEd => {
198             M => q{E, dd MMM – E, dd MMM},
199             d => q{E, dd – E, dd MMM},
200             },
201             MMMd => {
202             M => q{dd MMM – dd MMM},
203             d => q{dd – dd MMM},
204             },
205             yM => {
206             M => q{MM/y – MM/y G},
207             y => q{MM/y – MM/y G},
208             },
209             yMEd => {
210             M => q{E, dd/MM/y – E, dd/MM/y G},
211             d => q{E, dd/MM/y – E, dd/MM/y G},
212             y => q{E, dd/MM/y – E, dd/MM/y G},
213             },
214             yMMMd => {
215             M => q{dd MMM – dd MMM y G},
216             d => q{dd – dd MMM y G},
217             y => q{dd MMM y – dd MMM y G},
218             },
219             yMd => {
220             M => q{dd/MM/y – dd/MM/y G},
221             d => q{dd/MM/y – dd/MM/y G},
222             y => q{dd/MM/y – dd/MM/y G},
223             },
224             },
225             'gregorian' => {
226             MEd => {
227             M => q{E, dd/MM – E, dd/MM},
228             d => q{E, dd/MM – E, dd/MM},
229             },
230             MMMEd => {
231             M => q{E, dd MMM – E, dd MMM},
232             d => q{E, dd – E, dd MMM},
233             },
234             MMMd => {
235             M => q{dd MMM – dd MMM},
236             d => q{dd – dd MMM},
237             },
238             yMMMd => {
239             M => q{dd MMM – dd MMM y},
240             d => q{dd – dd MMM y},
241             y => q{dd MMM y – dd MMM y},
242             },
243             },
244             } },
245             );
246              
247 1     1   2350 no Moo;
  1         2  
  1         4  
248              
249             1;
250              
251             # vim: tabstop=4