Versions in this module Expand all Collapse all v0 v0.10.0 Nov 8, 2023 Changes in this version + const TypeLineString + const TypeMultiLineString + const TypeMultiPoint + const TypeMultiPolygon + const TypePoint + const TypePolygon + var CustomJSONMarshaler interface{ ... } = nil + var CustomJSONUnmarshaler interface{ ... } = nil + var ErrInvalidGeometry = errors.New("geojson: invalid geometry") + type BBox []float64 + func NewBBox(b orb.Bound) BBox + func (bb BBox) Bound() orb.Bound + func (bb BBox) Valid() bool + type Feature struct + BBox BBox + Geometry orb.Geometry + ID interface{} + Properties Properties + Type string + func NewFeature(geometry orb.Geometry) *Feature + func UnmarshalFeature(data []byte) (*Feature, error) + func (f *Feature) Point() orb.Point + func (f *Feature) UnmarshalBSON(data []byte) error + func (f *Feature) UnmarshalJSON(data []byte) error + func (f Feature) MarshalBSON() ([]byte, error) + func (f Feature) MarshalJSON() ([]byte, error) + type FeatureCollection struct + BBox BBox + ExtraMembers Properties + Features []*Feature + Type string + func NewFeatureCollection() *FeatureCollection + func UnmarshalFeatureCollection(data []byte) (*FeatureCollection, error) + func (fc *FeatureCollection) Append(feature *Feature) *FeatureCollection + func (fc *FeatureCollection) UnmarshalBSON(data []byte) error + func (fc *FeatureCollection) UnmarshalJSON(data []byte) error + func (fc FeatureCollection) MarshalBSON() ([]byte, error) + func (fc FeatureCollection) MarshalJSON() ([]byte, error) + type Geometry struct + Coordinates orb.Geometry + Geometries []*Geometry + Type string + func NewGeometry(g orb.Geometry) *Geometry + func UnmarshalGeometry(data []byte) (*Geometry, error) + func (g *Geometry) Geometry() orb.Geometry + func (g *Geometry) MarshalBSON() ([]byte, error) + func (g *Geometry) MarshalBSONValue() (bsontype.Type, []byte, error) + func (g *Geometry) MarshalJSON() ([]byte, error) + func (g *Geometry) UnmarshalBSON(data []byte) error + func (g *Geometry) UnmarshalJSON(data []byte) error + type LineString orb.LineString + func (ls *LineString) UnmarshalBSON(data []byte) error + func (ls *LineString) UnmarshalJSON(data []byte) error + func (ls LineString) Geometry() orb.Geometry + func (ls LineString) MarshalBSON() ([]byte, error) + func (ls LineString) MarshalJSON() ([]byte, error) + type MultiLineString orb.MultiLineString + func (mls *MultiLineString) UnmarshalBSON(data []byte) error + func (mls *MultiLineString) UnmarshalJSON(data []byte) error + func (mls MultiLineString) Geometry() orb.Geometry + func (mls MultiLineString) MarshalBSON() ([]byte, error) + func (mls MultiLineString) MarshalJSON() ([]byte, error) + type MultiPoint orb.MultiPoint + func (mp *MultiPoint) UnmarshalBSON(data []byte) error + func (mp *MultiPoint) UnmarshalJSON(data []byte) error + func (mp MultiPoint) Geometry() orb.Geometry + func (mp MultiPoint) MarshalBSON() ([]byte, error) + func (mp MultiPoint) MarshalJSON() ([]byte, error) + type MultiPolygon orb.MultiPolygon + func (mp *MultiPolygon) UnmarshalBSON(data []byte) error + func (mp *MultiPolygon) UnmarshalJSON(data []byte) error + func (mp MultiPolygon) Geometry() orb.Geometry + func (mp MultiPolygon) MarshalBSON() ([]byte, error) + func (mp MultiPolygon) MarshalJSON() ([]byte, error) + type Point orb.Point + func (p *Point) UnmarshalBSON(data []byte) error + func (p *Point) UnmarshalJSON(data []byte) error + func (p Point) Geometry() orb.Geometry + func (p Point) MarshalBSON() ([]byte, error) + func (p Point) MarshalJSON() ([]byte, error) + type Polygon orb.Polygon + func (p *Polygon) UnmarshalBSON(data []byte) error + func (p *Polygon) UnmarshalJSON(data []byte) error + func (p Polygon) Geometry() orb.Geometry + func (p Polygon) MarshalBSON() ([]byte, error) + func (p Polygon) MarshalJSON() ([]byte, error) + type Properties map[string]interface + func (p Properties) Clone() Properties + func (p Properties) MustBool(key string, def ...bool) bool + func (p Properties) MustFloat64(key string, def ...float64) float64 + func (p Properties) MustInt(key string, def ...int) int + func (p Properties) MustString(key string, def ...string) string