File Coverage

blib/lib/Locale/CLDR/Locales/Ru/Any/Ua.pm
Criterion Covered Total %
statement 29 29 100.0
branch n/a
condition n/a
subroutine 10 10 100.0
pod n/a
total 39 39 100.0


line stmt bran cond sub pod time code
1             =encoding utf8
2              
3             =head1
4              
5             Locale::CLDR::Locales::Ru::Any::Ua - Package for language Russian
6              
7             =cut
8              
9             # This file auto generated from Data/common/main/ru_UA.xml
10             # on Mon 11 Apr 5:37:23 pm GMT
11              
12             use strict;
13 1     1   766 use warnings;
  1         2  
  1         22  
14 1     1   4 use version;
  1         1  
  1         16  
15 1     1   4  
  1         2  
  1         4  
16             our $VERSION = version->declare('v0.34.1');
17              
18             use v5.10.1;
19 1     1   73 use mro 'c3';
  1         3  
20 1     1   6 use utf8;
  1         1  
  1         18  
21 1     1   26 use if $^V ge v5.12.0, feature => 'unicode_strings';
  1         1  
  1         4  
22 1     1   23 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         2  
  1         8  
23 1     1   89 use Moo;
  1         2  
  1         4  
24 1     1   799  
  1         1  
  1         5  
25             extends('Locale::CLDR::Locales::Ru::Any');
26             has 'display_name_region' => (
27             is => 'ro',
28             isa => HashRef[Str],
29             init_arg => undef,
30             default => sub {
31             {
32             'AC' => 'О-в Вознесения',
33             'AE' => 'Объединенные Арабские Эмираты',
34             'BV' => 'О-в Буве',
35             'CK' => 'О-ва Кука',
36             'CP' => 'О-в Клиппертон',
37             'CX' => 'О-в Рождества',
38             'HM' => 'О-ва Херд и Макдональд',
39             'NF' => 'О-в Норфолк',
40             'TL' => 'Тимор-Лесте',
41             'UM' => 'Малые Тихоокеанские Отдаленные Острова США',
42              
43             }
44             },
45             );
46              
47             has 'minimum_grouping_digits' => (
48             is =>'ro',
49             isa => Int,
50             init_arg => undef,
51             default => 2,
52             );
53              
54             has 'day_period_data' => (
55             is => 'ro',
56             isa => CodeRef,
57             init_arg => undef,
58             default => sub { sub {
59             # Time in hhmm format
60             my ($self, $type, $time, $day_period_type) = @_;
61             $day_period_type //= 'default';
62             SWITCH:
63             for ($type) {
64             if ($_ eq 'generic') {
65             if($day_period_type eq 'default') {
66             return 'midnight' if $time == 0;
67             return 'noon' if $time == 1200;
68             return 'afternoon1' if $time >= 1200
69             && $time < 1800;
70             return 'evening1' if $time >= 1800
71             && $time < 2400;
72             return 'morning1' if $time >= 400
73             && $time < 1200;
74             return 'night1' if $time >= 0
75             && $time < 400;
76             }
77             if($day_period_type eq 'selection') {
78             return 'afternoon1' if $time >= 1200
79             && $time < 1800;
80             return 'evening1' if $time >= 1800
81             && $time < 2400;
82             return 'morning1' if $time >= 400
83             && $time < 1200;
84             return 'night1' if $time >= 0
85             && $time < 400;
86             }
87             last SWITCH;
88             }
89             if ($_ eq 'gregorian') {
90             if($day_period_type eq 'default') {
91             return 'midnight' if $time == 0;
92             return 'noon' if $time == 1200;
93             return 'afternoon1' if $time >= 1200
94             && $time < 1800;
95             return 'evening1' if $time >= 1800
96             && $time < 2400;
97             return 'morning1' if $time >= 400
98             && $time < 1200;
99             return 'night1' if $time >= 0
100             && $time < 400;
101             }
102             if($day_period_type eq 'selection') {
103             return 'afternoon1' if $time >= 1200
104             && $time < 1800;
105             return 'evening1' if $time >= 1800
106             && $time < 2400;
107             return 'morning1' if $time >= 400
108             && $time < 1200;
109             return 'night1' if $time >= 0
110             && $time < 400;
111             }
112             last SWITCH;
113             }
114             }
115             } },
116             );
117              
118             around day_period_data => sub {
119             my ($orig, $self) = @_;
120             return $self->$orig;
121             };
122              
123             has 'eras' => (
124             is => 'ro',
125             isa => HashRef,
126             init_arg => undef,
127             default => sub { {
128             'generic' => {
129             },
130             'gregorian' => {
131             },
132             } },
133             );
134              
135             has 'date_formats' => (
136             is => 'ro',
137             isa => HashRef,
138             init_arg => undef,
139             default => sub { {
140             'generic' => {
141             },
142             'gregorian' => {
143             },
144             } },
145             );
146              
147             has 'time_formats' => (
148             is => 'ro',
149             isa => HashRef,
150             init_arg => undef,
151             default => sub { {
152             'generic' => {
153             },
154             'gregorian' => {
155             },
156             } },
157             );
158              
159             has 'datetime_formats' => (
160             is => 'ro',
161             isa => HashRef,
162             init_arg => undef,
163             default => sub { {
164             'generic' => {
165             },
166             'gregorian' => {
167             },
168             } },
169             );
170              
171             has 'datetime_formats_available_formats' => (
172             is => 'ro',
173             isa => HashRef,
174             init_arg => undef,
175             default => sub { {
176             'gregorian' => {
177             GyMMM => q{LLL y 'г'. G},
178             yMEd => q{ccc, d.MM.y},
179             },
180             } },
181             );
182              
183             has 'datetime_formats_append_item' => (
184             is => 'ro',
185             isa => HashRef,
186             init_arg => undef,
187             default => sub { {
188             } },
189             );
190              
191             has 'datetime_formats_interval' => (
192             is => 'ro',
193             isa => HashRef,
194             init_arg => undef,
195             default => sub { {
196             'generic' => {
197             H => {
198             H => q{HH–HH 'ч'.},
199             },
200             Hv => {
201             H => q{HH–HH 'ч'., v},
202             },
203             MMMEd => {
204             M => q{E, d MMM – E, d MMM},
205             d => q{E, d – E, d MMM},
206             },
207             h => {
208             h => q{h–h 'ч'. a},
209             },
210             hv => {
211             h => q{h–h 'ч'. a, v},
212             },
213             yMEd => {
214             M => q{E, dd.MM.y – E, dd.MM.y},
215             d => q{E, dd.MM.y – E, dd.MM.y},
216             y => q{E, dd.MM.y – E, dd.MM.y},
217             },
218             yMMM => {
219             M => q{MMM–MMM y},
220             y => q{MMM y – MMM y},
221             },
222             yMMMEd => {
223             M => q{E, d MMM – E, d MMM y 'г'.},
224             d => q{E, d – E, d MMM y 'г'.},
225             y => q{E, d MMM y – E, d MMM y 'г'.},
226             },
227             yMMMM => {
228             M => q{LLLL–LLLL y},
229             y => q{LLLL y – LLLL y},
230             },
231             yMMMd => {
232             M => q{d MMM – d MMM y},
233             d => q{d–d MMM y},
234             y => q{d MMM y – d MMM y},
235             },
236             },
237             'gregorian' => {
238             yMMM => {
239             y => q{LLL y – LLL y},
240             },
241             yMMMEd => {
242             y => q{ccc, d MMM y – ccc, d MMM y},
243             },
244             yMMMM => {
245             y => q{LLLL y – LLLL y},
246             },
247             yMMMd => {
248             y => q{d MMM y – d MMM y},
249             },
250             },
251             } },
252             );
253              
254             no Moo;
255 1     1   1052  
  1         2  
  1         3  
256             1;
257              
258             # vim: tabstop=4