.\" Automatically generated by Pod::Man 4.14 (Pod::Simple 3.40) .\" .\" Standard preamble: .\" ======================================================================== .de Sp \" Vertical space (when we can't use .PP) .if t .sp .5v .if n .sp .. .de Vb \" Begin verbatim text .ft CW .nf .ne \\$1 .. .de Ve \" End verbatim text .ft R .fi .. .\" Set up some character translations and predefined strings. \*(-- will .\" give an unbreakable dash, \*(PI will give pi, \*(L" will give a left .\" double quote, and \*(R" will give a right double quote. \*(C+ will .\" give a nicer C++. Capital omega is used to do unbreakable dashes and .\" therefore won't be available. \*(C` and \*(C' expand to `' in nroff, .\" nothing in troff, for use with C<>. .tr \(*W- .ds C+ C\v'-.1v'\h'-1p'\s-2+\h'-1p'+\s0\v'.1v'\h'-1p' .ie n \{\ . ds -- \(*W- . ds PI pi . if (\n(.H=4u)&(1m=24u) .ds -- \(*W\h'-12u'\(*W\h'-12u'-\" diablo 10 pitch . if (\n(.H=4u)&(1m=20u) .ds -- \(*W\h'-12u'\(*W\h'-8u'-\" diablo 12 pitch . ds L" "" . ds R" "" . ds C` "" . ds C' "" 'br\} .el\{\ . ds -- \|\(em\| . ds PI \(*p . ds L" `` . ds R" '' . ds C` . ds C' 'br\} .\" .\" Escape single quotes in literal strings from groff's Unicode transform. .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" .\" If the F register is >0, we'll generate index entries on stderr for .\" titles (.TH), headers (.SH), subsections (.SS), items (.Ip), and index .\" entries marked with X<> in POD. Of course, you'll have to process the .\" output yourself in some meaningful fashion. .\" .\" Avoid warning from groff about undefined register 'F'. .de IX .. .nr rF 0 .if \n(.g .if rF .nr rF 1 .if (\n(rF:(\n(.g==0)) \{\ . if \nF \{\ . de IX . tm Index:\\$1\t\\n%\t"\\$2" .. . if !\nF==2 \{\ . nr % 0 . nr F 2 . \} . \} .\} .rr rF .\" ======================================================================== .\" .IX Title "Locale::US 3pm" .TH Locale::US 3pm "2020-12-29" "perl v5.32.0" "User Contributed Perl Documentation" .\" For nroff, turn off justification. Always turn off hyphenation; it makes .\" way too many mistakes in technical documents. .if n .ad l .nh .SH "NAME" Locale::US \- Two letter codes for state identification in the United States and vice versa. .SH "SYNOPSIS" .IX Header "SYNOPSIS" .Vb 1 \& use Locale::US; \& \& my $u = Locale::US\->new; \& \& my $state = $u\->{code2state}{$code}; \& my $code = $u\->{state2code}{$state}; \& \& my @state = $u\->all_state_names; \& my @code = $u\->all_state_codes; .Ve .SH "ABSTRACT" .IX Header "ABSTRACT" Map from \s-1US\s0 two-letter codes to states and vice versa. .SH "DESCRIPTION" .IX Header "DESCRIPTION" .SS "\s-1MAPPING\s0" .IX Subsection "MAPPING" \fI\f(CI$self\fI\->{code2state}\fR .IX Subsection "$self->{code2state}" .PP This is a hashref which has two-letter state names as the key and the long name as the value. .PP \fI\f(CI$self\fI\->{state2code}\fR .IX Subsection "$self->{state2code}" .PP This is a hashref which has the long nameas the key and the two-letter state name as the value. .SS "\s-1DUMPING\s0" .IX Subsection "DUMPING" \fI\f(CI$self\fI\->all_state_names\fR .IX Subsection "$self->all_state_names" .PP Returns an array (not arrayref) of all state names in alphabetical form .PP \fI\f(CI$self\fI\->all_state_codes\fR .IX Subsection "$self->all_state_codes" .PP Returns an array (not arrayref) of all state codes in alphabetical form. .SH "KNOWN BUGS AND LIMITATIONS" .IX Header "KNOWN BUGS AND LIMITATIONS" .IP "\(bu" 4 The state name is returned in \f(CW\*(C`uc()\*(C'\fR format. .IP "\(bu" 4 neither hash is strict, though they should be. .SH "SEE ALSO" .IX Header "SEE ALSO" .SS "Locale::Country" .IX Subsection "Locale::Country" Locale::Country .SS "Abbreviations" .IX Subsection "Abbreviations" .PP .Vb 1 \& Online file with the USPS two\-letter codes for the United States and its possessions. .Ve .SS "\s-1AUXILIARY CODE:\s0" .IX Subsection "AUXILIARY CODE:" .Vb 2 \& lynx \-dump http://www.usps.gov/ncsc/lookups/usps_abbreviations.htm > kruft.txt \& kruft2codes.pl .Ve .SH "AUTHOR" .IX Header "AUTHOR" Currently maintained by Mike Accardo, .PP Original author T. M. Brannon .SS "\s-1PATCHES\s0" .IX Subsection "PATCHES" Thanks to stevet \s-1AT\s0 ibrinc for a patch about second call to new failing. .SH "COPYRIGHT" .IX Header "COPYRIGHT" .Vb 2 \& Copyright (c) 2015 Mike Accardo \& Copyright (c) 2002\-2014 Terrence Brannon .Ve .PP All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.