#!/usr/bin/perl
package Geo::CountryFlags::CIA;

################################################################
# WARNING! this module is automatically generated DO NOT EDIT! #
#            see Geo::CountryFlags::Util instead               #
#                                                              #
# creation date:  Sat Sep 16 07:05:43 2006 GMT	               #
################################################################

use strict;
use vars qw($VERSION);
$VERSION = '2006258.002';

my $CIA = {
    'aa' => q|Aruba|,
    'ac' => q|Antigua and Barbuda|,
    'ae' => q|United Arab Emirates|,
    'af' => q|Afghanistan|,
    'ag' => q|Algeria|,
    'aj' => q|Azerbaijan|,
    'al' => q|Albania|,
    'am' => q|Armenia|,
    'an' => q|Andorra|,
    'ao' => q|Angola|,
    'aq' => q|American Samoa|,
    'ar' => q|Argentina|,
    'as' => q|Australia|,
    'at' => q|Ashmore and Cartier Islands|,
    'au' => q|Austria|,
    'av' => q|Anguilla|,
    'ax' => q|Akrotiri|,
    'ay' => q|Antarctica|,
    'ba' => q|Bahrain|,
    'bb' => q|Barbados|,
    'bc' => q|Botswana|,
    'bd' => q|Bermuda|,
    'be' => q|Belgium|,
    'bf' => q|Bahamas, The|,
    'bg' => q|Bangladesh|,
    'bh' => q|Belize|,
    'bk' => q|Bosnia and Herzegovina|,
    'bl' => q|Bolivia|,
    'bm' => q|Burma|,
    'bn' => q|Benin|,
    'bo' => q|Belarus|,
    'bp' => q|Solomon Islands|,
    'bq' => q|Navassa Island|,
    'br' => q|Brazil|,
    'bs' => q|Bassas da India|,
    'bt' => q|Bhutan|,
    'bu' => q|Bulgaria|,
    'bv' => q|Bouvet Island|,
    'bx' => q|Brunei|,
    'by' => q|Burundi|,
    'ca' => q|Canada|,
    'cb' => q|Cambodia|,
    'cd' => q|Chad|,
    'ce' => q|Sri Lanka|,
    'cf' => q|Congo, Republic of the|,
    'cg' => q|Congo, Democratic Republic of the|,
    'ch' => q|China|,
    'ci' => q|Chile|,
    'cj' => q|Cayman Islands|,
    'ck' => q|Cocos (Keeling) Islands|,
    'cm' => q|Cameroon|,
    'cn' => q|Comoros|,
    'co' => q|Colombia|,
    'cq' => q|Northern Mariana Islands|,
    'cr' => q|Coral Sea Islands|,
    'cs' => q|Costa Rica|,
    'ct' => q|Central African Republic|,
    'cu' => q|Cuba|,
    'cv' => q|Cape Verde|,
    'cw' => q|Cook Islands|,
    'cy' => q|Cyprus|,
    'da' => q|Denmark|,
    'dj' => q|Djibouti|,
    'do' => q|Dominica|,
    'dq' => q|Jarvis Island|,
    'dr' => q|Dominican Republic|,
    'dx' => q|Dhekelia|,
    'ec' => q|Ecuador|,
    'ee' => q|European Union|,
    'eg' => q|Egypt|,
    'ei' => q|Ireland|,
    'ek' => q|Equatorial Guinea|,
    'en' => q|Estonia|,
    'er' => q|Eritrea|,
    'es' => q|El Salvador|,
    'et' => q|Ethiopia|,
    'eu' => q|Europa Island|,
    'ez' => q|Czech Republic|,
    'fg' => q|French Guiana|,
    'fi' => q|Finland|,
    'fj' => q|Fiji|,
    'fk' => q|Falkland Islands (Islas Malvinas)|,
    'fm' => q|Micronesia, Federated States of|,
    'fo' => q|Faroe Islands|,
    'fp' => q|French Polynesia|,
    'fq' => q|Baker Island|,
    'fr' => q|France|,
    'fs' => q|French Southern and Antarctic Lands|,
    'ga' => q|Gambia, The|,
    'gb' => q|Gabon|,
    'gg' => q|Georgia|,
    'gh' => q|Ghana|,
    'gi' => q|Gibraltar|,
    'gj' => q|Grenada|,
    'gk' => q|Guernsey|,
    'gl' => q|Greenland|,
    'gm' => q|Germany|,
    'go' => q|Glorioso Islands|,
    'gp' => q|Guadeloupe|,
    'gq' => q|Guam|,
    'gr' => q|Greece|,
    'gt' => q|Guatemala|,
    'gv' => q|Guinea|,
    'gy' => q|Guyana|,
    'gz' => q|Gaza Strip|,
    'ha' => q|Haiti|,
    'hk' => q|Hong Kong|,
    'hm' => q|Heard Island and McDonald Islands|,
    'ho' => q|Honduras|,
    'hq' => q|Howland Island|,
    'hr' => q|Croatia|,
    'hu' => q|Hungary|,
    'ic' => q|Iceland|,
    'id' => q|Indonesia|,
    'im' => q|Isle of Man|,
    'in' => q|India|,
    'io' => q|British Indian Ocean Territory|,
    'ip' => q|Clipperton Island|,
    'ir' => q|Iran|,
    'is' => q|Israel|,
    'it' => q|Italy|,
    'iv' => q|Cote d'Ivoire|,
    'iz' => q|Iraq|,
    'ja' => q|Japan|,
    'je' => q|Jersey|,
    'jm' => q|Jamaica|,
    'jn' => q|Jan Mayen|,
    'jo' => q|Jordan|,
    'jq' => q|Johnston Atoll|,
    'ju' => q|Juan de Nova Island|,
    'ke' => q|Kenya|,
    'kg' => q|Kyrgyzstan|,
    'kn' => q|Korea, North|,
    'kq' => q|Kingman Reef|,
    'kr' => q|Kiribati|,
    'ks' => q|Korea, South|,
    'kt' => q|Christmas Island|,
    'ku' => q|Kuwait|,
    'kz' => q|Kazakhstan|,
    'la' => q|Laos|,
    'le' => q|Lebanon|,
    'lg' => q|Latvia|,
    'lh' => q|Lithuania|,
    'li' => q|Liberia|,
    'lo' => q|Slovakia|,
    'lq' => q|Palmyra Atoll|,
    'ls' => q|Liechtenstein|,
    'lt' => q|Lesotho|,
    'lu' => q|Luxembourg|,
    'ly' => q|Libya|,
    'ma' => q|Madagascar|,
    'mb' => q|Martinique|,
    'mc' => q|Macau|,
    'md' => q|Moldova|,
    'mf' => q|Mayotte|,
    'mg' => q|Mongolia|,
    'mh' => q|Montserrat|,
    'mi' => q|Malawi|,
    'mj' => q|Montenegro|,
    'mk' => q|Macedonia|,
    'ml' => q|Mali|,
    'mn' => q|Monaco|,
    'mo' => q|Morocco|,
    'mp' => q|Mauritius|,
    'mq' => q|Midway Islands|,
    'mr' => q|Mauritania|,
    'mt' => q|Malta|,
    'mu' => q|Oman|,
    'mv' => q|Maldives|,
    'mx' => q|Mexico|,
    'my' => q|Malaysia|,
    'mz' => q|Mozambique|,
    'nc' => q|New Caledonia|,
    'ne' => q|Niue|,
    'nf' => q|Norfolk Island|,
    'ng' => q|Niger|,
    'nh' => q|Vanuatu|,
    'ni' => q|Nigeria|,
    'nl' => q|Netherlands|,
    'no' => q|Norway|,
    'np' => q|Nepal|,
    'nr' => q|Nauru|,
    'ns' => q|Suriname|,
    'nt' => q|Netherlands Antilles|,
    'nu' => q|Nicaragua|,
    'nz' => q|New Zealand|,
    'oo' => q|Southern Ocean|,
    'pa' => q|Paraguay|,
    'pc' => q|Pitcairn Islands|,
    'pe' => q|Peru|,
    'pf' => q|Paracel Islands|,
    'pg' => q|Spratly Islands|,
    'pk' => q|Pakistan|,
    'pl' => q|Poland|,
    'pm' => q|Panama|,
    'po' => q|Portugal|,
    'pp' => q|Papua New Guinea|,
    'ps' => q|Palau|,
    'pu' => q|Guinea-Bissau|,
    'qa' => q|Qatar|,
    'rb' => q|Serbia|,
    're' => q|Reunion|,
    'rm' => q|Marshall Islands|,
    'ro' => q|Romania|,
    'rp' => q|Philippines|,
    'rq' => q|Puerto Rico|,
    'rs' => q|Russia|,
    'rw' => q|Rwanda|,
    'sa' => q|Saudi Arabia|,
    'sb' => q|Saint Pierre and Miquelon|,
    'sc' => q|Saint Kitts and Nevis|,
    'se' => q|Seychelles|,
    'sf' => q|South Africa|,
    'sg' => q|Senegal|,
    'sh' => q|Saint Helena|,
    'si' => q|Slovenia|,
    'sl' => q|Sierra Leone|,
    'sm' => q|San Marino|,
    'sn' => q|Singapore|,
    'so' => q|Somalia|,
    'sp' => q|Spain|,
    'st' => q|Saint Lucia|,
    'su' => q|Sudan|,
    'sv' => q|Svalbard|,
    'sw' => q|Sweden|,
    'sx' => q|South Georgia and the South Sandwich Islands|,
    'sy' => q|Syria|,
    'sz' => q|Switzerland|,
    'td' => q|Trinidad and Tobago|,
    'te' => q|Tromelin Island|,
    'th' => q|Thailand|,
    'ti' => q|Tajikistan|,
    'tk' => q|Turks and Caicos Islands|,
    'tl' => q|Tokelau|,
    'tn' => q|Tonga|,
    'to' => q|Togo|,
    'tp' => q|Sao Tome and Principe|,
    'ts' => q|Tunisia|,
    'tt' => q|East Timor|,
    'tu' => q|Turkey|,
    'tv' => q|Tuvalu|,
    'tw' => q|Taiwan|,
    'tx' => q|Turkmenistan|,
    'tz' => q|Tanzania|,
    'ug' => q|Uganda|,
    'uk' => q|United Kingdom|,
    'um' => q|United States Pacific Island Wildlife Refuges|,
    'up' => q|Ukraine|,
    'us' => q|United States|,
    'uv' => q|Burkina Faso|,
    'uy' => q|Uruguay|,
    'uz' => q|Uzbekistan|,
    'vc' => q|Saint Vincent and the Grenadines|,
    've' => q|Venezuela|,
    'vi' => q|British Virgin Islands|,
    'vm' => q|Vietnam|,
    'vq' => q|Virgin Islands|,
    'vt' => q|Holy See (Vatican City)|,
    'wa' => q|Namibia|,
    'we' => q|West Bank|,
    'wf' => q|Wallis and Futuna|,
    'wi' => q|Western Sahara|,
    'wq' => q|Wake Island|,
    'ws' => q|Samoa|,
    'wz' => q|Swaziland|,
    'xo' => q|Indian Ocean|,
    'xq' => q|Arctic Ocean|,
    'xx' => q|World|,
    'ym' => q|Yemen|,
    'za' => q|Zambia|,
    'zh' => q|Atlantic Ocean|,
    'zi' => q|Zimbabwe|,
    'zn' => q|Pacific Ocean|,
    'zz' => q|Iles Eparses|,
};

sub AUTOLOAD {
  no strict;
  $AUTOLOAD =~ /[^:]+$/;
  value($&);
}

sub new {
  my $proto = shift;
  my $class = ref $proto || $proto || __PACKAGE__;
  my $self = {};
  bless $self, $class;
}

sub hashptr {
  my($proto,$class) = @_;
  $proto = $class if $class;
  $class = ref $proto || $proto;
  my $rv = {};
  %$rv = %$CIA;
  bless $rv, $class;
}

sub value {
  return (exists $CIA->{$_[0]}) ? $CIA->{$_[0]} : undef;
}

sub subref {
  return \&value;
}

1;
__END__

=pod

Geo::CountryFlags::CIA is autogenerated by Makefile.PL

Last updated Sat Sep 16 07:05:43 2006 GMT

=head1 NAME

Geo::CountryFlags::CIA::CIA - hash to map values

=head1 SYNOPSIS

Geo::CountryFlags::CIA provides a variety of methods and functions to lookup values
either as hash-like constants (recommended) or directly from a hash array.

    require $Geo::CountryFlags::CIA;
    my $gcc = new Geo::CountryFlags::CIA;
    $value = $gcc->KEY;

  Perl 5.6 or greater can use syntax
    $value = $gcc->$key;

  or
    $subref = subref Geo::CountryFlags::CIA;
    $value = $subref->($key);
    $value = &$subref($key);

  or
    $value = value Geo::CountryFlags::CIA($key);
    Geo::CountryFlags::CIA->value($key);

  to return a reference to the map directly

  $hashref = hashptr Geo::CountryFlags::CIA($class);
  $value = $hashref->{$key};

=head1 DESCRIPTION

Geo::CountryFlags::CIA maps CIA values.

Values may be returned directly by designating the KEY as a method or
subroutine of the form:

    $value = Geo::CountryFlags::CIA::KEY;
    $value = Geo::CountryFlags::CIA->KEY;
  or in Perl 5.6 and above
    $value = Geo::CountryFlags::CIA->$key;
  or
    $gcc = new Geo::CountryFlags::CIA;
    $value = $gcc->KEY;
  or in Perl 5.6 and above
    $value= =  $gcc->$key;

=over 4

=item * $gcc = new Geo::CountryFlags::CIA;

Return a reference to the modules in this package.

=item * $hashptr = hashptr Geo::CountryFlags::CIA($class);

Return a blessed reference to a copy of the hash in this package.

  input:	[optional] class or class ref
  returns:	a reference blessed into $class
		if $class is present otherwise
		blessed into Geo::CountryFlags::CIA

=item * $value = value Geo::CountryFlags::CIA($key);

=item * $value = $gcc->value($key);

Return the value in the map hash or undef if it does not exist.

=item * $subref = subref Geo::CountryFlags::CIA;

=item * $subref = $gcc->subref;

Return a subroutine reference that will return the value of a key or undef
if the key is not present.

  $value = $subref->($key);
  $value = &$subref($key);

=back

=head1 EXPORTs

Nothing

=head1 AUTHOR 

Michael Robinton michael@bizsystems.com

=head1 COPYRIGHT and LICENSE

  Copyright 2006 Michael Robinton, michael@bizsystems.com

This module is free software; you can redistribute it and/or modify it
under the terms of the GNU General Public License as published by the Free Software 
Foundation; either version 1, or (at your option) any later version,

This program is distributed in the hope that it will be useful, 
but WITHOUT ANY WARRANTY; without even the implied warranty of  
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See either
the GNU General Public License or the Artistic License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

=head1 SEE ALSO

L<Geo::CountryFlags::Util>

=cut

1;
