Geo.WKB
Converts to and from WKB and EWKB
point = Geo.WKB.decode("0101000000000000000000F03F000000000000F03F")
Geo.Geometry[type: :point, coordinates: [1, 1], srid: nil]
Geo.WKT.encode(point)
"POINT(1 1)"
point = Geo.WKB.decode("0101000020E61000009EFB613A637B4240CF2C0950D3735EC0")
Geo.Geometry[type: :point, coordinates: [36.9639657, -121.8097725], srid: 4326]
Summary↑
decode(wkb, geometries \\ []) | Takes a WKB string and returns a Geo.Geometry struct or list of Geo.Geometry |
encode(geom, endian \\ :xdr) | Takes a Geo.Geometry or list of Geo.Geometry and returns a WKB string. The endian decides what the byte order will be |
Functions
Takes a WKB string and returns a Geo.Geometry struct or list of Geo.Geometry.
Takes a Geo.Geometry or list of Geo.Geometry and returns a WKB string. The endian decides what the byte order will be