AMD:
require(["esri/symbols/support/cimConversionUtils"], (cimConversionUtils) => { /* code goes here */ });
ESM:
import * as cimConversionUtils from "@arcgis/core/symbols/support/cimConversionUtils.js";
Object:
esri/symbols/support/cimConversionUtils
Since: ArcGIS Maps SDK for JavaScript 4.29
beta
Provides utility functions for converting simple symbols and picture symbols to CIMSymbols.
- See also
Method Overview
Name | Return Type | Summary | Object |
---|---|---|---|
Converts a given symbol to a CIMSymbol. | cimConversionUtils |
Method Details
-
convertToCIMSymbol
convertToCIMSymbol(symbol){CIMSymbol}
-
Converts a given symbol to a CIMSymbol.
ParameterThe symbol to convert to a CIMSymbol.
ReturnsType Description CIMSymbol Returns a CIMSymbol representation of the given symbol. Exampleconst simpleLine = new SimpleLineSymbol({ width: 1, color: "black", style: "dash", cap: "round", }); const cimLine = cimConversionUtils.convertToCIMSymbol(simpleLine); graphic.symbol = cimLine;