Documentation ¶
Overview ¶
Package geoencoding is a library for encoding and decoding into Go structs using the geometries.
Index ¶
- Constants
- func Decode(s []byte, codeType int) (space.Geometry, error)
- func Encode(g space.Geometry, codeType int) []byte
- func Read(r io.Reader, codeType int) (space.Geometry, error)
- func ReadGeoJSON(r io.Reader, codeType int) (*geojson.FeatureCollection, error)
- func Write(w io.Writer, g space.Geometry, codeType int) error
- func WriteGeoJSON(w io.Writer, g *geojson.FeatureCollection, codeType int) error
- type Encoder
Constants ¶
View Source
const ( WKT = iota WKB GeoJSON GeoCSV Geobuf )
encode type
Variables ¶
This section is empty.
Functions ¶
func ReadGeoJSON ¶
ReadGeoJSON Returns geometry from reader by codeType.
func WriteGeoJSON ¶
WriteGeoJSON write geometry to writer by codeType.
Types ¶
type Encoder ¶
type Encoder interface { // Encode Returns string of that encode geometry. Encode(g space.Geometry) []byte // Decode Returns geometry of that decode string. Decode(s []byte) (space.Geometry, error) // Read Returns geometry from reader. Read(r io.Reader) (space.Geometry, error) // Write write geometry to writer. Write(w io.Writer, g space.Geometry) error // Read Returns geometry from reader. ReadGeoJSON(r io.Reader) (*geojson.FeatureCollection, error) // Write write geometry to writer. WriteGeoJSON(w io.Writer, g *geojson.FeatureCollection) error }
Encoder defines encoder for encoding and decoding into Go structs using the geometries.
Directories ¶
Path | Synopsis |
---|---|
Package geobuf is a library for encoding and decoding geobuf into Go structs using
|
Package geobuf is a library for encoding and decoding geobuf into Go structs using |
decode
Package encode is a library for decoding geobuf into Go structs using
|
Package encode is a library for decoding geobuf into Go structs using |
encode
Package encode is a library for encoding geobuf into Go structs using
|
Package encode is a library for encoding geobuf into Go structs using |
protogeo
Package protogeo is a library for encoding and decoding geobuf into Go structs using Code generated by protoc-gen-go.
|
Package protogeo is a library for encoding and decoding geobuf into Go structs using Code generated by protoc-gen-go. |
Package geocsv is a library for read csv file with geospatial data.
|
Package geocsv is a library for read csv file with geospatial data. |
Package geojson is a library for encoding and decoding GeoJSON into Go structs using the geometries.
|
Package geojson is a library for encoding and decoding GeoJSON into Go structs using the geometries. |
Package wkb is for decoding ESRI's Well Known Binary (WKB) format specification at https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry#Well-known_binary
|
Package wkb is for decoding ESRI's Well Known Binary (WKB) format specification at https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry#Well-known_binary |
Package wkt is for decoding Well Known Text (WKT) format specification at https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry#Well-known_binary
|
Package wkt is for decoding Well Known Text (WKT) format specification at https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry#Well-known_binary |
Click to show internal directories.
Click to hide internal directories.