Sha256: ff53845c46ef15df8e0bad2122edd0cbb8c13a5e9017842c99160c912daa2a49
Contents?: true
Size: 566 Bytes
Versions: 18
Compression:
Stored size: 566 Bytes
Contents
module Frodo module Properties module Geography class Point < Base def type 'Edm.GeographyPoint' end def coords_to_s value.join(' ') end def coords_from_s(str) str.split(' ').map(&:to_f) end def xml_value { pos: coords_to_s } end private def self.parse_xml(property_xml) property_xml.xpath('//pos').map do |el| el.content.split(' ').map(&:to_f) end.flatten end end end end end
Version data entries
18 entries across 18 versions & 1 rubygems