The London Perl and Raku Workshop takes place on 26th Oct 2024. If your company depends on Perl, please consider sponsoring and/or attending.

NAME

Geography::States::Borders - Return the borders of states and provinces

VERSION

version 0.0106

SYNOPSIS

  use Geography::States::Borders ();
  my $geo = Geography::States::Borders->new(country => 'Netherlands');
  my $states = $geo->borders('AW'); # empty list
  $states = $geo->borders('UT');    # ZH NH GE

DESCRIPTION

Geography::States::Borders returns the border states (or provinces) of given states or provinces.

* Currently the recognized countries are Australia, Canada, Brazil, the Netherlands, and the USA.

ATTRIBUTES

country

  $country = $geo->country;

Set the country.

Default: usa

METHODS

new

  $geo = Geography::States::Borders->new(country => $country);

Create a new Geography::States::Borders object.

borders

  $states = $geo->borders($state_code);

Return a hash reference of the bordering states of the given state code.

SEE ALSO

The t/methods.t file in this distribution

Moo

AUTHOR

Gene Boggs <gene@cpan.org>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2024 by Gene Boggs.

This is free software, licensed under:

  The Artistic License 2.0 (GPL Compatible)