Geo::GoogleEarth::Document::Placemark - Geo::GoogleEarth::Document::Placemark


Geo-GoogleEarth-Document documentation  | view source Contained in the Geo-GoogleEarth-Document distribution.

Index


NAME

Top

Geo::GoogleEarth::Document::Placemark - Geo::GoogleEarth::Document::Placemark

SYNOPSIS

Top

  use Geo::GoogleEarth::Document;
  my $document=Geo::GoogleEarth::Document->new();
  $document->Placemark();

DESCRIPTION

Top

Geo::GoogleEarth::Document::Placemark is a Geo::GoogleEarth::Document::Base with a few other methods.

USAGE

Top

  my $placemark=$document->Placemark(name=>"Placemark Name",
                                     lat=>$lat,
                                     lon=>$lon,
                                     alt=>$alt);

CONSTRUCTOR

Top

new

  my $placemark=$document->Placemark(
              name       => "White House",
              lat        => 38.89769,       #signed decimal degrees WGS-84
              lon        => -77.036549,     #signed decimal degrees WGS-84
              alt        => 30,             #meters above ellipsoid WGS-84
            );

  my $placemark=$document->Placemark(
              name       => "White House",
              address    => "1600 Pennsylvania Ave NW, Washington, DC 20006",
            );

METHODS

Top

type

Returns the object type.

  my $type=$placemark->type;

structure

Returns a hash reference for feeding directly into XML::Simple.

  my $structure=$placemark->structure;

address

Sets or returns address

  my $address=$placemark->address;

description

Set or returns the description. Google Earth uses this as the HTML description in the Placemark popup window.

snippet

Sets or returns the "snippet", which is the descriptive text shown in the places list. Optionally sets the maximum number of lines to show.

  my $snippet=$placemark->snippet($text);
  $placemark->snippet($text, {maxLines=>2});
  $placemark->snippet("", {maxLines=>0});        #popular setting

visibility

Sets or returns visibility

  my $visibility=$placemark->visibility;

lat

Sets or returns latitude. The format is signed decimal degrees WGS-84.

  my $lat=$placemark->lat;

lon

Sets or returns longitude. The format is signed decimal degrees WGS-84.

  my $lon=$placemark->lon;

alt

Sets or returns altitude. The units are meters above the ellipsoid WGS-84.

  my $alt=$placemark->alt;

Typically, Google Earth "snaps" Placemarks to the surface regardless of how the altitude is set.

BUGS

Top

SUPPORT

Top

Try geo-perl email list.

AUTHOR

Top

    Michael R. Davis (mrdvt92)
    CPAN ID: MRDVT

COPYRIGHT

Top

SEE ALSO

Top

Geo::GoogleEarth::Document creates a GoogleEarth KML Document.


Geo-GoogleEarth-Document documentation  | view source Contained in the Geo-GoogleEarth-Document distribution.