## com.esri.arcgis.geoprocessing.tools.analyst3dtools Class CutFill

```java.lang.Object com.esri.arcgis.geoprocessing.AbstractGPTool com.esri.arcgis.geoprocessing.tools.analyst3dtools.CutFill
```
All Implemented Interfaces:
GPTool

`public class CutFillextends AbstractGPTool`

Calculates the volume change between two surfaces. This is typically used for cut and fill operations. The Cut Fill tool is contained in the 3D Analyst Tools tool box.

#### Usage tips:

• The Cut Fill tool enables you to create a map based on two input surfaces�before and after�displaying the areas and volumes of surface materials that have been modified by the removal or addition of surface material.
• Both the input raster surfaces must be coincident. That is, they must have a common origin, the same number of rows and columns of cells, and the same cell size.
• For accurate results, the z-units should be the same as the x,y ground units. This ensures that the resulting volumes are meaningful cubic measures (i.e., cubic meters). If they are not the same, use a z-factor to convert z units to x,y units. For example, if your x,y units are meters and your z units are feet, you could specify a z-factor of 0.3048 to convert feet to meters.Alternatively, use the math tool to create a surface raster in which the z-values have been adjusted to correspond to the ground units.
• The attribute table of the output raster presents the changes in the surface volumes following the cut/fill operation. Positive values for the volume difference indicate regions of the before raster surface that have been cut (material removed). Negative values indicate areas that have been filled (material added). See for more details on how the results are calculated.
• When the cut/fill operation is performed from the tool, by default a specialized renderer is applied that highlights the locations of cut and of fill. The renderer draws areas that have been cut in blue, and areas that have been filled in red. Areas that have not changed are displayed in grey.

Field Summary

Fields inherited from class com.esri.arcgis.geoprocessing.AbstractGPTool
`vals`

Constructor Summary
`CutFill()`
Creates the Cut Fill tool with defaults.
```CutFill(Object inBeforeSurface, Object inAfterSurface, Object outRaster)```
Creates the Cut Fill tool with the required parameters.

Method Summary
` Object` `getInAfterSurface()`
Returns the Input after raster surface parameter of this tool .
` Object` `getInBeforeSurface()`
Returns the Input before raster surface parameter of this tool .
` Object` `getOutRaster()`
Returns the Output raster 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.
` double` `getZFactor()`
Returns the Z factor parameter of this tool .
` void` `setInAfterSurface(Object inAfterSurface)`
Sets the Input after raster surface parameter of this tool .
` void` `setInBeforeSurface(Object inBeforeSurface)`
Sets the Input before raster surface parameter of this tool .
` void` `setOutRaster(Object outRaster)`
Sets the Output raster parameter of this tool .
` void` `setZFactor(double zFactor)`
Sets the Z factor 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

### CutFill

`public CutFill()`
Creates the Cut Fill tool with defaults.

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

### CutFill

```public CutFill(Object inBeforeSurface,
Object inAfterSurface,
Object outRaster)```
Creates the Cut Fill 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:
`inBeforeSurface` - the input representing the surface before the cut or fill operation.
`inAfterSurface` - the input representing the surface after the cut or fill operation.
`outRaster` - the output raster defining regions of cut and of fill. the values show the locations and amounts where the surface has been added to or removed from.
Method Detail

### getInBeforeSurface

`public Object getInBeforeSurface()`
Returns the Input before raster surface parameter of this tool . This parameter is the input representing the surface before the cut or fill operation. This is a required parameter.

Returns:
the Input before raster surface

### setInBeforeSurface

`public void setInBeforeSurface(Object inBeforeSurface)`
Sets the Input before raster surface parameter of this tool . This parameter is the input representing the surface before the cut or fill operation. This is a required parameter.

Parameters:
`inBeforeSurface` - the input representing the surface before the cut or fill operation.

### getInAfterSurface

`public Object getInAfterSurface()`
Returns the Input after raster surface parameter of this tool . This parameter is the input representing the surface after the cut or fill operation. This is a required parameter.

Returns:
the Input after raster surface

### setInAfterSurface

`public void setInAfterSurface(Object inAfterSurface)`
Sets the Input after raster surface parameter of this tool . This parameter is the input representing the surface after the cut or fill operation. This is a required parameter.

Parameters:
`inAfterSurface` - the input representing the surface after the cut or fill operation.

### getOutRaster

`public Object getOutRaster()`
Returns the Output raster parameter of this tool . This parameter is the output raster defining regions of cut and of fill. the values show the locations and amounts where the surface has been added to or removed from. This is a required parameter.

Returns:
the Output raster

### setOutRaster

`public void setOutRaster(Object outRaster)`
Sets the Output raster parameter of this tool . This parameter is the output raster defining regions of cut and of fill. the values show the locations and amounts where the surface has been added to or removed from. This is a required parameter.

Parameters:
`outRaster` - the output raster defining regions of cut and of fill. the values show the locations and amounts where the surface has been added to or removed from.

### getZFactor

`public double getZFactor()`
Returns the Z factor parameter of this tool . This parameter is number of ground x,y units in one surface z unit. the z-factor adjusts the units of measure for the z units when they are different from the x,y units of the input surface. The z-values of the input surface are multiplied by the z-factor when calculating the final output surface. if the x,y units and z units are in the same units of measure, the z-factor is 1. This is the default. if the x,y units and z units are in different units of measure, the z-factor must be set to the appropriate factor, or the results will be incorrect. For example, if your z units are feet and your x,y units are meters, you would use a z-factor of 0.3048 to convert your z units from feet to meters (1 foot = 0.3048 meter). This is an optional parameter.

Returns:
the Z factor

### setZFactor

`public void setZFactor(double zFactor)`
Sets the Z factor parameter of this tool . This parameter is number of ground x,y units in one surface z unit. the z-factor adjusts the units of measure for the z units when they are different from the x,y units of the input surface. The z-values of the input surface are multiplied by the z-factor when calculating the final output surface. if the x,y units and z units are in the same units of measure, the z-factor is 1. This is the default. if the x,y units and z units are in different units of measure, the z-factor must be set to the appropriate factor, or the results will be incorrect. For example, if your z units are feet and your x,y units are meters, you would use a z-factor of 0.3048 to convert your z units from feet to meters (1 foot = 0.3048 meter). This is an optional parameter.

Parameters:
`zFactor` - number of ground x,y units in one surface z unit. the z-factor adjusts the units of measure for the z units when they are different from the x,y units of the input surface. The z-values of the input surface are multiplied by the z-factor when calculating the final output surface. if the x,y units and z units are in the same units of measure, the z-factor is 1. This is the default. if the x,y units and z units are in different units of measure, the z-factor must be set to the appropriate factor, or the results will be incorrect. For example, if your z units are feet and your x,y units are meters, you would use a z-factor of 0.3048 to convert your z units from feet to meters (1 foot = 0.3048 meter).

### 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