Base class for shield renderers. Shield renderers use a builder pattern to configure its options.

Hierarchy

Constructors

Properties

_fontSpec: string
_fontsLoaded: boolean = false
_map: Map
_networkPredicate: StringPredicate = ...
_preFontImageCache: Map<string, RouteDefinition> = ...

Cache images that are loaded before fonts so they can be re-rendered later

_routeParser: RouteParser
_shieldDefCallbacks: any[] = []
_shieldPredicate: StringPredicate = ...

Methods

  • Get a blank route shield graphics context in a specified size

    Parameters

    Returns CanvasRenderingContext2D

  • Get a blank route shield sprite in the default size

    Returns CanvasRenderingContext2D

  • Get the graphic for a specified route

    Parameters

    • network: string
    • ref: string
    • name: string

    Returns CanvasRenderingContext2D

  • Get the handler function for styleimagemissing event calls

    See MapStyleImageMissingEvent for more details.

    Returns ((e) => void)

      • (e): void
      • Parameters

        • e: MapStyleImageMissingEvent

        Returns void

Generated using TypeDoc