Debian Codegraph @

lib/Date/Language/Finnish.pm

raw
1 ##
2 ## Finnish tables
3 ## Contributed by Matthew Musgrove <[email protected]>
4 ## Corrected by roke
5 ##
6
7 package Date::Language::Finnish;
8
9 use strict;
10 use warnings;
11 use utf8;
12
13 use base 'Date::Language';
14
15 our $VERSION = '2.35'; # VERSION: generated
16 # ABSTRACT: Finnish localization for Date::Format
17 use Date::Language ();
18
19 # In Finnish, the names of the months and days are only capitalized at the beginning of sentences.
20 our @MoY = map($_ . "kuu", qw(tammi helmi maalis huhti touko kesä heinä elo syys loka marras joulu));
21 our @DoW = qw(sunnuntai maanantai tiistai keskiviikko torstai perjantai lauantai);
22
23 # it is not customary to use abbreviated names of months or days
24 # per Graham's suggestion:
25 our @MoYs = @MoY;
26 our @DoWs = @DoW;
27
28 # the short form of ordinals
29 our @Dsuf = ('.') x 31;
30
31 # doesn't look like this is normally used...
32 our @AMPM = qw(ap ip);
33
34 our ( %MoY, %DoW );
35 Date::Language::_build_lookups();
36
37 # Formatting routines
38
39 sub format_a { $DoWs[$_[0]->[6]] }
40 sub format_A { $DoW[$_[0]->[6]] }
41 sub format_b { $MoYs[$_[0]->[4]] }
42 sub format_B { $MoY[$_[0]->[4]] }
43 sub format_h { $MoYs[$_[0]->[4]] }
44 sub format_p { $_[0]->[2] >= 12 ? $AMPM[1] : $AMPM[0] }
45 sub format_o { sprintf("%2de",$_[0]->[3]) }
46
47 1;
48
49 __END__
50
51 =pod
52
53 =encoding UTF-8
54
55 =head1 NAME
56
57 Date::Language::Finnish - Finnish localization for Date::Format
58
59 =head1 VERSION
60
61 version 2.35
62
63 =head1 AUTHOR
64
65 Graham <[email protected]>
66
67 =head1 COPYRIGHT AND LICENSE
68
69 This software is copyright (c) 2020 by Graham Barr.
70
71 This is free software; you can redistribute it and/or modify it under
72 the same terms as the Perl 5 programming language system itself.
73
74 =cut