Class: Utilities::Geo::CoordinatesFromLabel
- Inherits:
-
Object
- Object
- Utilities::Geo::CoordinatesFromLabel
- Defined in:
- lib/utilities/geo.rb
Overview
class ConvertToDecimalDegrees
attr_reader(:dd, :dms)
# @param [String] coordinate
def initialize(coordinate)
@dms = coordinate
@dd = Utilities::Geo.degrees_minutes_seconds_to_decimal_degrees(coordinate)
end
end
Instance Attribute Summary collapse
-
#coordinates ⇒ Object
readonly
Returns the value of attribute coordinates.
-
#verbatim_label ⇒ Object
readonly
Returns the value of attribute verbatim_label.
Instance Method Summary collapse
-
#initialize(label) ⇒ CoordinatesFromLabel
constructor
A new instance of CoordinatesFromLabel.
Constructor Details
#initialize(label) ⇒ CoordinatesFromLabel
Returns a new instance of CoordinatesFromLabel.
102 103 104 105 |
# File 'lib/utilities/geo.rb', line 102 def initialize(label) @verbatim_label = label @coordinates = Utilities::Geo.coordinates_regex_from_verbatim_label(label) end |
Instance Attribute Details
#coordinates ⇒ Object (readonly)
Returns the value of attribute coordinates.
99 100 101 |
# File 'lib/utilities/geo.rb', line 99 def coordinates @coordinates end |
#verbatim_label ⇒ Object (readonly)
Returns the value of attribute verbatim_label.
99 100 101 |
# File 'lib/utilities/geo.rb', line 99 def verbatim_label @verbatim_label end |