import { executeMany, supportsCurves } from "@arcgis/core/geometry/operators/graphicBufferOperator.js";const { executeMany, supportsCurves } = await $arcgis.import("@arcgis/core/geometry/operators/graphicBufferOperator.js");- Since
- ArcGIS Maps SDK for JavaScript 4.31
Creates planar buffers around 2D geometries using graphical joins and caps.

Type definitions
Options
maxDeviation
The max deviation of the result buffer from the true buffer in the geometries spatial reference units.
When the value is NaN, internal logic is used to select the deviation based on the buffer distance.
Unless the unit option is set, the default is the geometries spatial reference unit.
- Default value
- NaN
unit
- Type
- LengthUnit | undefined
The length unit of the buffer distances and max deviation. The default is the input geometries spatial reference unit. An error will be thrown if this is set for Geographic Coordinate Systems.
Functions
| Name | Return Type | Object |
|---|---|---|
| | |
Polygon[] | | |
| |
executeMany
Creates a buffer around the input geometries, using graphical joins and caps.
Both maxDeviation and maxVerticesInFullCircle control the quality of round joins that are in the buffers.
The precision of each buffer is defined by maxDeviation unless the number of required vertices is too large.
- Signature
-
executeMany (geometries: GeometryUnion[], distances: number[], joins: "round" | "miter" | "bevel", caps: "round" | "butt" | "square", options?: Options): Polygon[]
Parameters
| Parameter | Type | Description | Required |
|---|---|---|---|
| geometries | The input geometries to be buffered. All the geometries must have the same spatial reference. | | |
| distances | number[] | The buffer distances for the geometries.
If the size of this array is less than the number of geometries in the input | |
| joins | "round" | "miter" | "bevel" | Defines the buffers shape where geometries are joined.
| |
| caps | "round" | "butt" | "square" | Defines the buffers shape at the end points of the geometries.
| |
| options | Additional options. | |
- Returns
- Polygon[]
Returns the buffered geometries.
Example
// Buffer two polylines with different distances and buffer styles.const buffers = graphicBufferOperator.executeMany( [polyline1, polyline2], [1000, 1500], "square", "round", 10,);Variables
supportsCurves
Indicates if the operator supports input geometries that contain curves.
The value will always be true. This will produce densified output geometries.
- Type
- boolean