File Coverage

blib/lib/Locale/CLDR/Locales/Zh/Hans/Hk.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 NAME
4              
5             Locale::CLDR::Locales::Zh::Hans::Hk - Package for language Chinese
6              
7             =cut
8              
9             package Locale::CLDR::Locales::Zh::Hans::Hk;
10             # This file auto generated from Data\common\main\zh_Hans_HK.xml
11             # on Fri 17 Jan 12:03:31 pm GMT
12              
13 1     1   5649 use strict;
  1         2  
  1         42  
14 1     1   6 use warnings;
  1         2  
  1         52  
15 1     1   7 use version;
  1         2  
  1         45  
16              
17             our $VERSION = version->declare('v0.46.0');
18              
19 1     1   150 use v5.12.0;
  1         4  
20 1     1   7 use mro 'c3';
  1         2  
  1         8  
21 1     1   54 use utf8;
  1         3  
  1         9  
22 1     1   82 use feature 'unicode_strings';
  1         3  
  1         283  
23 1     1   12 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         4  
  1         12  
24 1     1   6951 use Moo;
  1         6  
  1         11  
25              
26             extends('Locale::CLDR::Locales::Zh::Hans');
27             has 'units' => (
28             is => 'ro',
29             isa => HashRef[HashRef[HashRef[Str]]],
30             init_arg => undef,
31             default => sub { {
32             'long' => {
33             # Long Unit Identifier
34             'concentr-karat' => {
35             'name' => q(开),
36             'other' => q({0}开),
37             },
38             # Core Unit Identifier
39             'karat' => {
40             'name' => q(开),
41             'other' => q({0}开),
42             },
43             # Long Unit Identifier
44             'duration-second' => {
45             'other' => q({0}秒),
46             },
47             # Core Unit Identifier
48             'second' => {
49             'other' => q({0}秒),
50             },
51             # Long Unit Identifier
52             'per' => {
53             '1' => q({0}/{1}),
54             },
55             # Core Unit Identifier
56             'per' => {
57             '1' => q({0}/{1}),
58             },
59             # Long Unit Identifier
60             'temperature-kelvin' => {
61             'name' => q(开氏度),
62             'other' => q({0}开氏度),
63             },
64             # Core Unit Identifier
65             'kelvin' => {
66             'name' => q(开氏度),
67             'other' => q({0}开氏度),
68             },
69             },
70             'narrow' => {
71             # Long Unit Identifier
72             'concentr-karat' => {
73             'other' => q({0}开),
74             },
75             # Core Unit Identifier
76             'karat' => {
77             'other' => q({0}开),
78             },
79             # Long Unit Identifier
80             'length-foot' => {
81             'other' => q({0}英尺),
82             },
83             # Core Unit Identifier
84             'foot' => {
85             'other' => q({0}英尺),
86             },
87             # Long Unit Identifier
88             'length-inch' => {
89             'other' => q({0}英寸),
90             },
91             # Core Unit Identifier
92             'inch' => {
93             'other' => q({0}英寸),
94             },
95             # Long Unit Identifier
96             'length-light-year' => {
97             'other' => q({0}光年),
98             },
99             # Core Unit Identifier
100             'light-year' => {
101             'other' => q({0}光年),
102             },
103             # Long Unit Identifier
104             'length-mile' => {
105             'other' => q({0}英里),
106             },
107             # Core Unit Identifier
108             'mile' => {
109             'other' => q({0}英里),
110             },
111             # Long Unit Identifier
112             'length-picometer' => {
113             'other' => q({0}皮米),
114             },
115             # Core Unit Identifier
116             'picometer' => {
117             'other' => q({0}皮米),
118             },
119             # Long Unit Identifier
120             'length-yard' => {
121             'other' => q({0}码),
122             },
123             # Core Unit Identifier
124             'yard' => {
125             'other' => q({0}码),
126             },
127             },
128             'short' => {
129             # Long Unit Identifier
130             'acceleration-g-force' => {
131             'other' => q({0}G力),
132             },
133             # Core Unit Identifier
134             'g-force' => {
135             'other' => q({0}G力),
136             },
137             # Long Unit Identifier
138             'concentr-karat' => {
139             'name' => q(开),
140             'other' => q({0}开),
141             },
142             # Core Unit Identifier
143             'karat' => {
144             'name' => q(开),
145             'other' => q({0}开),
146             },
147             # Long Unit Identifier
148             'temperature-kelvin' => {
149             'name' => q(开氏度),
150             'other' => q({0}°K),
151             },
152             # Core Unit Identifier
153             'kelvin' => {
154             'name' => q(开氏度),
155             'other' => q({0}°K),
156             },
157             },
158             } }
159             );
160              
161             has 'currencies' => (
162             is => 'ro',
163             isa => HashRef,
164             init_arg => undef,
165             default => sub { {
166             'CNY' => {
167             symbol => 'CN¥',
168             },
169             'KYD' => {
170             display_name => {
171             'currency' => q(开曼群岛元),
172             },
173             },
174             'NIO' => {
175             display_name => {
176             'other' => q(尼加拉瓜科多巴),
177             },
178             },
179             'XAG' => {
180             display_name => {
181             'currency' => q(白银),
182             'other' => q(白银),
183             },
184             },
185             } },
186             );
187              
188              
189             has 'day_period_data' => (
190             is => 'ro',
191             isa => CodeRef,
192             init_arg => undef,
193             default => sub { sub {
194             # Time in hhmm format
195             my ($self, $type, $time, $day_period_type) = @_;
196             $day_period_type //= 'default';
197             SWITCH:
198             for ($type) {
199             if ($_ eq 'buddhist') {
200             if($day_period_type eq 'default') {
201             return 'midnight' if $time == 0;
202             return 'afternoon1' if $time >= 1200
203             && $time < 1300;
204             return 'afternoon2' if $time >= 1300
205             && $time < 1900;
206             return 'evening1' if $time >= 1900
207             && $time < 2400;
208             return 'morning1' if $time >= 500
209             && $time < 800;
210             return 'morning2' if $time >= 800
211             && $time < 1200;
212             return 'night1' if $time >= 0
213             && $time < 500;
214             }
215             if($day_period_type eq 'selection') {
216             return 'afternoon1' if $time >= 1200
217             && $time < 1300;
218             return 'afternoon2' if $time >= 1300
219             && $time < 1900;
220             return 'evening1' if $time >= 1900
221             && $time < 2400;
222             return 'morning1' if $time >= 500
223             && $time < 800;
224             return 'morning2' if $time >= 800
225             && $time < 1200;
226             return 'night1' if $time >= 0
227             && $time < 500;
228             }
229             last SWITCH;
230             }
231             if ($_ eq 'chinese') {
232             if($day_period_type eq 'default') {
233             return 'midnight' if $time == 0;
234             return 'afternoon1' if $time >= 1200
235             && $time < 1300;
236             return 'afternoon2' if $time >= 1300
237             && $time < 1900;
238             return 'evening1' if $time >= 1900
239             && $time < 2400;
240             return 'morning1' if $time >= 500
241             && $time < 800;
242             return 'morning2' if $time >= 800
243             && $time < 1200;
244             return 'night1' if $time >= 0
245             && $time < 500;
246             }
247             if($day_period_type eq 'selection') {
248             return 'afternoon1' if $time >= 1200
249             && $time < 1300;
250             return 'afternoon2' if $time >= 1300
251             && $time < 1900;
252             return 'evening1' if $time >= 1900
253             && $time < 2400;
254             return 'morning1' if $time >= 500
255             && $time < 800;
256             return 'morning2' if $time >= 800
257             && $time < 1200;
258             return 'night1' if $time >= 0
259             && $time < 500;
260             }
261             last SWITCH;
262             }
263             if ($_ eq 'generic') {
264             if($day_period_type eq 'default') {
265             return 'midnight' if $time == 0;
266             return 'afternoon1' if $time >= 1200
267             && $time < 1300;
268             return 'afternoon2' if $time >= 1300
269             && $time < 1900;
270             return 'evening1' if $time >= 1900
271             && $time < 2400;
272             return 'morning1' if $time >= 500
273             && $time < 800;
274             return 'morning2' if $time >= 800
275             && $time < 1200;
276             return 'night1' if $time >= 0
277             && $time < 500;
278             }
279             if($day_period_type eq 'selection') {
280             return 'afternoon1' if $time >= 1200
281             && $time < 1300;
282             return 'afternoon2' if $time >= 1300
283             && $time < 1900;
284             return 'evening1' if $time >= 1900
285             && $time < 2400;
286             return 'morning1' if $time >= 500
287             && $time < 800;
288             return 'morning2' if $time >= 800
289             && $time < 1200;
290             return 'night1' if $time >= 0
291             && $time < 500;
292             }
293             last SWITCH;
294             }
295             if ($_ eq 'gregorian') {
296             if($day_period_type eq 'default') {
297             return 'midnight' if $time == 0;
298             return 'afternoon1' if $time >= 1200
299             && $time < 1300;
300             return 'afternoon2' if $time >= 1300
301             && $time < 1900;
302             return 'evening1' if $time >= 1900
303             && $time < 2400;
304             return 'morning1' if $time >= 500
305             && $time < 800;
306             return 'morning2' if $time >= 800
307             && $time < 1200;
308             return 'night1' if $time >= 0
309             && $time < 500;
310             }
311             if($day_period_type eq 'selection') {
312             return 'afternoon1' if $time >= 1200
313             && $time < 1300;
314             return 'afternoon2' if $time >= 1300
315             && $time < 1900;
316             return 'evening1' if $time >= 1900
317             && $time < 2400;
318             return 'morning1' if $time >= 500
319             && $time < 800;
320             return 'morning2' if $time >= 800
321             && $time < 1200;
322             return 'night1' if $time >= 0
323             && $time < 500;
324             }
325             last SWITCH;
326             }
327             if ($_ eq 'islamic') {
328             if($day_period_type eq 'default') {
329             return 'midnight' if $time == 0;
330             return 'afternoon1' if $time >= 1200
331             && $time < 1300;
332             return 'afternoon2' if $time >= 1300
333             && $time < 1900;
334             return 'evening1' if $time >= 1900
335             && $time < 2400;
336             return 'morning1' if $time >= 500
337             && $time < 800;
338             return 'morning2' if $time >= 800
339             && $time < 1200;
340             return 'night1' if $time >= 0
341             && $time < 500;
342             }
343             if($day_period_type eq 'selection') {
344             return 'afternoon1' if $time >= 1200
345             && $time < 1300;
346             return 'afternoon2' if $time >= 1300
347             && $time < 1900;
348             return 'evening1' if $time >= 1900
349             && $time < 2400;
350             return 'morning1' if $time >= 500
351             && $time < 800;
352             return 'morning2' if $time >= 800
353             && $time < 1200;
354             return 'night1' if $time >= 0
355             && $time < 500;
356             }
357             last SWITCH;
358             }
359             if ($_ eq 'japanese') {
360             if($day_period_type eq 'default') {
361             return 'midnight' if $time == 0;
362             return 'afternoon1' if $time >= 1200
363             && $time < 1300;
364             return 'afternoon2' if $time >= 1300
365             && $time < 1900;
366             return 'evening1' if $time >= 1900
367             && $time < 2400;
368             return 'morning1' if $time >= 500
369             && $time < 800;
370             return 'morning2' if $time >= 800
371             && $time < 1200;
372             return 'night1' if $time >= 0
373             && $time < 500;
374             }
375             if($day_period_type eq 'selection') {
376             return 'afternoon1' if $time >= 1200
377             && $time < 1300;
378             return 'afternoon2' if $time >= 1300
379             && $time < 1900;
380             return 'evening1' if $time >= 1900
381             && $time < 2400;
382             return 'morning1' if $time >= 500
383             && $time < 800;
384             return 'morning2' if $time >= 800
385             && $time < 1200;
386             return 'night1' if $time >= 0
387             && $time < 500;
388             }
389             last SWITCH;
390             }
391             if ($_ eq 'roc') {
392             if($day_period_type eq 'default') {
393             return 'midnight' if $time == 0;
394             return 'afternoon1' if $time >= 1200
395             && $time < 1300;
396             return 'afternoon2' if $time >= 1300
397             && $time < 1900;
398             return 'evening1' if $time >= 1900
399             && $time < 2400;
400             return 'morning1' if $time >= 500
401             && $time < 800;
402             return 'morning2' if $time >= 800
403             && $time < 1200;
404             return 'night1' if $time >= 0
405             && $time < 500;
406             }
407             if($day_period_type eq 'selection') {
408             return 'afternoon1' if $time >= 1200
409             && $time < 1300;
410             return 'afternoon2' if $time >= 1300
411             && $time < 1900;
412             return 'evening1' if $time >= 1900
413             && $time < 2400;
414             return 'morning1' if $time >= 500
415             && $time < 800;
416             return 'morning2' if $time >= 800
417             && $time < 1200;
418             return 'night1' if $time >= 0
419             && $time < 500;
420             }
421             last SWITCH;
422             }
423             }
424             } },
425             );
426              
427             around day_period_data => sub {
428             my ($orig, $self) = @_;
429             return $self->$orig;
430             };
431              
432             has 'eras' => (
433             is => 'ro',
434             isa => HashRef,
435             init_arg => undef,
436             default => sub { {
437             'buddhist' => {
438             },
439             'chinese' => {
440             },
441             'generic' => {
442             },
443             'gregorian' => {
444             },
445             'islamic' => {
446             },
447             'japanese' => {
448             },
449             'roc' => {
450             },
451             } },
452             );
453              
454             has 'date_formats' => (
455             is => 'ro',
456             isa => HashRef,
457             init_arg => undef,
458             default => sub { {
459             'buddhist' => {
460             'short' => q{Gd/M/yy},
461             },
462             'chinese' => {
463             'full' => q{U年MMMd日EEEE},
464             'long' => q{U年MMMd日},
465             'medium' => q{U年MMMd日},
466             },
467             'generic' => {
468             'short' => q{d/M/yyGGGGG},
469             },
470             'gregorian' => {
471             'short' => q{d/M/yy},
472             },
473             'islamic' => {
474             'short' => q{Gd/M/yy},
475             },
476             'japanese' => {
477             'short' => q{Gd/M/yy},
478             },
479             'roc' => {
480             'short' => q{Gd/M/yy},
481             },
482             } },
483             );
484              
485             has 'time_formats' => (
486             is => 'ro',
487             isa => HashRef,
488             init_arg => undef,
489             default => sub { {
490             'buddhist' => {
491             },
492             'chinese' => {
493             },
494             'generic' => {
495             },
496             'gregorian' => {
497             'full' => q{zzzz ah:mm:ss},
498             'long' => q{z ah:mm:ss},
499             'medium' => q{ah:mm:ss},
500             'short' => q{ah:mm},
501             },
502             'islamic' => {
503             },
504             'japanese' => {
505             },
506             'roc' => {
507             },
508             } },
509             );
510              
511             has 'datetime_formats' => (
512             is => 'ro',
513             isa => HashRef,
514             init_arg => undef,
515             default => sub { {
516             'buddhist' => {
517             },
518             'chinese' => {
519             },
520             'generic' => {
521             },
522             'gregorian' => {
523             },
524             'islamic' => {
525             },
526             'japanese' => {
527             },
528             'roc' => {
529             },
530             } },
531             );
532              
533             has 'datetime_formats_available_formats' => (
534             is => 'ro',
535             isa => HashRef,
536             init_arg => undef,
537             default => sub { {
538             'buddhist' => {
539             M => q{L},
540             MEd => q{M/dE},
541             MMM => q{M月},
542             },
543             'generic' => {
544             HHmm => q{HH:mm},
545             MEd => q{E, d/M},
546             MMM => q{M月},
547             MMMMdd => q{M月d日},
548             Md => q{d/M},
549             yyyyM => q{M/yGGGGG},
550             yyyyMEd => q{E, d/M/yGGGGG},
551             yyyyMd => q{d/M/yGGGGG},
552             },
553             'gregorian' => {
554             HHmm => q{HH:mm},
555             MEd => q{E, d/M},
556             MMMMdd => q{M月d日},
557             MMdd => q{dd/MM},
558             Md => q{d/M},
559             yM => q{M/y},
560             yMEd => q{d/M/y(E)},
561             yMM => q{MM/y},
562             yMd => q{d/M/y},
563             },
564             'japanese' => {
565             MEd => q{M/dE},
566             Md => q{M/d},
567             },
568             'roc' => {
569             M => q{L},
570             MMM => q{M月},
571             Md => q{M-d},
572             },
573             } },
574             );
575              
576             has 'datetime_formats_append_item' => (
577             is => 'ro',
578             isa => HashRef,
579             init_arg => undef,
580             default => sub { {
581             } },
582             );
583              
584             has 'datetime_formats_interval' => (
585             is => 'ro',
586             isa => HashRef,
587             init_arg => undef,
588             default => sub { {
589             'buddhist' => {
590             Hv => {
591             H => q{vHH–HH},
592             },
593             fallback => '{0}–{1}',
594             },
595             'generic' => {
596             Hmv => {
597             H => q{vHH:mm–HH:mm},
598             m => q{vHH:mm–HH:mm},
599             },
600             Hv => {
601             H => q{vHH–HH},
602             },
603             fallback => '{0}–{1}',
604             h => {
605             h => q{ah至h时},
606             },
607             yM => {
608             M => q{y年M月至y年M月},
609             },
610             yMEd => {
611             M => q{d/M/yE至d/M/yE},
612             d => q{d/M/yE至d/M/yE},
613             y => q{d/M/yE至d/M/yE},
614             },
615             yMMMEd => {
616             d => q{y年M月d日E至M月d日E},
617             },
618             yMd => {
619             M => q{d/M/y至d/M/y},
620             d => q{d/M/y至d/M/y},
621             y => q{d/M/y至d/M/y},
622             },
623             },
624             'gregorian' => {
625             Hmv => {
626             H => q{vHH:mm–HH:mm},
627             m => q{vHH:mm–HH:mm},
628             },
629             Hv => {
630             H => q{vHH–HH},
631             },
632             fallback => '{0}–{1}',
633             h => {
634             h => q{ah至h时},
635             },
636             yM => {
637             M => q{y年M月至y年M月},
638             },
639             yMEd => {
640             M => q{d/M/yE至d/M/yE},
641             d => q{d/M/yE至d/M/yE},
642             y => q{d/M/yE至d/M/yE},
643             },
644             yMMMEd => {
645             d => q{y年M月d日E至M月d日E},
646             },
647             yMd => {
648             M => q{d/M/y至d/M/y},
649             d => q{d/M/y至d/M/y},
650             y => q{d/M/y至d/M/y},
651             },
652             },
653             } },
654             );
655              
656 1     1   4461 no Moo;
  1         3  
  1         6  
657              
658             1;
659              
660             # vim: tabstop=4