Documentation ¶
Index ¶
- func Contains(g1, g2 *Geom) bool
- func CoveredBy(g1, g2 *Geom) bool
- func Covers(g1, g2 *Geom) bool
- func Disjoint(g1, g2 *Geom) bool
- func Equals(g1, g2 *Geom) bool
- func Intersects(g1, g2 *Geom) bool
- func Touches(g1, g2 *Geom) bool
- func Within(g1, g2 *Geom) bool
- type Geom
- func UnmarshalGeoJSON(data []byte) (*Geom, error)
- func UnmarshalGeoJSONAndIndex(data []byte, idxt IndexType) (*Geom, error)
- func UnmarshalWKB(data []byte) (*Geom, error)
- func UnmarshalWKBAndIndex(data []byte, idxt IndexType) (*Geom, error)
- func UnmarshalWKT(data string) (*Geom, error)
- func UnmarshalWKTAndIndex(data string, idxt IndexType) (*Geom, error)
- type GeomType
- type IndexType
- type MultiPoly
- type Poly
- type Ring
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Intersects ¶
Types ¶
type Geom ¶
type Geom struct {
// contains filtered or unexported fields
}
func UnmarshalGeoJSON ¶
UnmarshalGeoJSON parses geometries from a GeoJSON representation. Using the Natural indexation.
func UnmarshalGeoJSONAndIndex ¶
UnmarshalGeoJSONAndIndex parses geometries from a GeoJSON representation, and sets the indexation type.
func UnmarshalWKB ¶
UnmarshalWKB parses geometries from a WKB representation. Using the Natural indexation.
func UnmarshalWKBAndIndex ¶
UnmarshalWKBAndIndex parses geometries from a WKB representation, and sets the indexation type.
func UnmarshalWKT ¶
UnmarshalWKT parses geometries from a WKT representation. Using the Natural indexation.
func UnmarshalWKTAndIndex ¶
UnmarshalWKTAndIndex parses geometries from a WKT representation, and sets the indexation type.
func (*Geom) AsMultiPoly ¶
AsMultiPoly returns a MultiPoly of the geometry, returns false if not applicable.
func (*Geom) Properties ¶
Properties returns a string that represents any extra JSON from a parsed GeoJSON geometry. Such as the "id" or "properties" fields.
type GeomType ¶
type GeomType uint8
const ( Point GeomType = iota + 1 // Point. LineString // LineString. Polygon // Polygon. MultiPoint // MultiPoint, collection of points. MultiLineString // MultiLineString, collection of linestrings. MultiPolygon // MultiPolygon, collection of polygons. GeometryCollection // GeometryCollection, collection of geometries. )
type MultiPoly ¶
type MultiPoly struct {
// contains filtered or unexported fields
}
func (*MultiPoly) PolygonsCount ¶
PolygonsCount returns the count of polygons in the multipoly.
type Poly ¶
type Poly struct {
// contains filtered or unexported fields
}
func (*Poly) IsClockWise ¶
IsClockWise returns true if the polygon is clock wise.