provider

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2021 License: BSD-3-Clause Imports: 10 Imported by: 3

Documentation

Index

Constants

View Source
const InitialLatitude string = "initial-latitude"
View Source
const InitialLongitude string = "initial-longitude"
View Source
const InitialZoom string = "initial-zoom"
View Source
const LeafletEnableDrawFlag string = "leaflet-enable-draw"
View Source
const LeafletEnableFullscreenFlag string = "leaflet-enable-fullscreen"
View Source
const LeafletEnableHashFlag string = "leaflet-enable-hash"
View Source
const MapProviderFlag string = "map-provider"
View Source
const NextzenAPIKeyFlag string = "nextzen-apikey"
View Source
const NextzenStyleURLFlag string = "nextzen-style-url"
View Source
const NextzenTileURLFlag string = "nextzen-tile-url"
View Source
const ProtomapsTileURLFlag string = "protomaps-tile-url"
View Source
const TilezenEnableTilepack string = "tilezen-enable-tilepack"
View Source
const TilezenTilepackPath string = "tilezen-tilepack-path"

Variables

This section is empty.

Functions

func AppendAssetHandlers

func AppendAssetHandlers(mux *http.ServeMux, opts *ProviderOptions) error

func AppendProviderFlags

func AppendProviderFlags(fs *flag.FlagSet) error

func AppendResourcesHandler

func AppendResourcesHandler(handler http.Handler, opts *ProviderOptions) http.Handler

Types

type Provider

type Provider int
const (
	UnknownProvider Provider = iota
	TangramJSProvider
	ProtomapsProvider
)

func (Provider) String

func (p Provider) String() string

type ProviderOptions

type ProviderOptions struct {
	Provider              Provider
	LeafletOptions        *leaflet.LeafletOptions
	TangramJSOptions      *tangramjs.TangramJSOptions
	ProtomapsOptions      *protomaps.ProtomapsOptions
	TilezenEnableTilepack bool
	TilezenTilepackPath   string
	TilezenTilepackURL    string
	InitialLatitude       float64
	InitialLongitude      float64
	InitialZoom           int
}

func ProviderOptionsFromFlagSet

func ProviderOptionsFromFlagSet(fs *flag.FlagSet) (*ProviderOptions, error)

Jump to

Keyboard shortcuts

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