require(["esri/tasks/OffsetParameters"], function(OffsetParameters) { /* code goes here */ });
Description
Samples
Search for
samples that use this class.
Constructors
Properties
bevelRatio | Number | The bevelRatio is multiplied by the offset distance and the result determines how far a mitered offset intersection can be located before it is beveled. |
geometries | Geometry[] | The array of geometries to be offset. |
offsetDistance | Number | Specifies the planar distance for constructing an offset based on the input geometries. |
offsetHow | String | Options that determine how the ends intersect. |
offsetUnit | String | The offset distance unit. |
Constructor Details
Creates a new OffsetParameters object. The constructor takes no parameters
Sample:
require([
"esri/tasks/OffsetParameters", ...
], function(OffsetParameters, ... ) {
var offsetParams = new OffsetParameters();
...
});
Property Details
The bevelRatio is multiplied by the offset distance and the result determines how far a mitered offset intersection can be located before it is beveled. When mitered is specified, the value set for bevelRatio is ignored and 10 is used internally. If beveled is specified 1.1 will be used if no value is set for bevelRatio. The bevelRatio is ignored when rounded is specified.
Sample:
offsetParams.offsetHow = "esriGeometryOffsetBevelled";
offsetParams.bevelRatio = 2;
The array of geometries to be offset.
Specifies the planar distance for constructing an offset based on the input geometries. If the offsetDistance parameter is positive the constructed offset will be on the right side of the curve. Left side offsets are constructed with negative values.
Options that determine how the ends intersect. Set to one of the following options.
- esriGeometryOffsetBevelled: Squares off the corner after a given ratio distance.
- esriGeometryOffsetMitered: Attempts to allow extended offsets to naturally intersect. If the intersection occurs too far from a corner, the corner will be beveled off at a fixed distance.
- esriGeometryOffsetRounded: Rounds the corner between extended offsets.