com.esri.arcgis.geoprocessing.tools.cartographytools
Class IntersectingLayersMasks
java.lang.Object
com.esri.arcgis.geoprocessing.AbstractGPTool
com.esri.arcgis.geoprocessing.tools.cartographytools.IntersectingLayersMasks
- All Implemented Interfaces:
- GPTool
public class IntersectingLayersMasks
- extends AbstractGPTool
Creates masking polygons at a specified shape and size at the intersections of symbolized input layers.
The Intersecting Layers Masks tool is contained in the Cartography Tools tool box.
Usage tips:
- This tool accepts point, line, and polygon feature layers as well as geodatabase annotation layers as input.
- Masks will be created if the margin distance is 0 or negative. A margin size of 0 will create a polygon that represents the exact shape of the symbolized feature. A negative margin will result in a polygon smaller than the symbolized feature. Generally, a margin value larger than 0 will be specified to produce the desired masking effect.
- When creating masks, it is important to know that adding masks to maps adds complexity that will slow map drawing and affect map printing and exporting. Generally, there are three things to consider when creating masks for a map: (1) the number of masks, (2) the complexity of the masks, and (3) whether the masks will be used to mask polygon features filled with marker or line symbols. An increase in the number of masks, having more complex masks, and/or masking against marker or polygon fill symbols will result in slower drawing on your screen. Additionally, printing and exporting performance can be poor and even fail to produce valid output, first, because of the large amount of processing required to print and export maps with masks, and second, because of known limitations in how graphic file formats store map export results that have many complicated masks.
- When seeking to improve drawing performance as well as printing and exporting performance and reliability, the most important guideline to follow is to use the simplest masks necessary for the purposes of your map. In particular, when masking annotation text, you will find that CONVEX_HULL type masks are sufficient for many map purposes. If you need more detailed text masks, then use the EXACT_SIMPLIFIED type. Generally, when masking much text on a relatively large map, avoid using the EXACT type mask because it will create too many complicated masks to produce valid output efficiently.
- Margin values are specified in either page units or map units. Most of the time you will want to specify your margin distance value in page units.Margin value units are interpreted differently depending on which units you choose. If you choose points, inches, millimeters, or centimeters, then masks are created using the margin distance as calculated in page space (you can think of the margin as a distance measured on the paper). The reference scale parameter value is accounted for in this calculation.If you choose any other units for your margin, then masks are created using the margin distance as calculated in map space (you can think of the margin as a real-world distance measure on the earth). Also, in this case, the reference scale parameter value is not used as part of the calculation.
- If one of the input layers is an annotation layer, the reference scale will be automatically set to the reference scale of the layer's feature class to ensure accurate calculation of the mask. If two annotation layers are being intersected, they must have the same reference scale.
- When masking annotation projected on the fly, masks should be created using the map's spatial reference by properly setting it in the spatial reference parameter. Readability is preserved when text is projected on the fly, which is why there may be differences in the spatial area text occupies in different projections.
- Masks of annotation features are font specific. When using masks with text, it is important to ensure that the same font is used onscreen as in the output. To do this, choose to embed fonts in vector output or download SoftFonts to printers or plotters.
Constructor Summary |
IntersectingLayersMasks()
Creates the Intersecting Layers Masks tool with defaults. |
IntersectingLayersMasks(java.lang.Object maskingLayer,
java.lang.Object maskedLayer,
java.lang.Object outputFc,
double referenceScale,
java.lang.Object spatialReference,
java.lang.Object margin,
java.lang.String method,
java.lang.String maskForNonPlacedAnno)
Creates the Intersecting Layers Masks tool with the required parameters. |
Method Summary |
java.lang.String |
getAttributes()
Returns the Transfer Attributes parameter of this tool . |
java.lang.Object |
getMargin()
Returns the Margin parameter of this tool . |
java.lang.Object |
getMaskedLayer()
Returns the Masked Layer parameter of this tool . |
java.lang.String |
getMaskForNonPlacedAnno()
Returns the Create masks for unplaced annotation. |
java.lang.Object |
getMaskingLayer()
Returns the Masking Layer parameter of this tool . |
java.lang.String |
getMethod()
Returns the Mask Kind parameter of this tool . |
java.lang.Object |
getOutputFc()
Returns the Output Feature Class parameter of this tool . |
double |
getReferenceScale()
Returns the Reference Scale parameter of this tool . |
java.lang.Object |
getSpatialReference()
Returns the Calculation coordinate system parameter of this tool . |
java.lang.String |
getToolboxAlias()
Returns the alias of the tool box containing this tool. |
java.lang.String |
getToolboxName()
Returns the name of the tool box containing this tool. |
java.lang.String |
getToolName()
Returns the name of this tool. |
void |
setAttributes(java.lang.String attributes)
Sets the Transfer Attributes parameter of this tool . |
void |
setMargin(java.lang.Object margin)
Sets the Margin parameter of this tool . |
void |
setMaskedLayer(java.lang.Object maskedLayer)
Sets the Masked Layer parameter of this tool . |
void |
setMaskForNonPlacedAnno(java.lang.String maskForNonPlacedAnno)
Sets the Create masks for unplaced annotation. |
void |
setMaskingLayer(java.lang.Object maskingLayer)
Sets the Masking Layer parameter of this tool . |
void |
setMethod(java.lang.String method)
Sets the Mask Kind parameter of this tool . |
void |
setOutputFc(java.lang.Object outputFc)
Sets the Output Feature Class parameter of this tool . |
void |
setReferenceScale(double referenceScale)
Sets the Reference Scale parameter of this tool . |
void |
setSpatialReference(java.lang.Object spatialReference)
Sets the Calculation coordinate system parameter of this tool . |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
IntersectingLayersMasks
public IntersectingLayersMasks()
- Creates the Intersecting Layers Masks tool with defaults.
Initializes the array of tool parameters with the default values specified when the tool was created.
IntersectingLayersMasks
public IntersectingLayersMasks(java.lang.Object maskingLayer,
java.lang.Object maskedLayer,
java.lang.Object outputFc,
double referenceScale,
java.lang.Object spatialReference,
java.lang.Object margin,
java.lang.String method,
java.lang.String maskForNonPlacedAnno)
- Creates the Intersecting Layers Masks 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:
maskingLayer
- the symbolized input layer, which will be intersected with the masked layer to create masking polygons. This is the layer that will be more prominently displayed when masking is applied to the masked layer.maskedLayer
- the symbolized input layer to be masked. This is the layer that will be obscured by the masking polygons.outputFc
- the feature class that will contain the mask features.referenceScale
- the reference scale used for calculating the masking geometry when masks are specified in page units. This is typically the reference scale of the map.spatialReference
- the spatial reference for which the masking polygons will be created. This is not the spatial reference that will be assigned to the output feature class. It is the spatial reference of the map in which the masking polygons will be used since the position of symbology may change when features are projected.margin
- the space in page units surrounding the symbolized input features used to create the mask polygon. Typically, masking polygons are created with a small margin around the symbol to improve visual appearance. Margin values are specified in either page units or map units. Most of the time you will want to specify your margin distance value in page units. margin value units are interpreted differently depending on which units you choose. If you choose points, inches, millimeters, or centimeters, then masks are created using the margin distance as calculated in page space (you can think of the margin as a distance measured on the paper). The reference scale parameter value is accounted for in this calculation. if you choose any other units for your margin, then masks are created using the margin distance as calculated in map space (you can think of the margin as a real-world distance measure on the earth). Also, in this case, the reference scale parameter value is not used as part of the calculation.method
- the type of masking geometry created. There are four types:maskForNonPlacedAnno
- specifies whether to create masks for unplaced annotation. This option is only used when masking geodatabase annotation layers.
getMaskingLayer
public java.lang.Object getMaskingLayer()
- Returns the Masking Layer parameter of this tool .
This parameter is the symbolized input layer, which will be intersected with the masked layer to create masking polygons. This is the layer that will be more prominently displayed when masking is applied to the masked layer.
This is a required parameter.
- Returns:
- the Masking Layer
setMaskingLayer
public void setMaskingLayer(java.lang.Object maskingLayer)
- Sets the Masking Layer parameter of this tool .
This parameter is the symbolized input layer, which will be intersected with the masked layer to create masking polygons. This is the layer that will be more prominently displayed when masking is applied to the masked layer.
This is a required parameter.
- Parameters:
maskingLayer
- the symbolized input layer, which will be intersected with the masked layer to create masking polygons. This is the layer that will be more prominently displayed when masking is applied to the masked layer.
getMaskedLayer
public java.lang.Object getMaskedLayer()
- Returns the Masked Layer parameter of this tool .
This parameter is the symbolized input layer to be masked. This is the layer that will be obscured by the masking polygons.
This is a required parameter.
- Returns:
- the Masked Layer
setMaskedLayer
public void setMaskedLayer(java.lang.Object maskedLayer)
- Sets the Masked Layer parameter of this tool .
This parameter is the symbolized input layer to be masked. This is the layer that will be obscured by the masking polygons.
This is a required parameter.
- Parameters:
maskedLayer
- the symbolized input layer to be masked. This is the layer that will be obscured by the masking polygons.
getOutputFc
public java.lang.Object getOutputFc()
- Returns the Output Feature Class parameter of this tool .
This parameter is the feature class that will contain the mask features.
This is a required parameter.
- Returns:
- the Output Feature Class
setOutputFc
public void setOutputFc(java.lang.Object outputFc)
- Sets the Output Feature Class parameter of this tool .
This parameter is the feature class that will contain the mask features.
This is a required parameter.
- Parameters:
outputFc
- the feature class that will contain the mask features.
getReferenceScale
public double getReferenceScale()
- Returns the Reference Scale parameter of this tool .
This parameter is the reference scale used for calculating the masking geometry when masks are specified in page units. This is typically the reference scale of the map.
This is a required parameter.
- Returns:
- the Reference Scale
setReferenceScale
public void setReferenceScale(double referenceScale)
- Sets the Reference Scale parameter of this tool .
This parameter is the reference scale used for calculating the masking geometry when masks are specified in page units. This is typically the reference scale of the map.
This is a required parameter.
- Parameters:
referenceScale
- the reference scale used for calculating the masking geometry when masks are specified in page units. This is typically the reference scale of the map.
getSpatialReference
public java.lang.Object getSpatialReference()
- Returns the Calculation coordinate system parameter of this tool .
This parameter is the spatial reference for which the masking polygons will be created. This is not the spatial reference that will be assigned to the output feature class. It is the spatial reference of the map in which the masking polygons will be used since the position of symbology may change when features are projected.
This is a required parameter.
- Returns:
- the Calculation coordinate system
setSpatialReference
public void setSpatialReference(java.lang.Object spatialReference)
- Sets the Calculation coordinate system parameter of this tool .
This parameter is the spatial reference for which the masking polygons will be created. This is not the spatial reference that will be assigned to the output feature class. It is the spatial reference of the map in which the masking polygons will be used since the position of symbology may change when features are projected.
This is a required parameter.
- Parameters:
spatialReference
- the spatial reference for which the masking polygons will be created. This is not the spatial reference that will be assigned to the output feature class. It is the spatial reference of the map in which the masking polygons will be used since the position of symbology may change when features are projected.
getMargin
public java.lang.Object getMargin()
- Returns the Margin parameter of this tool .
This parameter is the space in page units surrounding the symbolized input features used to create the mask polygon. Typically, masking polygons are created with a small margin around the symbol to improve visual appearance. Margin values are specified in either page units or map units. Most of the time you will want to specify your margin distance value in page units. margin value units are interpreted differently depending on which units you choose. If you choose points, inches, millimeters, or centimeters, then masks are created using the margin distance as calculated in page space (you can think of the margin as a distance measured on the paper). The reference scale parameter value is accounted for in this calculation. if you choose any other units for your margin, then masks are created using the margin distance as calculated in map space (you can think of the margin as a real-world distance measure on the earth). Also, in this case, the reference scale parameter value is not used as part of the calculation.
This is a required parameter.
- Returns:
- the Margin
setMargin
public void setMargin(java.lang.Object margin)
- Sets the Margin parameter of this tool .
This parameter is the space in page units surrounding the symbolized input features used to create the mask polygon. Typically, masking polygons are created with a small margin around the symbol to improve visual appearance. Margin values are specified in either page units or map units. Most of the time you will want to specify your margin distance value in page units. margin value units are interpreted differently depending on which units you choose. If you choose points, inches, millimeters, or centimeters, then masks are created using the margin distance as calculated in page space (you can think of the margin as a distance measured on the paper). The reference scale parameter value is accounted for in this calculation. if you choose any other units for your margin, then masks are created using the margin distance as calculated in map space (you can think of the margin as a real-world distance measure on the earth). Also, in this case, the reference scale parameter value is not used as part of the calculation.
This is a required parameter.
- Parameters:
margin
- the space in page units surrounding the symbolized input features used to create the mask polygon. Typically, masking polygons are created with a small margin around the symbol to improve visual appearance. Margin values are specified in either page units or map units. Most of the time you will want to specify your margin distance value in page units. margin value units are interpreted differently depending on which units you choose. If you choose points, inches, millimeters, or centimeters, then masks are created using the margin distance as calculated in page space (you can think of the margin as a distance measured on the paper). The reference scale parameter value is accounted for in this calculation. if you choose any other units for your margin, then masks are created using the margin distance as calculated in map space (you can think of the margin as a real-world distance measure on the earth). Also, in this case, the reference scale parameter value is not used as part of the calculation.
getMethod
public java.lang.String getMethod()
- Returns the Mask Kind parameter of this tool .
This parameter is the type of masking geometry created. There are four types:
This is a required parameter.
- Returns:
- the Mask Kind
setMethod
public void setMethod(java.lang.String method)
- Sets the Mask Kind parameter of this tool .
This parameter is the type of masking geometry created. There are four types:
This is a required parameter.
- Parameters:
method
- the type of masking geometry created. There are four types:
getMaskForNonPlacedAnno
public java.lang.String getMaskForNonPlacedAnno()
- Returns the Create masks for unplaced annotation. parameter of this tool .
This parameter is specifies whether to create masks for unplaced annotation. This option is only used when masking geodatabase annotation layers.
This is a required parameter.
- Returns:
- the Create masks for unplaced annotation.
setMaskForNonPlacedAnno
public void setMaskForNonPlacedAnno(java.lang.String maskForNonPlacedAnno)
- Sets the Create masks for unplaced annotation. parameter of this tool .
This parameter is specifies whether to create masks for unplaced annotation. This option is only used when masking geodatabase annotation layers.
This is a required parameter.
- Parameters:
maskForNonPlacedAnno
- specifies whether to create masks for unplaced annotation. This option is only used when masking geodatabase annotation layers.
getAttributes
public java.lang.String getAttributes()
- Returns the Transfer Attributes parameter of this tool .
This parameter is determines which attributes will be transferred from the input features to the output features.
This is an optional parameter.
- Returns:
- the Transfer Attributes
setAttributes
public void setAttributes(java.lang.String attributes)
- Sets the Transfer Attributes parameter of this tool .
This parameter is determines which attributes will be transferred from the input features to the output features.
This is an optional parameter.
- Parameters:
attributes
- determines which attributes will be transferred from the input features to the output features.
getToolName
public java.lang.String getToolName()
- Returns the name of this tool.
- Returns:
- the tool name
getToolboxName
public java.lang.String getToolboxName()
- Returns the name of the tool box containing this tool.
- Returns:
- the tool box name
getToolboxAlias
public java.lang.String getToolboxAlias()
- Returns the alias of the tool box containing this tool.
- Returns:
- the tool box alias