cimConversionUtils

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.

Method Overview

Name Return Type Summary Object

Converts a given symbol to a CIMSymbol.

cimConversionUtils

Method Details

convertToCIMSymbol

Method
convertToCIMSymbol(symbol){CIMSymbol}

Converts a given symbol to a CIMSymbol.

Parameter
Returns
Type Description
CIMSymbol Returns a CIMSymbol representation of the given symbol.
Example
const simpleLine = new SimpleLineSymbol({
   width: 1,
   color: "black",
   style: "dash",
   cap: "round",
});
const cimLine = cimConversionUtils.convertToCIMSymbol(simpleLine);
graphic.symbol = cimLine;

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.