public class MapImpl extends java.lang.Object implements Map, Tileable, Disposable, ComponentContextAware
The implementation class of the map service component interface.
Map service component is a type of GIS service component encapsulating GIS functions associated with the map. This class implements the interface.
The service providers in a map service component must be map service providers (MapProvider
).
Below is an example to show how to construct map service component using SuperMap data.
public MapImpl getMapComponent() { // Initialize the settings of SuperMap map service provider. UGCMapProviderSetting ugcPSetting = new UGCMapProviderSetting(); // SuperMap workspace path. ugcPSetting.setWorkspacePath("C:\\SuperMap\\World\\World.sxwu"); // The output path of the map image of the map service provider. ugcPSetting.setOutputPath(".\\output1"); // The publish site of the map image of the map service provider.. ugcPSetting.setOutputSite("http://localhost"); ugcPSetting.setName("default"); // The map service provider set, used to initialize the map service component context. List<MapProviderSetting> ugcPSettings = new ArrayList<MapProviderSetting>(); ugcPSettings.add(ugcPSetting); // Configuration information of the map service component, used to initialize the map service component context. MapConfig config = new MapConfig(); // The output path of the map image of the map service component. config.setOutputPath(".\\output"); // The publish site of the map image of the map service component. config.setOutputSite("http://localhost/output"); // Initialize the context of the map service component. MapContext mapContext = new MapContext(); mapContext.setMapProviderSettings(ugcPSettings); mapContext.setConfig(config); // Create the map service component MapImpl mapc = new MapImpl(mapContext); return mapc; }
Component
Modifier and Type | Field and Description |
---|---|
protected static java.lang.String |
PROVIDER_FACTORY
The factory object keyword of the provider.
|
Constructor and Description |
---|
MapImpl()
The default constructor.
|
MapImpl(MapContext mapContext)
Constructs a MapImpl object with context information of the specified map service component.
|
Modifier and Type | Method and Description |
---|---|
void |
clearCache(Rectangle2D bounds)
Removing caches within the specified map extent.
|
void |
clearCache(Rectangle2D bounds, MapParameter mapParameter, ImageOutputOption outputOption)
Clears the cache within specified map extent.
|
void |
dispose()
Releases the resources used by this map service component.
|
void |
dispose(boolean disposeProvidersInContext) |
QueryResult |
findNearest(Geometry geometry, double maxDistance, QueryParameterSet queryParameterSet, java.lang.String mapName)
Queries the geometric objects on a specified map whose distances to a specified geometry are within a certain value.
|
java.util.List<ChartFeatureInfoSpec> |
getChartFeatureInfoSpecs(java.lang.String mapName)
Chart feature.
|
MapParameter |
getDefaultMapParameter(java.lang.String mapName)
${services_components_impl_MapImpl_method_getDefaultMapParameter_Title}
|
MapParameter |
getDefaultMapParameterNoCache(MapProvider mapProvider, java.lang.String mapName) |
java.util.List<PrjCoordSys> |
getDynamicPrjCoordsyses(java.lang.String mapName) |
MapImage |
getMapImage(MapParameter mapParameter, ImageOutputOption outputOption)
Gets map images according to map parameters and image output settings.
|
java.util.List<java.lang.String> |
getMapNames()
Gets map names list.
|
MapParameter |
getMapParameter(java.lang.String mapName)
Gets parameters of the specified map.
|
byte[] |
getMVTFonts(java.lang.String mapName, java.lang.String fontstack, java.lang.String range)
Gets the font of sdf format.
|
java.lang.String |
getMVTSpriteJson(java.lang.String mapName, java.lang.String spriteName)
Gets the json of the MVT Sprite.
|
byte[] |
getMVTSpriteResource(java.lang.String mapName, java.lang.String spriteName)
Gets the resource of the MVT Sprite.
|
byte[] |
getMVTTile(VectorTileParameter vectorTileParameter)
Gets MVT tile of the map.
|
Overview |
getOverview(MapParameter mapParameter, ImageOutputOption outputOption)
Gets eagle-eye map according to map parameters and image output settings.
|
protected MapProvider |
getProvider(java.lang.String name)
Gets the map service provider of the specified map.
|
protected MapProvider |
getQueryProvider(java.lang.String name)
Gets the map service provider required by the query function.
|
java.lang.String |
getResource(ResourceParameter resourceParameter)
Gets resource image according to resource image parameter.
|
byte[] |
getResource(ResourceParameter resourceParameter, Point2D[] points)
Gets resource image according to resource image parameter.
|
byte[] |
getResource(java.lang.String mapName, java.lang.String symbolId, OutputFormat format)
Gets resource image according to resource image parameter.
|
TilesetInfo[] |
getTilesetInfos(java.lang.String mapName)
Returns all the tiles set of the specified map.
|
MapImage |
getTrackingLayerImage(MapParameter mapParameter, ImageOutputOption outputOption)
Gets images of TrackingLayer according to map parameters and image output settings.
|
UTFGridResult |
getUTFGrid(UTFGridParameter gridParameter)
Extracts the UTFGrid object from a specified layer according to the map extent.
|
VectorStyle |
getVectorStyle(java.lang.String mapName, java.lang.String[] layerNames, VectorStyleType type)
Gets the specified vector layer style in the specified map.
|
VectorTileData |
getVectorTile(VectorTileParameter vectorTileParameter)
Gets vector tile of the map.
|
java.lang.String[] |
listMVTSprites(java.lang.String mapName)
Lists all the Sprites names of the MVT.
|
MeasureResult |
measureArea(java.lang.String mapName, Point2D[] points, MeasureParameter measureParameter)
${services_components_impl_MapImpl_method_measureArea_Title}
|
MeasureResult |
measureDistance(java.lang.String mapName, Point2D[] points, MeasureParameter measureParameter)
${services_components_impl_MapImpl_method_measureDistance_Title}
|
MapImage |
pan(double offsetX, double offsetY, MapParameter mapParameter, ImageOutputOption outputOption)
Map panning.
|
QueryResult |
queryByBounds(java.lang.String mapName, Rectangle2D bounds, QueryParameterSet queryParameterSet)
Queries the geometries within a specified range on the map.
|
QueryResult |
queryByDistance(java.lang.String mapName, Geometry geometry, double distance, QueryParameterSet queryParameterSet)
Queries all the geometric objects on a specified map whose distances to a specified geometry are within a certain value.
|
QueryResult |
queryByGeometry(java.lang.String mapName, Geometry geometry, SpatialQueryMode spatialQueryMode, QueryParameterSet queryParameterSet)
${services_components_impl_MapImpl_method_queryByGeometry_Title}
|
QueryResult |
queryByKeywords(java.lang.String mapName, KeywordsQueryParameterSet queryParameterSet)
Queries the map features based on the keyword.
|
QueryResult |
queryBySQL(java.lang.String mapName, QueryParameterSet queryParameterSet)
${services_components_impl_MapImpl_method_queryBySQL_Title}
|
QueryResult |
queryChart(java.lang.String mapName, java.lang.String[] chartLayerNames, ChartQueryParameterSet chartQueryParams)
Chart feature.
|
QueryResult |
queryChart(java.lang.String mapName, java.lang.String[] chartLayerNames, ChartQueryParameterSet chartQueryParams, Rectangle2D bounds)
Chart feature.
|
void |
setComponentContext(ComponentContext context)
Sets the context of map service component.
|
protected void |
setComponentContext(ComponentContext context, ImageTileCache<TileSourceInfo> tileCache, UTFGridTileCache<TileSourceInfo> utfGridTileCache, VectorTileCache<TileSourceInfo> vectorTileCache) |
MapParameter |
setDefaultMapParameter(MapParameter mapParameter)
${services_components_impl_MapImpl_method_setDefaultMapParameter_Title}
|
boolean |
support(java.lang.String mapName, MapCapability capability)
Determines whether the map supports the specified function.
|
boolean |
updateMap(MapParameter mapParameter)
Updates the map status permanently, which will do a persistence in the disk.
|
void |
updateVectorStyle(java.lang.String mapName, java.lang.String layerName, VectorStyleType type, java.lang.String style)
Updates the specified vector layer style in the specified map.
|
void |
useCachedDefaultMapParams(boolean use) |
MapImage |
viewByBounds(Rectangle2D bounds, MapParameter mapParameter, ImageOutputOption outputOption)
Displays map according to the bounds of geographic coordinates.
|
MapImage |
viewByScale(Point2D center, double scale, MapParameter mapParameter, ImageOutputOption outputOption)
Displays a map according to the specified center point and scale.
|
MapImage |
viewEntire(MapParameter mapParameter, ImageOutputOption outputOption)
Displays a map in the Full Extent mode according to map parameters and image output settings.
|
MapImage |
viewEntire(java.lang.String layerName, MapParameter mapParameter, ImageOutputOption outputOption)
Displays a map in the Full Extent mode according to map layer name, map parameters and image output settings.
|
MapImage |
zoom(Point2D center, double ratio, MapParameter mapParameter, ImageOutputOption outputOption)
Performs map scaling according to the specified center point, zoom scale, map parameter and image output settings.
|
protected static final java.lang.String PROVIDER_FACTORY
The factory object keyword of the provider. Default is "MapProviderFactory".
public MapImpl(MapContext mapContext)
Constructs a MapImpl object with context information of the specified map service component.
mapContext
- Context information of the map service component. This parameter cannot be null.public MapImpl()
The default constructor.
public void useCachedDefaultMapParams(boolean use)
public void clearCache(Rectangle2D bounds) throws MapException
Removing caches within the specified map extent.
clearCache
in interface Map
bounds
- The specified map extent.MapException
- A map service component exception.public void clearCache(Rectangle2D bounds, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Clears the cache within specified map extent.
clearCache
in interface Map
bounds
- The specified map extent.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- Displays a map according to the specified center point and scale.public java.util.List<java.lang.String> getMapNames()
Gets map names list.
getMapNames
in interface Map
getMapNames
in interface Tileable
public MapParameter getMapParameter(java.lang.String mapName) throws MapException
Gets parameters of the specified map.
getMapParameter
in interface Map
mapName
- The map name.MapException
- A map service component exception, which is thrown if the map named by mapName parameter doesn't exist.public MapImage getMapImage(MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Gets map images according to map parameters and image output settings.
getMapImage
in interface Map
mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.public byte[] getResource(java.lang.String mapName, java.lang.String symbolId, OutputFormat format) throws MapException
Map
getResource
in interface Map
symbolId
- Symbol id.format
- Symbol Format.MapException
- Displays a map according to the specified center point and scale.public java.lang.String getResource(ResourceParameter resourceParameter) throws MapException
Gets resource image according to resource image parameter.
getResource
in interface Map
resourceParameter
- The resource image parameter.MapException
- A map service component exception, which is thrown when the size of the current map names list is less than 0.java.lang.IllegalArgumentException
- When resourceParameter is null, this exception will be thrown.public byte[] getResource(ResourceParameter resourceParameter, Point2D[] points) throws MapException
Map
getResource
in interface Map
resourceParameter
- The resource image parameter, including the image height, width, type, resource type, style, etcpoints
- The points used to draw resource images.MapException
- Displays a map according to the specified center point and scale.public MeasureResult measureDistance(java.lang.String mapName, Point2D[] points, MeasureParameter measureParameter) throws MapException
${services_components_impl_MapImpl_method_measureDistance_Title}
${services_components_impl_MapImpl_method_measureDistance_Description}
measureDistance
in interface Map
mapName
- ${services_components_impl_MapImpl_method_measureDistance_param_mapName}points
- ${services_components_impl_MapImpl_method_measureDistance_param_points}measureParameter
- ${services_components_impl_MapImpl_method_measureDistance_param_measureParameter}MapException
- ${services_components_impl_MapImpl_method_measureDistance_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_measureDistance_throw_IllegalArgumentException}public MeasureResult measureArea(java.lang.String mapName, Point2D[] points, MeasureParameter measureParameter) throws MapException
${services_components_impl_MapImpl_method_measureArea_Title}
${services_components_impl_MapImpl_method_measureArea_Description}
measureArea
in interface Map
mapName
- ${services_components_impl_MapImpl_method_measureArea_param_mapName}points
- ${services_components_impl_MapImpl_method_measureArea_param_points}measureParameter
- ${services_components_impl_MapImpl_method_measureArea_param_measureParameter}MapException
- ${services_components_impl_MapImpl_method_measureArea_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_measureArea_throw_IllegalArgumentException}public QueryResult queryByDistance(java.lang.String mapName, Geometry geometry, double distance, QueryParameterSet queryParameterSet) throws MapException
Queries all the geometric objects on a specified map whose distances to a specified geometry are within a certain value. When you limit the number of the returned geometries (specified by QueryParameterSet.expectCount
), the query result is the expectCount object extracting randomly from the total query records.
Which means to query all the geometries within a circle whose center is the specified geometry.
The sample of this query is as follows. About the map service component initialization, please seemap component initialization sample.
public QueryResult queryByDistanceSample() throws MapException { //Initialize the map service component MapImpl mapc = getMapComponent(); // The attribute query parameter set. QueryParameterSet queryParameters = new QueryParameterSet(); QueryParameter[] queryLayerParams = new QueryParameter[1]; queryLayerParams[0] = new QueryParameter(); queryLayerParams[0].name = "Countries@World"; // Attribute filter condition. Here is set to null. queryLayerParams[0].attributeFilter = ""; // The field name to be returned (Not case sensitive). queryLayerParams[0].fields = new String[] { "Country", "Capital" }; queryParameters.queryParams = queryLayerParams; // The query result which is set to only contain attribute information queryParameters.queryOption = QueryOption.ATTRIBUTE; // Create the reference geometry object for buffer query. Here is a triangular planar object. Point2D p1 = new Point2D(101.0, 26.0); Point2D p2 = new Point2D(97.0, 21.0); Point2D p3 = new Point2D(103.0, 16.0); Point2D[] point2ds = { p1, p2, p3 }; Geometry geometry = Geometry.fromPoint2Ds(point2ds, GeometryType.REGION); // Query all features within 0.5 of the specified objects on the layer of "Countries@World" of the map of "WorldMap" QueryResult queryResult = mapc.queryByDistance("WorldMap", geometry, 0.5, queryParameters); mapc.dispose(); return queryResult; }
queryByDistance
in interface Map
mapName
- The map name.geometry
- The geometric object.distance
- The unit of the distance extent is identical to that of dataset coordinates corresponding to the current map.queryParameterSet
- Query parameters can query multiple layers of a map. The query parameters in a single layer can be set in queryParameterSet.queryParams[i]
.MapException
- A map service component exception, which is thrown if the map named by mapName parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:queryParameterSet.queryParams
is null, or the length of the array is 0.public QueryResult queryByGeometry(java.lang.String mapName, Geometry geometry, SpatialQueryMode spatialQueryMode, QueryParameterSet queryParameterSet) throws MapException
${services_components_impl_MapImpl_method_queryByGeometry_Title}
${services_components_impl_MapImpl_method_queryByGeometry_Description}
queryByGeometry
in interface Map
mapName
- ${services_components_impl_MapImpl_method_queryByGeometry_param_mapName}geometry
- ${services_components_impl_MapImpl_method_queryByGeometry_param_geometry}spatialQueryMode
- ${services_components_impl_MapImpl_method_queryByGeometry_param_spatialQueryMode}queryParameterSet
- ${services_components_impl_MapImpl_method_queryByGeometry_param_queryParameterSet}MapException
- ${services_components_impl_MapImpl_method_queryByGeometry_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_queryByGeometry_throw_IllegalArgumentException}public QueryResult queryBySQL(java.lang.String mapName, QueryParameterSet queryParameterSet) throws MapException
${services_components_impl_MapImpl_method_queryBySQL_Title}
${services_components_impl_MapImpl_method_queryBySQL_Description}
queryBySQL
in interface Map
mapName
- ${services_components_impl_MapImpl_method_queryBySQL_param_mapName}queryParameterSet
- ${services_components_impl_MapImpl_method_queryBySQL_param_queryParameterSet}MapException
- ${services_components_impl_MapImpl_method_queryBySQL_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_queryBySQL_throw_IllegalArgumentException}public QueryResult queryByBounds(java.lang.String mapName, Rectangle2D bounds, QueryParameterSet queryParameterSet) throws MapException
Queries the geometries within a specified range on the map.
queryByBounds
in interface Map
mapName
- The map name.bounds
- The specified query bounds.queryParameterSet
- Query parameters can query multiple layers of a map. The query parameters in a single layer can be set in queryParameters.queryParams[i]
.MapException
- A map service component exception, which is thrown if the map named by mapName parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:queryParameterSet.queryParams
is null, or the length of the array is 0.public MapParameter setDefaultMapParameter(MapParameter mapParameter) throws MapException
${services_components_impl_MapImpl_method_setDefaultMapParameter_Title}
${services_components_impl_MapImpl_method_setDefaultMapParameter_Description}
setDefaultMapParameter
in interface Map
mapParameter
- ${services_components_impl_MapImpl_method_setDefaultMapParameter_param_mapParameter}MapException
- ${services_components_impl_MapImpl_method_setDefaultMapParameter_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_setDefaultMapParameter_throw_IllegalArgumentException}public MapParameter getDefaultMapParameter(java.lang.String mapName) throws MapException
${services_components_impl_MapImpl_method_getDefaultMapParameter_Title}
${services_components_impl_MapImpl_method_getDefaultMapParameter_Description}
getDefaultMapParameter
in interface Map
mapName
- ${services_components_impl_MapImpl_method_getDefaultMapParameter_param_mapName}MapException
- ${services_components_impl_MapImpl_method_getDefaultMapParameter_throws_MapException}public MapImage pan(double offsetX, double offsetY, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Map panning.
pan
in interface Map
offsetX
- Geographic coordinates offset in the horizontal axis.offsetY
- Geographic coordinates offset in the vertical axis.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- Displays a map according to the specified center point and scale.public MapImage viewByBounds(Rectangle2D bounds, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Displays map according to the bounds of geographic coordinates.
viewByBounds
in interface Map
bounds
- The bounds of geographic coordinates.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- Displays a map according to the specified center point and scale.java.lang.IllegalArgumentException
- If the following situations occur, an IllegalArgumentException will be thrown.public MapImage viewByScale(Point2D center, double scale, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Displays a map according to the specified center point and scale.
The sample is as follows. About the map service component initialization, please seemap component initialization sample.
public MapImage viewByScaleSample() throws MapException { //Initialize the map service component MapImpl mapc = getMapComponent(); // The coordinates of the center point. Point2D center = new Point2D(101.0, 26.0); // The scale for outputting map. double scale = 0.00000003; // The map parameters. Here the default parameters of "WorldMap" is used. MapParameter mapParameter = mapc.getDefaultMapParameter("WorldMap"); // Image output settings. Here the output format is set to PNG. ImageOutputOption outputOption = new ImageOutputOption(); outputOption.format = OutputFormat.PNG; MapImage mapImage = mapc.viewByScale(center, scale, mapParameter, outputOption); // Dispose the resources occupied by the map component mapc.dispose(); return mapImage; }
viewByScale
in interface Map
center
- Center point.scale
- The specified scale.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:public MapImage zoom(Point2D center, double ratio, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Performs map scaling according to the specified center point, zoom scale, map parameter and image output settings.
zoom
in interface Map
center
- Center point.ratio
- The zoom scale.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:public MapImage viewEntire(MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Displays a map in the Full Extent mode according to map parameters and image output settings.
viewEntire
in interface Map
mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.mapName
parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:public MapImage getTrackingLayerImage(MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Gets images of TrackingLayer according to map parameters and image output settings.
getTrackingLayerImage
in interface Map
mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:public QueryResult findNearest(Geometry geometry, double maxDistance, QueryParameterSet queryParameterSet, java.lang.String mapName) throws MapException
Queries the geometric objects on a specified map whose distances to a specified geometry are within a certain value. When limit the number of returned geometric objects (specified by QueryParameterSet.expectCount
), the query result is the expectCount features nearest to the center in the records. There is no orders of expectCount.
findNearest
in interface Map
geometry
- ${services_components_impl_MapImpl_method_findNearest_param_geometry}maxDistance
- The unit of the distance extent is identical to that of dataset coordinates corresponding to the current map.queryParameterSet
- ${services_components_impl_MapImpl_method_findNearest_param_queryParameterSet}mapName
- ${services_components_impl_MapImpl_method_findNearest_param_mapName}MapException
- ${services_components_impl_MapImpl_method_findNearest_throws_MapException}java.lang.IllegalArgumentException
- ${services_components_impl_MapImpl_method_findNearest_throw_IllegalArgumentException}public MapImage viewEntire(java.lang.String layerName, MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Displays a map in the Full Extent mode according to map layer name, map parameters and image output settings.
The full geographic map extent to display is the minimum circumscribed rectangle of the specified layer.
viewEntire
in interface Map
layerName
- Layer name, used to determine the full map extent.mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.java.lang.IllegalArgumentException
- An IllegalArgumentException will be thrown if the following situations occur:public Overview getOverview(MapParameter mapParameter, ImageOutputOption outputOption) throws MapException
Gets eagle-eye map according to map parameters and image output settings.
getOverview
in interface Map
mapParameter
- Map parameters.outputOption
- Image output settings.MapException
- A map service component exception, which is thrown if the map named by mapParameter.name
parameter doesn't exist.java.lang.IllegalArgumentException
- If the following situations occur, an IllegalArgumentException will be thrown.public java.util.List<PrjCoordSys> getDynamicPrjCoordsyses(java.lang.String mapName) throws MapException
getDynamicPrjCoordsyses
in interface Map
MapException
public java.util.List<ChartFeatureInfoSpec> getChartFeatureInfoSpecs(java.lang.String mapName) throws MapException
getChartFeatureInfoSpecs
in interface Map
MapException
public QueryResult queryChart(java.lang.String mapName, java.lang.String[] chartLayerNames, ChartQueryParameterSet chartQueryParams) throws MapException
queryChart
in interface Map
MapException
public QueryResult queryChart(java.lang.String mapName, java.lang.String[] chartLayerNames, ChartQueryParameterSet chartQueryParams, Rectangle2D bounds) throws MapException
queryChart
in interface Map
MapException
public UTFGridResult getUTFGrid(UTFGridParameter gridParameter) throws MapException
getUTFGrid
in interface Map
gridParameter
- UTFGrid request parameters object.MapException
- The exception.public MapParameter getDefaultMapParameterNoCache(MapProvider mapProvider, java.lang.String mapName) throws MapException
MapException
public void dispose()
Releases the resources used by this map service component.
dispose
in interface Disposable
public void dispose(boolean disposeProvidersInContext)
public void setComponentContext(ComponentContext context)
Sets the context of map service component.
setComponentContext
in interface ComponentContextAware
context
- The context of map service component.protected void setComponentContext(ComponentContext context, ImageTileCache<TileSourceInfo> tileCache, UTFGridTileCache<TileSourceInfo> utfGridTileCache, VectorTileCache<TileSourceInfo> vectorTileCache)
public TilesetInfo[] getTilesetInfos(java.lang.String mapName)
Returns all the tiles set of the specified map.
getTilesetInfos
in interface Tileable
mapName
-protected MapProvider getProvider(java.lang.String name)
Gets the map service provider of the specified map.
name
- Map name, can not be null.protected MapProvider getQueryProvider(java.lang.String name)
Gets the map service provider required by the query function.
name
- The map name.public byte[] getMVTTile(VectorTileParameter vectorTileParameter) throws MapException
Map
Gets MVT tile of the map.
getMVTTile
in interface Map
vectorTileParameter
- The parameters of the vector tile.MapException
public VectorTileData getVectorTile(VectorTileParameter vectorTileParameter) throws MapException
Map
Gets vector tile of the map.
getVectorTile
in interface Map
vectorTileParameter
- The parameters of the vector tile.MapException
public boolean support(java.lang.String mapName, MapCapability capability)
Map
public QueryResult queryByKeywords(java.lang.String mapName, KeywordsQueryParameterSet queryParameterSet) throws MapException
Map
queryByKeywords
in interface Map
mapName
- The map name.queryParameterSet
- Query parameter set.MapException
public VectorStyle getVectorStyle(java.lang.String mapName, java.lang.String[] layerNames, VectorStyleType type) throws MapException
Map
getVectorStyle
in interface Map
mapName
- The map name.layerNames
- The layer name.type
- The vector style type.MapException
public void updateVectorStyle(java.lang.String mapName, java.lang.String layerName, VectorStyleType type, java.lang.String style)
Map
updateVectorStyle
in interface Map
mapName
- The map name.type
- The vector style type.public java.lang.String[] listMVTSprites(java.lang.String mapName)
Map
listMVTSprites
in interface Map
mapName
- The map name.public java.lang.String getMVTSpriteJson(java.lang.String mapName, java.lang.String spriteName)
Map
getMVTSpriteJson
in interface Map
mapName
- The map name.spriteName
- Sprite name.public byte[] getMVTSpriteResource(java.lang.String mapName, java.lang.String spriteName)
Map
getMVTSpriteResource
in interface Map
mapName
- The map name.spriteName
- Sprite name.public byte[] getMVTFonts(java.lang.String mapName, java.lang.String fontstack, java.lang.String range)
Map
getMVTFonts
in interface Map
mapName
- The map name.fontstack
- The fontstack name.range
- rang.public boolean updateMap(MapParameter mapParameter) throws MapException
Map
updateMap
in interface Map
mapParameter
- The map status to update to.MapException