Class: Kamelopard::Wait
- Inherits:
-
TourPrimitive
- Object
- Object
- TourPrimitive
- Kamelopard::Wait
- Defined in:
- lib/kamelopard/classes.rb
Overview
Corresponds to a KML gx:Wait object
Instance Attribute Summary collapse
-
#duration ⇒ Object
Returns the value of attribute duration.
Attributes inherited from Object
Instance Method Summary collapse
-
#initialize(duration = 0, options = {}) ⇒ Wait
constructor
A new instance of Wait.
- #to_kml(elem = nil) ⇒ Object
Methods inherited from Object
Constructor Details
#initialize(duration = 0, options = {}) ⇒ Wait
Returns a new instance of Wait.
1401 1402 1403 1404 |
# File 'lib/kamelopard/classes.rb', line 1401 def initialize(duration = 0, = {}) super @duration = duration end |
Instance Attribute Details
#duration ⇒ Object
Returns the value of attribute duration.
1400 1401 1402 |
# File 'lib/kamelopard/classes.rb', line 1400 def duration @duration end |
Instance Method Details
#to_kml(elem = nil) ⇒ Object
1406 1407 1408 1409 1410 1411 1412 1413 1414 |
# File 'lib/kamelopard/classes.rb', line 1406 def to_kml(elem = nil) k = XML::Node.new 'gx:Wait' super k d = XML::Node.new 'gx:duration' d << @duration.to_s k << d elem << k unless elem.nil? k end |