Constructor
new Raster(geoJSON)
The `Raster` class represents a raster annotation item. It inherits from the `AnnotationItem` class and provides methods to work with raster annotations.
Parameters:
Name | Type | Description |
---|---|---|
geoJSON |
Object | The GeoJSON object containing annotation data. |
Properties:
Name | Type | Description |
---|---|---|
_paperItem |
paper.Group | The associated paper item representing the raster. |
- Source:
Throws:
-
Throws an error if the GeoJSON type or subtype is invalid.
- Type
- string
Extends
- AnnotationItem
Methods
getGeoJSONType() → {Object}
Get the type of this object.
- Source:
Returns:
with fields `type === 'GeometryCollection'` and `subtype === 'Raster'`
- Type
- Object
toGeoJSONGeometry() → {Object}
Convert the raster annotation to a GeoJSON geometry.
- Source:
Returns:
The GeoJSON representation of the raster annotation.
- Type
- Object
(static) supportsGeoJSONType(type, subtypeopt) → {Boolean}
Retrieves the supported types by the Raster annotation item.
Parameters:
Name | Type | Attributes | Description |
---|---|---|---|
type |
String | ||
subtype |
String |
<optional> |
- Source:
Returns:
Whether this constructor supports the requested type/subtype
- Type
- Boolean