domain

package
v0.1.8 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jan 17, 2025 License: MIT Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const (
	PropCollectionID      = "collectionId"
	PropCollectionVersion = "collectionVersion"
	PropGeomType          = "collectionGeometryType"
	PropDisplayName       = "displayName"
	PropHighlight         = "highlight"
	PropScore             = "score"
	PropHref              = "href"
)

GeoJSON properties in search response

View Source
const (
	CrsURIPrefix     = "http://www.opengis.net/def/crs/"
	UndefinedSRID    = 0
	WGS84SRIDPostgis = 4326 // Use the same SRID as used during ETL
	WGS84CodeOGC     = "CRS84"
)
View Source
const (
	VersionParam = "version"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type CollectionParams

type CollectionParams map[string]string

CollectionParams parameter key with associated value

type CollectionsWithParams

type CollectionsWithParams map[string]CollectionParams

CollectionsWithParams collection name with associated CollectionParams These are provided though a URL query string as "deep object" params, e.g. paramName[prop1]=value1&paramName[prop2]=value2&....

func (CollectionsWithParams) NamesAndVersions

func (cp CollectionsWithParams) NamesAndVersions() (names []string, versions []int)

type Feature

type Feature struct {
	Type       featureType      `json:"type"`
	Properties map[string]any   `json:"properties"`
	Geometry   geojson.Geometry `json:"geometry"`
	// We expect feature ids to be auto-incrementing integers (which is the default in geopackages)
	// since we use it for cursor-based pagination.
	ID    string `json:"id"`
	Links []Link `json:"links,omitempty"`
}

Feature is a GeoJSON Feature with extras such as links Note: fields in this struct are sorted for optimal memory usage (field alignment)

type FeatureCollection

type FeatureCollection struct {
	Type           featureCollectionType `json:"type"`
	Timestamp      string                `json:"timeStamp,omitempty"`
	Links          []Link                `json:"links,omitempty"`
	Features       []*Feature            `json:"features"`
	NumberReturned int                   `json:"numberReturned"`
}

FeatureCollection is a GeoJSON FeatureCollection with extras such as links Note: fields in this struct are sorted for optimal memory usage (field alignment)

type Link struct {
	Rel       string `json:"rel"`
	Title     string `json:"title,omitempty"`
	Type      string `json:"type,omitempty"`
	Href      string `json:"href"`
	Hreflang  string `json:"hreflang,omitempty"`
	Length    int64  `json:"length,omitempty"`
	Templated bool   `json:"templated,omitempty"`
}

Link according to RFC 8288, https://datatracker.ietf.org/doc/html/rfc8288 Note: fields in this struct are sorted for optimal memory usage (field alignment)

type SRID

type SRID int

SRID Spatial Reference System Identifier: a unique value to unambiguously identify a spatial coordinate system. For example '28992' in https://www.opengis.net/def/crs/EPSG/0/28992

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL