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

Geo::GoogleEarth::Pluggable - Generates GoogleEarth Documents

SYNOPSIS

  use Geo::GoogleEarth::Pluggable;
  my $document    = Geo::GoogleEarth::Pluggable->new(); #is a special Folder...
  my $folder      = $document->Folder();                #Geo::GoogleEarth::Pluggable::Folder object
  my $placemark   = $document->Point();             #Geo::GoogleEarth::Pluggable::Point object
  my $networklink = $document->NetworkLink();           #Geo::GoogleEarth::Pluggable::NetworkLink object
  my $style = $document->Style();                       #Geo::GoogleEarth::Pluggable::Style object
  print $document->render();

DESCRIPTION

Geo::GoogleEarth::Pluggable is a Perl object oriented interface that allows for the creation of XML documents that can be used with Google Earth.

Geo::GoogleEarth::Pluggable is a Geo::GoogleEarth::Pluggable::Folder with a render method.

USAGE

This is all of the code you need to generate a complete Google Earth document.

  use Geo::GoogleEarth::Pluggable;
  my $document=Geo::GoogleEarth::Pluggable->new;
  $document->Point(name=>"White House", lat=>38.897337, lon=>-77.036503);
  print $document->render;

document

render

Returns an XML document with an XML declaration and a root name of "Document"

  print $document->render;

archive

Returns a KMZ formatted Zipped archive of the XML document

  print $document->archive;

xmlns

nextId

  my $id=$document->nextId($type); #$type in {"s", "sm") Style or Style Map

TODO

Full support for LookAt and Style, and StyleMap
Support for default Polygon and Line styles that are nicer than GoogleEarth's
Support for DateTime object in the constructor that is promoted to the LookAt object.
Support for MultiPoint(coordinates=>[{},[],...]) (multiple name.$#coordinates)
Create a Great circle to LineString plugin
Create a GPSPoint plugin (Promote tag as name and datetime to LookAt)

BUGS

Please log on RT and send to the geo-perl email list.

SUPPORT

Try geo-perl email list.

AUTHOR

    Michael R. Davis (mrdvt92)
    CPAN ID: MRDVT

COPYRIGHT

This program is free software licensed under the...

        The BSD License

The full text of the license can be found in the LICENSE file included with this module.

SEE ALSO

Geo::GoogleEarth::Pluggable creates a GoogleEarth Document.

Geo::GoogleEarth::Pluggable::Base is the base for Geo::GoogleEarth::Pluggable::* packages.

Geo::GoogleEarth::Pluggable::Folder is a Geo::GoogleEarth::Pluggable folder object.

Geo::GoogleEarth::Pluggable::NetworkLink is a Geo::GoogleEarth::Pluggable NetworkLink object.

Geo::GoogleEarth::Pluggable::Placemark is a Geo::GoogleEarth::Pluggable Placemark base object.

Geo::GoogleEarth::Pluggable::Style is a Geo::GoogleEarth::Pluggable Style object.