File Coverage

blib/lib/Locale/CLDR/Locales/Sv/Any/Fi.pm
Criterion Covered Total %
statement 26 26 100.0
branch n/a
condition n/a
subroutine 9 9 100.0
pod n/a
total 35 35 100.0


line stmt bran cond sub pod time code
1             =head1
2              
3             Locale::CLDR::Locales::Sv::Any::Fi - Package for language Swedish
4              
5             =cut
6              
7             package Locale::CLDR::Locales::Sv::Any::Fi;
8             # This file auto generated from Data\common\main\sv_FI.xml
9             # on Sun 24 Apr 8:52:16 am GMT
10              
11 1     1   903 use version;
  1         2  
  1         4  
12              
13             our $VERSION = version->declare('v0.29.0');
14              
15 1     1   78 use v5.10.1;
  1         2  
16 1     1   3 use mro 'c3';
  1         1  
  1         4  
17 1     1   27 use utf8;
  1         1  
  1         4  
18 1     1   24 use if $^V ge v5.12.0, feature => 'unicode_strings';
  1         1  
  1         14  
19              
20 1     1   77 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         1  
  1         8  
21 1     1   686 use Moo;
  1         1  
  1         4  
22              
23             extends('Locale::CLDR::Locales::Sv::Any');
24             has 'display_name_language' => (
25             is => 'ro',
26             isa => CodeRef,
27             init_arg => undef,
28             default => sub {
29             sub {
30             my %languages = (
31             'ky' => 'kirgiziska',
32              
33             );
34             if (@_) {
35             return $languages{$_[0]};
36             }
37             return \%languages;
38             }
39             },
40             );
41              
42             has 'display_name_script' => (
43             is => 'ro',
44             isa => CodeRef,
45             init_arg => undef,
46             default => sub {
47             sub {
48             my %scripts = (
49             'Arab@alt=variant' => 'persisk-arabiska',
50              
51             );
52             if ( @_ ) {
53             return $scripts{$_[0]};
54             }
55             return \%scripts;
56             }
57             }
58             );
59              
60             has 'display_name_key' => (
61             is => 'ro',
62             isa => HashRef[Str],
63             init_arg => undef,
64             default => sub {
65             {
66             'timezone' => 'tidszon',
67              
68             }
69             },
70             );
71              
72             has 'display_name_type' => (
73             is => 'ro',
74             isa => HashRef[HashRef[Str]],
75             init_arg => undef,
76             default => sub {
77             {
78             'collation' => {
79             'big5han' => q{kinesiska i big5-sorteringsordning},
80             'gb2312han' => q{kinesiska i gb2312-sorteringsordning},
81             'pinyin' => q{kinesiska i pinyin-sorteringsordning},
82             'stroke' => q{kinesiska i strecksorteringsordning},
83             'traditional' => q{traditionell sorteringsordning},
84             },
85              
86             }
87             },
88             );
89              
90             has 'characters' => (
91             is => 'ro',
92             isa => HashRef,
93             init_arg => undef,
94             default => $^V ge v5.18.0
95             ? eval <<'EOT'
96             sub {
97             no warnings 'experimental::regex_sets';
98             return {
99             main => qr{(?^u:[a à b c d e é f g h i j k l m n o p q r s t u v x y z Ã¥ ä ö])},
100             };
101             },
102             EOT
103             : sub {
104             return {};
105             },
106 1     1   103 );
  1         2  
  1         91  
107              
108              
109             has 'units' => (
110             is => 'ro',
111             isa => HashRef[HashRef[HashRef[Str]]],
112             init_arg => undef,
113             default => sub { {
114             'narrow' => {
115             'kilometer-per-hour' => {
116             'one' => q({0} km/h),
117             'other' => q({0} km/h),
118             },
119             },
120             'short' => {
121             'celsius' => {
122             'name' => q(grader Celsius),
123             },
124             },
125             } }
126             );
127              
128             has 'day_period_data' => (
129             is => 'ro',
130             isa => CodeRef,
131             init_arg => undef,
132             default => sub { sub {
133             # Time in hhmm format
134             my ($self, $type, $time, $day_period_type) = @_;
135             $day_period_type //= 'default';
136             SWITCH:
137             for ($type) {
138             if ($_ eq 'gregorian') {
139             if($day_period_type eq 'default') {
140             return 'midnight' if $time == 0;
141             return 'evening1' if $time >= 1800
142             && $time < 2400;
143             return 'morning1' if $time >= 500
144             && $time < 1000;
145             return 'afternoon1' if $time >= 1200
146             && $time < 1800;
147             return 'morning2' if $time >= 1000
148             && $time < 1200;
149             return 'night1' if $time >= 0
150             && $time < 500;
151             }
152             if($day_period_type eq 'selection') {
153             return 'night1' if $time >= 0
154             && $time < 500;
155             return 'morning2' if $time >= 1000
156             && $time < 1200;
157             return 'morning1' if $time >= 500
158             && $time < 1000;
159             return 'afternoon1' if $time >= 1200
160             && $time < 1800;
161             return 'evening1' if $time >= 1800
162             && $time < 2400;
163             }
164             last SWITCH;
165             }
166             }
167             } },
168             );
169              
170             around day_period_data => sub {
171             my ($orig, $self) = @_;
172             return $self->$orig;
173             };
174              
175             has 'eras' => (
176             is => 'ro',
177             isa => HashRef,
178             init_arg => undef,
179             default => sub { {
180             'gregorian' => {
181             },
182             } },
183             );
184              
185             has 'date_formats' => (
186             is => 'ro',
187             isa => HashRef,
188             init_arg => undef,
189             default => sub { {
190             'gregorian' => {
191             'short' => q{dd-MM-y},
192             },
193             } },
194             );
195              
196             has 'time_formats' => (
197             is => 'ro',
198             isa => HashRef,
199             init_arg => undef,
200             default => sub { {
201             'gregorian' => {
202             },
203             } },
204             );
205              
206             has 'datetime_formats' => (
207             is => 'ro',
208             isa => HashRef,
209             init_arg => undef,
210             default => sub { {
211             'gregorian' => {
212             },
213             } },
214             );
215              
216             has 'datetime_formats_available_formats' => (
217             is => 'ro',
218             isa => HashRef,
219             init_arg => undef,
220             default => sub { {
221             } },
222             );
223              
224             has 'datetime_formats_append_item' => (
225             is => 'ro',
226             isa => HashRef,
227             init_arg => undef,
228             default => sub { {
229             } },
230             );
231              
232             has 'datetime_formats_interval' => (
233             is => 'ro',
234             isa => HashRef,
235             init_arg => undef,
236             default => sub { {
237             } },
238             );
239              
240 1     1   2349 no Moo;
  1         2  
  1         4  
241              
242             1;
243              
244             # vim: tabstop=4