File Coverage

blib/lib/Locale/CLDR/Locales/Ar/Any/Sa.pm
Criterion Covered Total %
statement 32 32 100.0
branch n/a
condition n/a
subroutine 11 11 100.0
pod n/a
total 43 43 100.0


line stmt bran cond sub pod time code
1             =encoding utf8
2              
3             =head1
4              
5             Locale::CLDR::Locales::Ar::Any::Sa - Package for language Arabic
6              
7             =cut
8              
9             # This file auto generated from Data/common/main/ar_SA.xml
10             # on Mon 11 Apr 5:23:39 pm GMT
11              
12             use strict;
13 1     1   808 use warnings;
  1         2  
  1         22  
14 1     1   4 use version;
  1         2  
  1         29  
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   71 use mro 'c3';
  1         3  
20 1     1   4 use utf8;
  1         2  
  1         4  
21 1     1   20 use if $^V ge v5.12.0, feature => 'unicode_strings';
  1         1  
  1         4  
22 1     1   32 use Types::Standard qw( Str Int HashRef ArrayRef CodeRef RegexpRef );
  1         2  
  1         8  
23 1     1   83 use Moo;
  1         2  
  1         5  
24 1     1   809  
  1         1  
  1         4  
25             extends('Locale::CLDR::Locales::Ar::Any');
26             has 'display_name_language' => (
27             is => 'ro',
28             isa => CodeRef,
29             init_arg => undef,
30             default => sub {
31             sub {
32             my %languages = (
33             'arn' => 'المابودونجونية',
34             'gn' => 'الغورانية',
35             'hsb' => 'صوربيا العليا',
36             'lo' => 'اللاوو',
37             'sh' => 'الكرواتية الصربية',
38             'sma' => 'سامي الجنوبية',
39             'sw' => 'السواحيلية',
40             'sw_CD' => 'السواحيلية الكونغولية',
41             'te' => 'التيلوجو',
42             'ti' => 'التيغرينية',
43              
44             );
45             if (@_) {
46             return $languages{$_[0]};
47             }
48             return \%languages;
49             }
50             },
51             );
52              
53             has 'display_name_region' => (
54             is => 'ro',
55             isa => HashRef[Str],
56             init_arg => undef,
57             default => sub {
58             {
59             'AC' => 'جزيرة أسينشين',
60             'BS' => 'جزر البهاما',
61             'CZ@alt=variant' => 'التشيك',
62             'EA' => 'سبتة ومليلية',
63             'MO' => 'ماكاو الصينية (منطقة إدارية خاصة)',
64             'MO@alt=short' => 'ماكاو',
65             'MS' => 'مونتيسيرات',
66             'UY' => 'أوروغواي',
67              
68             }
69             },
70             );
71              
72             has 'characters' => (
73             is => 'ro',
74             isa => HashRef,
75             init_arg => undef,
76             default => $^V ge v5.18.0
77             ? eval <<'EOT'
78             sub {
79             no warnings 'experimental::regex_sets';
80             return {
81             numbers => qr{[‎ \- , . ٪ ‰ + 0 1 2 3 4 5 6 7 8 9]},
82             };
83             },
84             EOT
85             : sub {
86             return {};
87             },
88             );
89 1     1   90  
  1         1  
  1         73  
90              
91             has 'default_numbering_system' => (
92             is => 'ro',
93             isa => Str,
94             init_arg => undef,
95             default => 'arab',
96             );
97              
98             has 'number_symbols' => (
99             is => 'ro',
100             isa => HashRef,
101             init_arg => undef,
102             default => sub { {
103             'latn' => {
104             'percentSign' => q(٪),
105             },
106             } }
107             );
108              
109             has 'day_period_data' => (
110             is => 'ro',
111             isa => CodeRef,
112             init_arg => undef,
113             default => sub { sub {
114             # Time in hhmm format
115             my ($self, $type, $time, $day_period_type) = @_;
116             $day_period_type //= 'default';
117             SWITCH:
118             for ($type) {
119             if ($_ eq 'gregorian') {
120             if($day_period_type eq 'default') {
121             return 'afternoon1' if $time >= 1200
122             && $time < 1300;
123             return 'afternoon2' if $time >= 1300
124             && $time < 1800;
125             return 'evening1' if $time >= 1800
126             && $time < 2400;
127             return 'morning1' if $time >= 300
128             && $time < 600;
129             return 'morning2' if $time >= 600
130             && $time < 1200;
131             return 'night1' if $time >= 0
132             && $time < 100;
133             return 'night2' if $time >= 100
134             && $time < 300;
135             }
136             if($day_period_type eq 'selection') {
137             return 'afternoon1' if $time >= 1200
138             && $time < 1300;
139             return 'afternoon2' if $time >= 1300
140             && $time < 1800;
141             return 'evening1' if $time >= 1800
142             && $time < 2400;
143             return 'morning1' if $time >= 300
144             && $time < 600;
145             return 'morning2' if $time >= 600
146             && $time < 1200;
147             return 'night1' if $time >= 0
148             && $time < 100;
149             return 'night2' if $time >= 100
150             && $time < 300;
151             }
152             last SWITCH;
153             }
154             }
155             } },
156             );
157              
158             around day_period_data => sub {
159             my ($orig, $self) = @_;
160             return $self->$orig;
161             };
162              
163             has 'day_periods' => (
164             is => 'ro',
165             isa => HashRef,
166             init_arg => undef,
167             default => sub { {
168             'gregorian' => {
169             'format' => {
170             'abbreviated' => {
171             'afternoon1' => q{ظهرًا},
172             'afternoon2' => q{بعد الظهر},
173             'evening1' => q{مساءً},
174             'morning1' => q{فجرًا},
175             'morning2' => q{ص},
176             'night1' => q{منتصف الليل},
177             'night2' => q{ل},
178             },
179             },
180             },
181             } },
182             );
183              
184             has 'eras' => (
185             is => 'ro',
186             isa => HashRef,
187             init_arg => undef,
188             default => sub { {
189             'gregorian' => {
190             },
191             } },
192             );
193              
194             has 'date_formats' => (
195             is => 'ro',
196             isa => HashRef,
197             init_arg => undef,
198             default => sub { {
199             'gregorian' => {
200             },
201             } },
202             );
203              
204             has 'time_formats' => (
205             is => 'ro',
206             isa => HashRef,
207             init_arg => undef,
208             default => sub { {
209             'gregorian' => {
210             },
211             } },
212             );
213              
214             has 'datetime_formats' => (
215             is => 'ro',
216             isa => HashRef,
217             init_arg => undef,
218             default => sub { {
219             'gregorian' => {
220             },
221             } },
222             );
223              
224             has 'datetime_formats_available_formats' => (
225             is => 'ro',
226             isa => HashRef,
227             init_arg => undef,
228             default => sub { {
229             } },
230             );
231              
232             has 'datetime_formats_append_item' => (
233             is => 'ro',
234             isa => HashRef,
235             init_arg => undef,
236             default => sub { {
237             } },
238             );
239              
240             has 'datetime_formats_interval' => (
241             is => 'ro',
242             isa => HashRef,
243             init_arg => undef,
244             default => sub { {
245             } },
246             );
247              
248             no Moo;
249 1     1   1018  
  1         1  
  1         4  
250             1;
251              
252             # vim: tabstop=4