com.esri.arcgis.geoprocessing.tools.servertools
Class CreateMapServerCache

java.lang.Object
  extended by com.esri.arcgis.geoprocessing.AbstractGPTool
      extended by com.esri.arcgis.geoprocessing.tools.servertools.CreateMapServerCache
All Implemented Interfaces:
GPTool

public class CreateMapServerCache
extends AbstractGPTool

Creates the tiling scheme and preparatory folders for a map service cache. After running this tool, run Manage Map Server Cache Tiles to add tiles to the cache. The Create Map Server Cache tool is contained in the Server Tools tool box.

Usage tips:


Field Summary
 
Fields inherited from class com.esri.arcgis.geoprocessing.AbstractGPTool
vals
 
Constructor Summary
CreateMapServerCache()
          Creates the Create Map Server Cache tool with defaults.
CreateMapServerCache(String serverName, String objectName, String dataFrame, String outFolder, String tilingSchemeType, String scalesType, int numOfScales, int dpi, int tileWidth, int tileHeight)
          Creates the Create Map Server Cache tool with the required parameters.
 
Method Summary
 String getAntialiasing()
          Returns the Antialiasing (Smoothes edges of labels and lines for improved display quality) parameter of this tool .
 String getCacheFormat()
          Returns the Cache Tile Format parameter of this tool .
 String getDataFrame()
          Returns the Data Frame parameter of this tool .
 int getDpi()
          Returns the Dots(Pixels) Per Inch parameter of this tool .
 Object getLayer()
          Returns the Input Layers parameter of this tool .
 Object getLevels()
          Returns the Scales parameter of this tool .
 String getMapOrLayers()
          Returns the Cache Type parameter of this tool .
 int getNumOfScales()
          Returns the Number of Scales parameter of this tool .
 String getObjectName()
          Returns the Map Server parameter of this tool .
 String getOutFolder()
          Returns the Server Cache Directory parameter of this tool .
 String getOutObjectName()
          Returns the Output Map Server parameter of this tool (Read only).
 String getOutServerName()
          Returns the Output Host parameter of this tool (Read only).
 String getScalesType()
          Returns the Scales parameter of this tool .
 String getServerName()
          Returns the Host parameter of this tool .
 String getStorageFormat()
          Returns the Storage Format parameter of this tool .
 int getTileCompressionQuality()
          Returns the Tile Compression Quality parameter of this tool .
 int getTileHeight()
          Returns the Tile Height (in pixels) parameter of this tool .
 Object getTileOrigin()
          Returns the Tiling origin in map units parameter of this tool .
 int getTileWidth()
          Returns the Tile Width (in pixels) parameter of this tool .
 Object getTilingSchema()
          Returns the Predefined Tiling Scheme parameter of this tool .
 String getTilingSchemeType()
          Returns the Tiling Scheme parameter of this tool .
 String getToolboxAlias()
          Returns the alias of the tool box containing this tool.
 String getToolboxName()
          Returns the name of the tool box containing this tool.
 String getToolName()
          Returns the name of this tool.
 void setAntialiasing(String antialiasing)
          Sets the Antialiasing (Smoothes edges of labels and lines for improved display quality) parameter of this tool .
 void setCacheFormat(String cacheFormat)
          Sets the Cache Tile Format parameter of this tool .
 void setDataFrame(String dataFrame)
          Sets the Data Frame parameter of this tool .
 void setDpi(int dpi)
          Sets the Dots(Pixels) Per Inch parameter of this tool .
 void setLayer(Object layer)
          Sets the Input Layers parameter of this tool .
 void setLevels(Object levels)
          Sets the Scales parameter of this tool .
 void setMapOrLayers(String mapOrLayers)
          Sets the Cache Type parameter of this tool .
 void setNumOfScales(int numOfScales)
          Sets the Number of Scales parameter of this tool .
 void setObjectName(String objectName)
          Sets the Map Server parameter of this tool .
 void setOutFolder(String outFolder)
          Sets the Server Cache Directory parameter of this tool .
 void setScalesType(String scalesType)
          Sets the Scales parameter of this tool .
 void setServerName(String serverName)
          Sets the Host parameter of this tool .
 void setStorageFormat(String storageFormat)
          Sets the Storage Format parameter of this tool .
 void setTileCompressionQuality(int tileCompressionQuality)
          Sets the Tile Compression Quality parameter of this tool .
 void setTileHeight(int tileHeight)
          Sets the Tile Height (in pixels) parameter of this tool .
 void setTileOrigin(Object tileOrigin)
          Sets the Tiling origin in map units parameter of this tool .
 void setTileWidth(int tileWidth)
          Sets the Tile Width (in pixels) parameter of this tool .
 void setTilingSchema(Object tilingSchema)
          Sets the Predefined Tiling Scheme parameter of this tool .
 void setTilingSchemeType(String tilingSchemeType)
          Sets the Tiling Scheme parameter of this tool .
 
Methods inherited from class com.esri.arcgis.geoprocessing.AbstractGPTool
getParameterValues, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CreateMapServerCache

public CreateMapServerCache()
Creates the Create Map Server Cache tool with defaults.

Initializes the array of tool parameters with the default values specified when the tool was created.


CreateMapServerCache

public CreateMapServerCache(String serverName,
                            String objectName,
                            String dataFrame,
                            String outFolder,
                            String tilingSchemeType,
                            String scalesType,
                            int numOfScales,
                            int dpi,
                            int tileWidth,
                            int tileHeight)
Creates the Create Map Server Cache tool with the required parameters.

Initializes the array of tool parameters with the values as specified for the required parameters and with the default values for the other parameters.

Parameters:
serverName - the ArcGIS Server machine hosting the service to be cached.
objectName - the map service to be cached.
dataFrame - the map data frame to be cached.
outFolder - the parent directory for the cache. This must be a registered ArcGIS Server cache directory.
tilingSchemeType - choose to use a NEW or PREDEFINED tiling scheme. You can define a new tiling scheme with this tool, or browse to a predefined tiling scheme file (.xml). A predefined scheme can be created by running the Generate Map Server Cache Tiling Scheme tool. nEW is the default.
scalesType - specify how you will define the scales for the tiles.
numOfScales - the number of scale levels to create in the cache. This option is disabled if you create a custom list of scales.
dpi - the dots per inch of the intended output device. If a DPI is chosen that does not match the resolution of the output device, the scale of the map tile will appear incorrect. The default value is 96.
tileWidth - the width of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512.
tileHeight - the height of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512.
Method Detail

getServerName

public String getServerName()
Returns the Host parameter of this tool . This parameter is the ArcGIS Server machine hosting the service to be cached. This is a required parameter.

Returns:
the Host

setServerName

public void setServerName(String serverName)
Sets the Host parameter of this tool . This parameter is the ArcGIS Server machine hosting the service to be cached. This is a required parameter.

Parameters:
serverName - the ArcGIS Server machine hosting the service to be cached.

getObjectName

public String getObjectName()
Returns the Map Server parameter of this tool . This parameter is the map service to be cached. This is a required parameter.

Returns:
the Map Server

setObjectName

public void setObjectName(String objectName)
Sets the Map Server parameter of this tool . This parameter is the map service to be cached. This is a required parameter.

Parameters:
objectName - the map service to be cached.

getDataFrame

public String getDataFrame()
Returns the Data Frame parameter of this tool . This parameter is the map data frame to be cached. This is a required parameter.

Returns:
the Data Frame

setDataFrame

public void setDataFrame(String dataFrame)
Sets the Data Frame parameter of this tool . This parameter is the map data frame to be cached. This is a required parameter.

Parameters:
dataFrame - the map data frame to be cached.

getOutFolder

public String getOutFolder()
Returns the Server Cache Directory parameter of this tool . This parameter is the parent directory for the cache. This must be a registered ArcGIS Server cache directory. This is a required parameter.

Returns:
the Server Cache Directory

setOutFolder

public void setOutFolder(String outFolder)
Sets the Server Cache Directory parameter of this tool . This parameter is the parent directory for the cache. This must be a registered ArcGIS Server cache directory. This is a required parameter.

Parameters:
outFolder - the parent directory for the cache. This must be a registered ArcGIS Server cache directory.

getTilingSchemeType

public String getTilingSchemeType()
Returns the Tiling Scheme parameter of this tool . This parameter is choose to use a NEW or PREDEFINED tiling scheme. You can define a new tiling scheme with this tool, or browse to a predefined tiling scheme file (.xml). A predefined scheme can be created by running the Generate Map Server Cache Tiling Scheme tool. nEW is the default. This is a required parameter.

Returns:
the Tiling Scheme

setTilingSchemeType

public void setTilingSchemeType(String tilingSchemeType)
Sets the Tiling Scheme parameter of this tool . This parameter is choose to use a NEW or PREDEFINED tiling scheme. You can define a new tiling scheme with this tool, or browse to a predefined tiling scheme file (.xml). A predefined scheme can be created by running the Generate Map Server Cache Tiling Scheme tool. nEW is the default. This is a required parameter.

Parameters:
tilingSchemeType - choose to use a NEW or PREDEFINED tiling scheme. You can define a new tiling scheme with this tool, or browse to a predefined tiling scheme file (.xml). A predefined scheme can be created by running the Generate Map Server Cache Tiling Scheme tool. nEW is the default.

getScalesType

public String getScalesType()
Returns the Scales parameter of this tool . This parameter is specify how you will define the scales for the tiles. This is a required parameter.

Returns:
the Scales

setScalesType

public void setScalesType(String scalesType)
Sets the Scales parameter of this tool . This parameter is specify how you will define the scales for the tiles. This is a required parameter.

Parameters:
scalesType - specify how you will define the scales for the tiles.

getNumOfScales

public int getNumOfScales()
Returns the Number of Scales parameter of this tool . This parameter is the number of scale levels to create in the cache. This option is disabled if you create a custom list of scales. This is a required parameter.

Returns:
the Number of Scales

setNumOfScales

public void setNumOfScales(int numOfScales)
Sets the Number of Scales parameter of this tool . This parameter is the number of scale levels to create in the cache. This option is disabled if you create a custom list of scales. This is a required parameter.

Parameters:
numOfScales - the number of scale levels to create in the cache. This option is disabled if you create a custom list of scales.

getDpi

public int getDpi()
Returns the Dots(Pixels) Per Inch parameter of this tool . This parameter is the dots per inch of the intended output device. If a DPI is chosen that does not match the resolution of the output device, the scale of the map tile will appear incorrect. The default value is 96. This is a required parameter.

Returns:
the Dots(Pixels) Per Inch

setDpi

public void setDpi(int dpi)
Sets the Dots(Pixels) Per Inch parameter of this tool . This parameter is the dots per inch of the intended output device. If a DPI is chosen that does not match the resolution of the output device, the scale of the map tile will appear incorrect. The default value is 96. This is a required parameter.

Parameters:
dpi - the dots per inch of the intended output device. If a DPI is chosen that does not match the resolution of the output device, the scale of the map tile will appear incorrect. The default value is 96.

getTileWidth

public int getTileWidth()
Returns the Tile Width (in pixels) parameter of this tool . This parameter is the width of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512. This is a required parameter.

Returns:
the Tile Width (in pixels)

setTileWidth

public void setTileWidth(int tileWidth)
Sets the Tile Width (in pixels) parameter of this tool . This parameter is the width of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512. This is a required parameter.

Parameters:
tileWidth - the width of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512.

getTileHeight

public int getTileHeight()
Returns the Tile Height (in pixels) parameter of this tool . This parameter is the height of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512. This is a required parameter.

Returns:
the Tile Height (in pixels)

setTileHeight

public void setTileHeight(int tileHeight)
Sets the Tile Height (in pixels) parameter of this tool . This parameter is the height of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512. This is a required parameter.

Parameters:
tileHeight - the height of the cache tiles in pixels. The default is 256. For the best balance between performance and manageability, avoid deviating from standard widths of 256 or 512.

getMapOrLayers

public String getMapOrLayers()
Returns the Cache Type parameter of this tool . This parameter is choose to generate a FUSED or MULTI_LAYER cache: This is an optional parameter.

Returns:
the Cache Type

setMapOrLayers

public void setMapOrLayers(String mapOrLayers)
Sets the Cache Type parameter of this tool . This parameter is choose to generate a FUSED or MULTI_LAYER cache: This is an optional parameter.

Parameters:
mapOrLayers - choose to generate a FUSED or MULTI_LAYER cache:

getTilingSchema

public Object getTilingSchema()
Returns the Predefined Tiling Scheme parameter of this tool . This parameter is path to a pre-defined tiling scheme file (usually named conf.xml). This is an optional parameter.

Returns:
the Predefined Tiling Scheme

setTilingSchema

public void setTilingSchema(Object tilingSchema)
Sets the Predefined Tiling Scheme parameter of this tool . This parameter is path to a pre-defined tiling scheme file (usually named conf.xml). This is an optional parameter.

Parameters:
tilingSchema - path to a pre-defined tiling scheme file (usually named conf.xml).

getTileOrigin

public Object getTileOrigin()
Returns the Tiling origin in map units parameter of this tool . This parameter is the origin (upper left corner) of the tiling scheme in the coordinates of the spatial reference of the source map document. The extent of the source map document must be within (but does not need to coincide) with this region. This is an optional parameter.

Returns:
the Tiling origin in map units

setTileOrigin

public void setTileOrigin(Object tileOrigin)
Sets the Tiling origin in map units parameter of this tool . This parameter is the origin (upper left corner) of the tiling scheme in the coordinates of the spatial reference of the source map document. The extent of the source map document must be within (but does not need to coincide) with this region. This is an optional parameter.

Parameters:
tileOrigin - the origin (upper left corner) of the tiling scheme in the coordinates of the spatial reference of the source map document. The extent of the source map document must be within (but does not need to coincide) with this region.

getLevels

public Object getLevels()
Returns the Scales parameter of this tool . This parameter is scale levels available for the cache. These are not represented as fractions. Instead, use 500 to represent a scale of 1:500, and so on. This is an optional parameter.

Returns:
the Scales

setLevels

public void setLevels(Object levels)
Sets the Scales parameter of this tool . This parameter is scale levels available for the cache. These are not represented as fractions. Instead, use 500 to represent a scale of 1:500, and so on. This is an optional parameter.

Parameters:
levels - scale levels available for the cache. These are not represented as fractions. Instead, use 500 to represent a scale of 1:500, and so on.

getLayer

public Object getLayer()
Returns the Input Layers parameter of this tool . This parameter is layers to include in the cache if MULTI_LAYER cache type is chosen. This is an optional parameter.

Returns:
the Input Layers

setLayer

public void setLayer(Object layer)
Sets the Input Layers parameter of this tool . This parameter is layers to include in the cache if MULTI_LAYER cache type is chosen. This is an optional parameter.

Parameters:
layer - layers to include in the cache if MULTI_LAYER cache type is chosen.

getAntialiasing

public String getAntialiasing()
Returns the Antialiasing (Smoothes edges of labels and lines for improved display quality) parameter of this tool . This parameter is specifies whether to use antialiasing when rendering the tiles. If antialiasing is chosen, edges of lines, borders, and text will be smoothed. There is a performance cost for this option. The performance cost is greater when using MXD-based map services (as opposed to MSD-based map services that have antialiasing defined in the MSD file). Antialiasing provides no benefit with raster imagery. if the source for your map service is an MSD file and you defined antialiasing within the MSD, antialiasing will be applied in your cache whether or not you choose the option in this tool. This is an optional parameter.

Returns:
the Antialiasing (Smoothes edges of labels and lines for improved display quality)

setAntialiasing

public void setAntialiasing(String antialiasing)
Sets the Antialiasing (Smoothes edges of labels and lines for improved display quality) parameter of this tool . This parameter is specifies whether to use antialiasing when rendering the tiles. If antialiasing is chosen, edges of lines, borders, and text will be smoothed. There is a performance cost for this option. The performance cost is greater when using MXD-based map services (as opposed to MSD-based map services that have antialiasing defined in the MSD file). Antialiasing provides no benefit with raster imagery. if the source for your map service is an MSD file and you defined antialiasing within the MSD, antialiasing will be applied in your cache whether or not you choose the option in this tool. This is an optional parameter.

Parameters:
antialiasing - specifies whether to use antialiasing when rendering the tiles. If antialiasing is chosen, edges of lines, borders, and text will be smoothed. There is a performance cost for this option. The performance cost is greater when using MXD-based map services (as opposed to MSD-based map services that have antialiasing defined in the MSD file). Antialiasing provides no benefit with raster imagery. if the source for your map service is an MSD file and you defined antialiasing within the MSD, antialiasing will be applied in your cache whether or not you choose the option in this tool.

getCacheFormat

public String getCacheFormat()
Returns the Cache Tile Format parameter of this tool . This parameter is choose either PNG8, PNG24, PNG32, JPEG or MIXED file format for the tiles in the cache. PNG8 is the default. This is an optional parameter.

Returns:
the Cache Tile Format

setCacheFormat

public void setCacheFormat(String cacheFormat)
Sets the Cache Tile Format parameter of this tool . This parameter is choose either PNG8, PNG24, PNG32, JPEG or MIXED file format for the tiles in the cache. PNG8 is the default. This is an optional parameter.

Parameters:
cacheFormat - choose either PNG8, PNG24, PNG32, JPEG or MIXED file format for the tiles in the cache. PNG8 is the default.

getTileCompressionQuality

public int getTileCompressionQuality()
Returns the Tile Compression Quality parameter of this tool . This parameter is enter a value between 1 and 100 for the JPEG compression quality. The default value is 75 for JPEG tile format and zero for other formats. compression is supported only for JPEG format. Choosing a higher value will result in a larger file size with a higher-quality image. Choosing a lower value will result in a smaller file size with a lower-quality image. This is an optional parameter.

Returns:
the Tile Compression Quality

setTileCompressionQuality

public void setTileCompressionQuality(int tileCompressionQuality)
Sets the Tile Compression Quality parameter of this tool . This parameter is enter a value between 1 and 100 for the JPEG compression quality. The default value is 75 for JPEG tile format and zero for other formats. compression is supported only for JPEG format. Choosing a higher value will result in a larger file size with a higher-quality image. Choosing a lower value will result in a smaller file size with a lower-quality image. This is an optional parameter.

Parameters:
tileCompressionQuality - enter a value between 1 and 100 for the JPEG compression quality. The default value is 75 for JPEG tile format and zero for other formats. compression is supported only for JPEG format. Choosing a higher value will result in a larger file size with a higher-quality image. Choosing a lower value will result in a smaller file size with a lower-quality image.

getStorageFormat

public String getStorageFormat()
Returns the Storage Format parameter of this tool . This parameter is choose to group your tiles into large "bundle" files using "Compact" storage format, instead of storing each tile as a separate file using "Exploded" format. Compact storage format is more efficient in terms of storage and mobility. This is an optional parameter.

Returns:
the Storage Format

setStorageFormat

public void setStorageFormat(String storageFormat)
Sets the Storage Format parameter of this tool . This parameter is choose to group your tiles into large "bundle" files using "Compact" storage format, instead of storing each tile as a separate file using "Exploded" format. Compact storage format is more efficient in terms of storage and mobility. This is an optional parameter.

Parameters:
storageFormat - choose to group your tiles into large "bundle" files using "Compact" storage format, instead of storing each tile as a separate file using "Exploded" format. Compact storage format is more efficient in terms of storage and mobility.

getOutServerName

public String getOutServerName()
Returns the Output Host parameter of this tool (Read only). This is an derived parameter.

Returns:
the Output Host

getOutObjectName

public String getOutObjectName()
Returns the Output Map Server parameter of this tool (Read only). This is an derived parameter.

Returns:
the Output Map Server

getToolName

public String getToolName()
Returns the name of this tool.

Returns:
the tool name

getToolboxName

public String getToolboxName()
Returns the name of the tool box containing this tool.

Returns:
the tool box name

getToolboxAlias

public String getToolboxAlias()
Returns the alias of the tool box containing this tool.

Returns:
the tool box alias