| 1 | package Geo::JSON::MultiPolygon; | ||
| 2 | |||
| 3 | 3 | our $VERSION = '0.007'; | |
| 4 | |||
| 5 | # ABSTRACT: object representing a geojson MultiPolygon | ||
| 6 | |||
| 7 | 3 | ▶ | use Moo; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 8 | 3 | extends 'Geo::JSON::Base'; | |
| 9 | 3 | with 'Geo::JSON::Role::Geometry'; | |
| 10 | |||
| 11 | 3 | ▶ | use Geo::JSON::Types -types; |
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||
| 12 | |||
| 13 | 3 | has '+coordinates' => ( isa => Polygons ); | |
| 14 | |||
| 15 | 1 | ▶ | sub all_positions { |
|
Subroutine
all_positions: called CC=1 SCAR=0.0
Pod
documented
| |||
| 16 | 1 | my $self = shift; | |
| 17 | |||
| 18 | return [ | ||
| 19 | 2 | map { @{$_} } | |
| 20 | 1 | map { @{$_} } @{ $self->coordinates } | |
| 21 | ]; | ||
| 22 | } | ||
| 23 | |||
| 24 | 3 | 1; | |
| 25 | |||
| 26 | __END__ | ||