Class: KML::GroundOverlay
- Defined in:
- lib/kml/ground_overlay.rb
Overview
This element draws an image overlay draped onto the terrain.
Instance Attribute Summary collapse
-
#altitude ⇒ Object
Returns the value of attribute altitude.
-
#altitude_mode ⇒ Object
Returns the value of attribute altitude_mode.
-
#lat_lon_box ⇒ Object
Returns the value of attribute lat_lon_box.
Attributes inherited from Overlay
Attributes inherited from Feature
#address, #address_details, #description, #look_at, #metadata, #name, #phone_number, #region, #snippet, #style_selector, #style_url, #time_primitive
Attributes inherited from Object
Instance Method Summary collapse
Methods inherited from Feature
#open, #open=, #open?, #parse, #visibility, #visibility=, #visibility?
Methods inherited from Object
Constructor Details
This class inherits a constructor from KML::Object
Instance Attribute Details
#altitude ⇒ Object
Returns the value of attribute altitude.
4 5 6 |
# File 'lib/kml/ground_overlay.rb', line 4 def altitude @altitude end |
#altitude_mode ⇒ Object
Returns the value of attribute altitude_mode.
5 6 7 |
# File 'lib/kml/ground_overlay.rb', line 5 def altitude_mode @altitude_mode end |
#lat_lon_box ⇒ Object
Returns the value of attribute lat_lon_box.
6 7 8 |
# File 'lib/kml/ground_overlay.rb', line 6 def lat_lon_box @lat_lon_box end |
Instance Method Details
#render(xm = Builder::XmlMarkup.new(:indent => 2)) ⇒ Object
8 9 10 11 12 13 14 15 16 |
# File 'lib/kml/ground_overlay.rb', line 8 def render(xm=Builder::XmlMarkup.new(:indent => 2)) raise InvalidKMLError, "GroundOverlay.lat_lon_box is required" if lat_lon_box.nil? xm.GroundOverlay { super xm.altitude(altitude) unless altitude.nil? xm.altitudeMode(altitude_mode) unless altitude_mode.nil? lat_lon_box.render(xm) } end |