Package org.geotools.mbstyle
Class MapBoxStyle
Object
MapBoxStyle
MapBox Style facade offering utility methods for quickly working with JSON and converting to
StyledLayerDescriptor
.- Author:
- Jody Garnett (Boundless)
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StyledLayerDescriptor
parse
(InputStream stream) Read in the provided JSON as aStyledLayerDescriptor
.static StyledLayerDescriptor
Read in the provided JSON as aStyledLayerDescriptor
.Validate ability to read json, and parse each layer.
-
Constructor Details
-
MapBoxStyle
public MapBoxStyle()
-
-
Method Details
-
parse
Read in the provided JSON as aStyledLayerDescriptor
.- Parameters:
reader
- JSON content- Returns:
- generated style
- Throws:
ParseException
- Invalid JSON providedIOException
- Problem reading definition from reader
-
parse
Read in the provided JSON as aStyledLayerDescriptor
.- Parameters:
stream
- JSON content- Returns:
- generated style
- Throws:
ParseException
- Invalid JSON providedIOException
- Problem reading definition from stream
-
validate
Validate ability to read json, and parse each layer.- Parameters:
reader
- Reader for reading the style- Returns:
- List of parse exceptions found. If this list is empty, the style is valid.
-