Method: Metro::Units::Point.parse

Defined in:
lib/metro/units/point.rb

.parse(string) ⇒ Object

Parse a string representation of a point object. The supported formated is a comma-delimited string that contains either “x,y” or “x,y,z”.



31
32
33
# File 'lib/metro/units/point.rb', line 31

def self.parse(string)
  at *string.to_s.split(",",3).map(&:to_f)
end