SimpleLineSymbol

class SimpleLineSymbol : LineSymbol

Used to draw linear features on a layer. Simple line symbols display graphics using predefined line style patterns such as solid, dash, dot, etc.

See also

Constructors

Link copied to clipboard
fun SimpleLineSymbol(    style: SimpleLineSymbolStyle = SimpleLineSymbolStyle.Solid,     color: Color = Color.white,     width: Float = 1.0f,     markerStyle: SimpleLineSymbolMarkerStyle = SimpleLineSymbolMarkerStyle.None,     markerPlacement: SimpleLineSymbolMarkerPlacement = SimpleLineSymbolMarkerPlacement.End)

Creates a simple line symbol object with some initial values.

Functions

Link copied to clipboard
open override fun clone(): SimpleLineSymbol

Clones the SimpleLineSymbol.

Link copied to clipboard
suspend fun createSwatch(    screenScale: Float,     width: Float? = null,     height: Float? = null,     backgroundColor: Color = Color.transparent): Result<BitmapDrawable>

Creates a swatch of the symbol. This method will scale the symbol up or down in order to fit it in to the desired width and height of the swatch.

suspend fun createSwatch(    screenScale: Float,     width: Float,     height: Float,     geometry: Geometry,     backgroundColor: Color = Color.transparent): Result<BitmapDrawable>

Creates a swatch of the symbol.

Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
Link copied to clipboard
open override fun hashCode(): Int
Link copied to clipboard
open override fun toJson(): String

Convert an object to JSON string.

Link copied to clipboard
fun toMultilayerSymbol(): MultilayerPolylineSymbol

Get Multilayer polyline symbol generated from simple line symbol. Multilayer symbol API allows users to create complex and custom symbols with multiple layers of different type of symbology. Simple line symbol offers a factory of styles like dash, dash_dot_dot etc. This helper method exports this symbol to MultilayerPolylineSymbol with SolidStrokeSymbolLayer and predefined collection of DashGeometricEffect.

Properties

Link copied to clipboard
var antiAlias: Boolean

The anti-alias setting of the line symbol.

Link copied to clipboard
var color: Color

The color for the line symbol. When getting the color (or tint color) from a symbol, the consensus value (for all layers) is reported. If there is no consensus (one or more layers have different colors), a null value is reported for the color. Likewise, setting a value for color on a symbol will apply that color to all layers the symbol contains.

Link copied to clipboard
var markerPlacement: SimpleLineSymbolMarkerPlacement

The simple line symbol end marker placement of the simple line symbol.

Link copied to clipboard
var markerStyle: SimpleLineSymbolMarkerStyle

The simple line symbol end marker style of the simple line symbol.

Link copied to clipboard
var style: SimpleLineSymbolStyle

The style of the simple line symbol. SimpleLineSymbolStyle.Solid if an error occurs.

Link copied to clipboard
open override val unknownJson: Map<String, Any>

Unknown data from the source JSON. Unknown JSON is a dictionary of values that was in the source JSON but was unparsed by this API.

Link copied to clipboard
open override val unsupportedJson: Map<String, Any>

Unsupported data from the source JSON. Unsupported JSON is a dictionary of values that are supported by web maps, but not exposed through this API.

Link copied to clipboard
var width: Float

The width of the line symbol.