Documentation ¶
Overview ¶
Package middleware defines utility decorators of sources as such, middlewares implement the source interface
Index ¶
Constants ¶
View Source
const NestingLevel timedContextKey = "tckn"
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache interface { Get(key interface{}) (value interface{}, found bool) Set(key, value interface{}) }
Cache is the interface of cache implementations expected by the Cacher
type Cacher ¶
type Cacher struct {
// contains filtered or unexported fields
}
Cacher is a tile retriever that uses a cache
type Delayer ¶
type Delayer struct {
// contains filtered or unexported fields
}
Delayer is a tile source that returns the tile in at least n milliseconds where min < n < max useful for testing and simulations
func NewDelayer ¶
New yields a fresh new Delayer tile retriever
type Fallback ¶
type Fallback struct {
// contains filtered or unexported fields
}
func NewFallback ¶
type Masker ¶
type Masker struct {
// contains filtered or unexported fields
}
type Resizer ¶
type Resizer struct {
// contains filtered or unexported fields
}
func NewResizer ¶
func NewResizer(source source.Source, sm SamplingMethod, targetSize uint16) *Resizer
type SamplingMethod ¶
type SamplingMethod int
const ( NearestNeighbor SamplingMethod = iota + 1 Box Linear Gaussian MitchellNetravali CatmullRom Lanczos )
type Switcher ¶
type Switcher struct {
// contains filtered or unexported fields
}
func NewSwitcher ¶
func NewSwitcher(name string, method SwitchingMethod) *Switcher
type SwitchingMethod ¶
Click to show internal directories.
Click to hide internal directories.