Package org.geotools.mbstyle.source
Class CanvasMBSource
- Object
-
- MBSource
-
- MediaMBSource
-
- CanvasMBSource
-
public class CanvasMBSource extends MediaMBSource
Wrapper around aJSONObjectcontaining a Mapbox canvas source.
-
-
Constructor Summary
Constructors Constructor Description CanvasMBSource(JSONObject json)CanvasMBSource(JSONObject json, MBObjectParser parser)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description BooleangetAnimate()(Optional) Defaults to true.StringgetCanvas()(Required) HTML ID of the canvas from which to read pixels.StringgetType()Type of source.-
Methods inherited from class MediaMBSource
getCoordinates
-
-
-
-
Constructor Detail
-
CanvasMBSource
public CanvasMBSource(JSONObject json)
-
CanvasMBSource
public CanvasMBSource(JSONObject json, MBObjectParser parser)
-
-
Method Detail
-
getCanvas
public String getCanvas()
(Required) HTML ID of the canvas from which to read pixels.- Returns:
- String value for the HTML ID
-
getAnimate
public Boolean getAnimate()
(Optional) Defaults to true. Whether the canvas source is animated. If the canvas is static, animate should be set to false to improve performance.- Returns:
- Boolean for whether the source is animated, defaulting to true.
-
-