dymaptic.GeoBlazor.Core

dymaptic.GeoBlazor.Core.Components

ScaleBarViewModel Class

Provides the logic for the Scale Bar component and ScaleBar widget.
ArcGIS Maps SDK for JavaScript

public class ScaleBarViewModel : dymaptic.GeoBlazor.Core.Components.MapComponent,
dymaptic.GeoBlazor.Core.Interfaces.IViewModel

Inheritance System.Object 🡒 Microsoft.AspNetCore.Components.ComponentBase 🡒 MapComponent 🡒 ScaleBarViewModel

Implements IViewModel

Constructors

ScaleBarViewModel() Constructor

Parameterless constructor for use as a Razor Component.

public ScaleBarViewModel();

Properties

ScaleBarViewModel.State Property

The current state of the widget.
ArcGIS Maps SDK for JavaScript

public System.Nullable<dymaptic.GeoBlazor.Core.Enums.ScaleBarViewModelState> State { get; set; }

Property Value

System.Nullable<ScaleBarViewModelState>

Methods

ScaleBarViewModel.GetScaleBarProperties(double, MeasurementSystem) Method

Computes the size and units of the scale bar widget given a base length in pixels.
param measurementSystem The measurement system to use.
ArcGIS Maps SDK for JavaScript

public System.Threading.Tasks.Task<string?> GetScaleBarProperties(double length, dymaptic.GeoBlazor.Core.Enums.MeasurementSystem measurementSystem);

Parameters

length System.Double

The base width of the scale bar widget in pixels.

measurementSystem MeasurementSystem

The measurement system to use.

Returns

System.Threading.Tasks.Task<System.String>

ScaleBarViewModel.GetState() Method

Asynchronously retrieve the current value of the State property.

public System.Threading.Tasks.Task<System.Nullable<dymaptic.GeoBlazor.Core.Enums.ScaleBarViewModelState>> GetState();

Returns

System.Threading.Tasks.Task<System.Nullable<ScaleBarViewModelState>>