class Armg::WkbDeserializer

Constants

DEFAULT_OPTIONS

Public Class Methods

new(factory: nil, **options) click to toggle source
# File lib/armg/wkb_deserializer.rb, line 9
def initialize(factory: nil, **options)
  options = DEFAULT_OPTIONS.merge(options)
  @wkb_parser = RGeo::WKRep::WKBParser.new(factory, options)
end

Public Instance Methods

deserialize(mysql_geometry) click to toggle source
# File lib/armg/wkb_deserializer.rb, line 14
def deserialize(mysql_geometry)
  wkb = Armg::Utils.mysql_geometry_to_wkb(mysql_geometry)
  @wkb_parser.parse(wkb)
end