File Coverage

blib/lib/Locale/CLDR/Locales/De/Any/Lu.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::De::Any::Lu - Package for language German
6              
7             =cut
8              
9             package Locale::CLDR::Locales::De::Any::Lu;
10             # This file auto generated from Data\common\main\de_LU.xml
11             # on Sun 16 Dec 4:11:49 pm GMT
12              
13 1     1   1638 use strict;
  1         4  
  1         34  
14 1     1   6 use warnings;
  1         3  
  1         34  
15 1     1   6 use version;
  1         3  
  1         8  
16              
17             our $VERSION = version->declare('v0.34.0');
18              
19 1     1   130 use v5.10.1;
  1         5  
20 1     1   8 use mro 'c3';
  1         2  
  1         11  
21 1     1   43 use utf8;
  1         2  
  1         11  
22 1     1   51 use if $^V ge v5.12.0, feature => 'unicode_strings';
  1         2  
  1         17  
23 1     1   184 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         3  
  1         13  
24 1     1   1231 use Moo;
  1         3  
  1         8  
25              
26             extends('Locale::CLDR::Locales::De::Any');
27             has 'display_name_language' => (
28             is => 'ro',
29             isa => CodeRef,
30             init_arg => undef,
31             default => sub {
32             sub {
33             my %languages = (
34             'be' => 'Belarussisch',
35              
36             );
37             if (@_) {
38             return $languages{$_[0]};
39             }
40             return \%languages;
41             }
42             },
43             );
44              
45             has 'currencies' => (
46             is => 'ro',
47             isa => HashRef,
48             init_arg => undef,
49             default => sub { {
50             'LUF' => {
51             symbol => 'F',
52             },
53             } },
54             );
55              
56              
57             has 'day_period_data' => (
58             is => 'ro',
59             isa => CodeRef,
60             init_arg => undef,
61             default => sub { sub {
62             # Time in hhmm format
63             my ($self, $type, $time, $day_period_type) = @_;
64             $day_period_type //= 'default';
65             SWITCH:
66             for ($type) {
67             if ($_ eq 'gregorian') {
68             if($day_period_type eq 'selection') {
69             return 'afternoon1' if $time >= 1200
70             && $time < 1300;
71             return 'morning1' if $time >= 500
72             && $time < 1000;
73             return 'evening1' if $time >= 1800
74             && $time < 2400;
75             return 'morning2' if $time >= 1000
76             && $time < 1200;
77             return 'afternoon2' if $time >= 1300
78             && $time < 1800;
79             return 'night1' if $time >= 0
80             && $time < 500;
81             }
82             if($day_period_type eq 'default') {
83             return 'midnight' if $time == 0;
84             return 'night1' if $time >= 0
85             && $time < 500;
86             return 'afternoon2' if $time >= 1300
87             && $time < 1800;
88             return 'morning2' if $time >= 1000
89             && $time < 1200;
90             return 'evening1' if $time >= 1800
91             && $time < 2400;
92             return 'afternoon1' if $time >= 1200
93             && $time < 1300;
94             return 'morning1' if $time >= 500
95             && $time < 1000;
96             }
97             last SWITCH;
98             }
99             }
100             } },
101             );
102              
103             around day_period_data => sub {
104             my ($orig, $self) = @_;
105             return $self->$orig;
106             };
107              
108             has 'day_periods' => (
109             is => 'ro',
110             isa => HashRef,
111             init_arg => undef,
112             default => sub { {
113             'gregorian' => {
114             'format' => {
115             'narrow' => {
116             'am' => q{vorm.},
117             'pm' => q{nachm.},
118             },
119             },
120             },
121             } },
122             );
123              
124             has 'eras' => (
125             is => 'ro',
126             isa => HashRef,
127             init_arg => undef,
128             default => sub { {
129             'gregorian' => {
130             },
131             } },
132             );
133              
134             has 'date_formats' => (
135             is => 'ro',
136             isa => HashRef,
137             init_arg => undef,
138             default => sub { {
139             'gregorian' => {
140             },
141             } },
142             );
143              
144             has 'time_formats' => (
145             is => 'ro',
146             isa => HashRef,
147             init_arg => undef,
148             default => sub { {
149             'gregorian' => {
150             },
151             } },
152             );
153              
154             has 'datetime_formats' => (
155             is => 'ro',
156             isa => HashRef,
157             init_arg => undef,
158             default => sub { {
159             'gregorian' => {
160             },
161             } },
162             );
163              
164             has 'datetime_formats_available_formats' => (
165             is => 'ro',
166             isa => HashRef,
167             init_arg => undef,
168             default => sub { {
169             'gregorian' => {
170             h => q{h a},
171             },
172             } },
173             );
174              
175             has 'datetime_formats_append_item' => (
176             is => 'ro',
177             isa => HashRef,
178             init_arg => undef,
179             default => sub { {
180             } },
181             );
182              
183             has 'datetime_formats_interval' => (
184             is => 'ro',
185             isa => HashRef,
186             init_arg => undef,
187             default => sub { {
188             } },
189             );
190              
191 1     1   1269 no Moo;
  1         3  
  1         6  
192              
193             1;
194              
195             # vim: tabstop=4