layout: default title: MapView parent: Core Classes —

dymaptic.GeoBlazor.Core

dymaptic.GeoBlazor.Core.Components.Views

MapView Class

The Top-Level Map Component Container.
A MapView displays a 2D view of a Map instance. An instance of MapView must be created to render a Map (along with
its operational and base layers) in 2D. To render a map and its layers in 3D, see the documentation for SceneView.
For a general overview of views, see View.
ArcGIS Maps SDK for JavaScript

public class MapView : dymaptic.GeoBlazor.Core.Components.MapComponent

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

Derived
SceneView

Example

Sample - Navigation

Properties

MapView.AllowDefaultEsriLogin Property

Allows maps to be rendered without an Api or OAuth Token, which will trigger a default esri login popup.

public System.Nullable<bool> AllowDefaultEsriLogin { get; set; }

Property Value

System.Nullable<System.Boolean>

MapView.AuthenticationManager Property

Handles OAuth authentication

public dymaptic.GeoBlazor.Core.Model.AuthenticationManager AuthenticationManager { get; set; }

Property Value

AuthenticationManager

MapView.Center Property

The Center point of the view, equivalent to setting Latitude/Longitude

public dymaptic.GeoBlazor.Core.Components.Geometries.Point? Center { get; set; }

Property Value

Point

MapView.Class Property

Inline html/css class selector for applying css

public string Class { get; set; }

Property Value

System.String

MapView.Configuration Property

A set of key/value application configuration properties, that can be populated from `appsettings.json, environment
variables, or other sources.

public Microsoft.Extensions.Configuration.IConfiguration Configuration { get; set; }

Property Value

Microsoft.Extensions.Configuration.IConfiguration

MapView.EventRateLimitInMilliseconds Property

Set this parameter to limit the rate at which recurring events are returned. Applies to OnDrag,
OnPointerMove, OnMouseWheel, OnResize, and
OnExtentChanged

public System.Nullable<int> EventRateLimitInMilliseconds { get; set; }

Property Value

System.Nullable<System.Int32>

MapView.ExtentChangedInJs Property

A boolean flag to indicate that the map extent has been modified in JavaScript, and therefore should not be
modifiable by markup until Refresh() is called

public bool ExtentChangedInJs { get; set; }

Property Value

System.Boolean

MapView.Graphics Property

The collection of Graphics in the view. These are directly on the view itself, not in a
GraphicsLayer.

public System.Collections.Generic.IReadOnlyCollection<dymaptic.GeoBlazor.Core.Components.Layers.Graphic> Graphics { get; set; }

Property Value

System.Collections.Generic.IReadOnlyCollection<Graphic>

MapView.GraphicSerializationChunkSize Property

Optional setting to control the number of graphics that are serialized in a single chunk. Tuning this value might help with performance when adding large graphic sets.

public System.Nullable<int> GraphicSerializationChunkSize { get; set; }

Property Value

System.Nullable<System.Int32>

MapView.IsMaui Property

Boolean flag to identify if GeoBlazor is running in Blazor Hybrid (MAUI) mode

public bool IsMaui { get; }

Property Value

System.Boolean

MapView.IsServer Property

Boolean flag to identify if GeoBlazor is running in Blazor Server mode

public bool IsServer { get; }

Property Value

System.Boolean

MapView.IsWebAssembly Property

Boolean flag to identify if GeoBlazor is running in Blazor WebAssembly (client) mode

public bool IsWebAssembly { get; }

Property Value

System.Boolean

MapView.Latitude Property

The Latitude for the Center point of the view

public System.Nullable<double> Latitude { get; set; }

Property Value

System.Nullable<System.Double>

MapView.LoadOnRender Property

Boolean flag that can be set to false to prevent the MapView from automatically rendering with the Blazor
components.

public bool LoadOnRender { get; set; }

Property Value

System.Boolean

MapView.Longitude Property

The Longitude for the Center point of the view

public System.Nullable<double> Longitude { get; set; }

Property Value

System.Nullable<System.Double>

MapView.Map Property

An instance of a Map object to display in the view.

public virtual dymaptic.GeoBlazor.Core.Components.Map? Map { get; set; }

Property Value

Map

MapView.OnBlur Property

Handler delegate for blur (lost focus) events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.BlurEvent> OnBlur { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<BlurEvent>

MapView.OnClick Property

Handler delegate for click events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ClickEvent> OnClick { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ClickEvent>

MapView.OnDoubleClick Property

Handler delegate for double-click events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ClickEvent> OnDoubleClick { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ClickEvent>

MapView.OnDrag Property

Handler delegate for pointer drag events on the view, returns a DragEvent.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.DragEvent> OnDrag { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<DragEvent>

Remarks

The real-time nature of this handler make it a challenge to use continuously over SignalR in Blazor Server.
In this scenario, you should write a custom JavaScript handler instead.

MapView.OnExtentChanged Property

Handler delegate for the view’s Extent changing.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Components.Geometries.Extent> OnExtentChanged { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<Extent>

MapView.OnFocus Property

Handler delegate for focus events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.FocusEvent> OnFocus { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<FocusEvent>

MapView.OnHold Property

Handler delegate for hold events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ClickEvent> OnHold { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ClickEvent>

MapView.OnImmediateClick Property

Handler delegate for immediate-click events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ClickEvent> OnImmediateClick { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ClickEvent>

MapView.OnImmediateDoubleClick Property

Handler delegate for immediate-double-click events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ClickEvent> OnImmediateDoubleClick { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ClickEvent>

MapView.OnJavascriptErrorHandler Property

Implement this handler in your calling code to catch and handle Javascript errors.

public System.Func<dymaptic.GeoBlazor.Core.Exceptions.JavascriptException,System.Threading.Tasks.Task>? OnJavascriptErrorHandler { get; set; }

Property Value

System.Func<JavascriptException,System.Threading.Tasks.Task>

MapView.OnKeyDown Property

Handler delegate for key-down events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.KeyDownEvent> OnKeyDown { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<KeyDownEvent>

Remarks

Fires after a keyboard key is pressed.

MapView.OnKeyUp Property

Handler delegate for key-up events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.KeyUpEvent> OnKeyUp { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<KeyUpEvent>

Remarks

Fires after a keyboard key is released.

MapView.OnLayerViewCreate Property

Fires after each layer in the map has a corresponding LayerView created and rendered in the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.LayerViewCreateEvent> OnLayerViewCreate { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<LayerViewCreateEvent>

MapView.OnLayerViewCreateError Property

Fires after a LayerView is destroyed and is no longer rendered in the view. This happens for example when a layer
is removed from the map of the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.LayerViewCreateErrorEvent> OnLayerViewCreateError { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<LayerViewCreateErrorEvent>

MapView.OnLayerViewDestroy Property

Fires after a LayerView is destroyed and is no longer rendered in the view. This happens for example when a layer
is removed from the map of the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.LayerViewDestroyEvent> OnLayerViewDestroy { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<LayerViewDestroyEvent>

MapView.OnMouseWheel Property

Handler delegate for the view’s Extent changing.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.MouseWheelEvent> OnMouseWheel { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<MouseWheelEvent>

MapView.OnPointerDown Property

Handler delegate for pointer down events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.PointerEvent> OnPointerDown { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<PointerEvent>

Remarks

Fires after a mouse button is pressed, or a finger touches the display.

MapView.OnPointerEnter Property

Handler delegate for pointer enter events on the view.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.PointerEvent> OnPointerEnter { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<PointerEvent>

Remarks

Fires after a mouse cursor enters the view, or a display touch begins.

MapView.OnPointerLeave Property

Handler delegate for pointer leave events on the view. Must take in a Point and return a
System.Threading.Tasks.Task.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.PointerEvent> OnPointerLeave { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<PointerEvent>

Remarks

Fires after a mouse cursor leaves the view, or a display touch ends.

MapView.OnPointerMove Property

Handler delegate for point move events on the view. Must take in a Point and return a
System.Threading.Tasks.Task.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.PointerEvent> OnPointerMove { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<PointerEvent>

Remarks

The real-time nature of this handler make it a challenge to use continuously over SignalR in Blazor Server.
In this scenario, you should write a custom JavaScript handler instead.
See

Display
Projection

code.

MapView.OnPointerUp Property

Handler delegate for pointer up events on the view. Must take in a Point and return a
System.Threading.Tasks.Task.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.PointerEvent> OnPointerUp { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<PointerEvent>

Remarks

Fires after a mouse button is released, or a display touch ends.

MapView.OnResize Property

Handler delegate for the view’s Extent changing.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Events.ResizeEvent> OnResize { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<ResizeEvent>

MapView.OnSpatialReferenceChanged Property

Handler delegate for the view’s Spatial Reference changing.

public Microsoft.AspNetCore.Components.EventCallback<dymaptic.GeoBlazor.Core.Components.Geometries.SpatialReference> OnSpatialReferenceChanged { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<SpatialReference>

MapView.OnViewInitialized Property

Event triggered when the JS view is created, but before the full map is rendered.

public Microsoft.AspNetCore.Components.EventCallback OnViewInitialized { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback

MapView.OnViewRendered Property

Handler delegate for when the map view is fully rendered. Must return a System.Threading.Tasks.Task.

public Microsoft.AspNetCore.Components.EventCallback<System.Guid> OnViewRendered { get; set; }

Property Value

Microsoft.AspNetCore.Components.EventCallback<System.Guid>

MapView.PopupEnabled Property

Controls whether the popup opens when users click on the view.
When true, a Popup instance is created and assigned to view.popup the first time the user clicks on the view, unless popup is null. The popup then processes the click event.
When false, the click event is ignored and popup is not created for features but will open for other scenarios that use a popup, such as displaying Search results.
Default Value:true

public System.Nullable<bool> PopupEnabled { get; set; }

Property Value

System.Nullable<System.Boolean>

MapView.PromptForArcGISKey Property

Provides an override for the default behavior of requiring an API key. By setting to “false”, all calls to ArcGIS
services will trigger a sign-in popup.

public System.Nullable<bool> PromptForArcGISKey { get; set; }

Property Value

System.Nullable<System.Boolean>

Remarks

Setting this to “false” is the same as setting AllowDefaultEsriLogin to “true”. This is provided
simply for convenience of discovery.

MapView.PromptForOAuthLogin Property

If you set an AppId in your configuration, setting this to true will cause the app to attempt to auto-login
using ArcGIS OAuth.

public System.Nullable<bool> PromptForOAuthLogin { get; set; }

Property Value

System.Nullable<System.Boolean>

MapView.QueryResultsMaxSizeLimit Property

The maximum size of query results that will be returned in a stream. Note that setting this to a smaller
value might create errors in query returns.

public long QueryResultsMaxSizeLimit { get; set; }

Property Value

System.Int64

MapView.Rotation Property

The clockwise rotation of due north in relation to the top of the view in degrees.

public double Rotation { get; set; }

Property Value

System.Double

MapView.Scale Property

Represents the map scale at the center of the view.

public System.Nullable<double> Scale { get; set; }

Property Value

System.Nullable<System.Double>

MapView.Style Property

Inline css styling attribute

public string Style { get; set; }

Property Value

System.String

MapView.Widgets Property

The collection of Widgets in the view.

public System.Collections.Generic.IReadOnlyCollection<dymaptic.GeoBlazor.Core.Components.Widgets.Widget> Widgets { get; set; }

Property Value

System.Collections.Generic.IReadOnlyCollection<Widget>

MapView.Zoom Property

Represents the level of detail (LOD) at the center of the view.

public System.Nullable<double> Zoom { get; set; }

Property Value

System.Nullable<System.Double>

Methods

MapView.AddGraphic(Graphic) Method

Adds a Graphic to the current view, or to a GraphicsLayer.

public System.Threading.Tasks.Task AddGraphic(dymaptic.GeoBlazor.Core.Components.Layers.Graphic graphic);

Parameters

graphic Graphic

The Graphic to add.

Returns

System.Threading.Tasks.Task

MapView.AddGraphics(IEnumerable, CancellationToken) Method

Adds a collection of Graphics to the current view

public System.Threading.Tasks.Task AddGraphics(System.Collections.Generic.IEnumerable<dymaptic.GeoBlazor.Core.Components.Layers.Graphic> graphics, System.Threading.CancellationToken cancellationToken=default(System.Threading.CancellationToken));

Parameters

graphics System.Collections.Generic.IEnumerable<Graphic>

cancellationToken System.Threading.CancellationToken

Returns

System.Threading.Tasks.Task

MapView.AddLayer(Layer, bool) Method

Adds a layer to the current Map

public System.Threading.Tasks.Task AddLayer(dymaptic.GeoBlazor.Core.Components.Layers.Layer layer, bool isBasemapLayer=false);

Parameters

layer Layer

The layer to add

isBasemapLayer System.Boolean

If true, adds the layer as a Basemap. If there is no Basemap yet, one will be created.

Returns

System.Threading.Tasks.Task

MapView.AddWidget(Widget) Method

Adds a widget to the view.

public System.Threading.Tasks.Task AddWidget(dymaptic.GeoBlazor.Core.Components.Widgets.Widget widget);

Parameters

widget Widget

Returns

System.Threading.Tasks.Task

MapView.ClearGraphics() Method

Clears all graphics from the view.

public System.Threading.Tasks.Task ClearGraphics();

Returns

System.Threading.Tasks.Task

MapView.ClosePopup() Method

Closes the popup by setting its visible property to false. Users can alternatively close the popup by directly
setting the visible property to false.

public System.Threading.Tasks.Task ClosePopup();

Returns

System.Threading.Tasks.Task

MapView.DisposeAsync() Method

Implements the IAsyncDisposable pattern.

public override System.Threading.Tasks.ValueTask DisposeAsync();

Implements DisposeAsync()

Returns

System.Threading.Tasks.ValueTask

MapView.DrawRouteAndGetDirections(Symbol, string) Method

A custom method to set up the interaction for clicking a start and end point, and have the view render a driving
route. Also returns a set of Directions for display.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Objects.Direction[]> DrawRouteAndGetDirections(dymaptic.GeoBlazor.Core.Components.Symbols.Symbol routeSymbol, string routeUrl);

Parameters

routeSymbol Symbol

The Symbol used to render the route.

routeUrl System.String

A routing service url for calculating the route.

Returns

System.Threading.Tasks.Task<Direction[]>
A collection of Direction steps to follow the route.

MapView.FindPlaces(AddressQuery, Symbol, PopupTemplate) Method

A custom method to run an AddressQuery against the current view, and display the results.

public System.Threading.Tasks.Task FindPlaces(dymaptic.GeoBlazor.Core.Objects.AddressQuery query, dymaptic.GeoBlazor.Core.Components.Symbols.Symbol displaySymbol, dymaptic.GeoBlazor.Core.Components.Popups.PopupTemplate popupTemplate);

Parameters

query AddressQuery

The AddressQuery to run.

displaySymbol Symbol

The Symbol to use to render the results of the query.

popupTemplate PopupTemplate

A PopupTemplate for displaying Popups on rendered results.

Returns

System.Threading.Tasks.Task

MapView.GetCenter() Method

Returns the center Point of the current view extent.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Components.Geometries.Point?> GetCenter();

Returns

System.Threading.Tasks.Task<Point>

MapView.GetCursor() Method

Returns the current cursor when hovering over the view.

public System.Threading.Tasks.Task<string> GetCursor();

Returns

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

MapView.GetDotNetPopupTemplateObjectReference(Guid) Method

For internal use only, this looks up a missing dymaptic.GeoBlazor.Core.Components.Views.MapView.DotNetObjectReference for a PopupTemplate
and returns it to JavaScript.

public Microsoft.JSInterop.DotNetObjectReference<dymaptic.GeoBlazor.Core.Components.Popups.PopupTemplate>? GetDotNetPopupTemplateObjectReference(System.Guid popupTemplateId);

Parameters

popupTemplateId System.Guid

Returns

Microsoft.JSInterop.DotNetObjectReference<PopupTemplate>

MapView.GetExtent() Method

Returns the current dymaptic.GeoBlazor.Core.Components.Views.MapView.Extent of the view.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Components.Geometries.Extent?> GetExtent();

Returns

System.Threading.Tasks.Task<Extent>

MapView.GetId() Method

JS-Invokable method to generate a new GUID Id

public string GetId();

Returns

System.String

MapView.GetPopupWidget() Method

Retrieves the Popup Widget for the view.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Components.Widgets.PopupWidget?> GetPopupWidget();

Returns

System.Threading.Tasks.Task<PopupWidget>

MapView.GetRotation() Method

Returns the rotation of the current view.

public System.Threading.Tasks.Task<System.Nullable<double>> GetRotation();

Returns

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

MapView.GetScale() Method

Returns the scale of the current view.

public System.Threading.Tasks.Task<System.Nullable<double>> GetScale();

Returns

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

MapView.GetSpatialReference() Method

Returns the current dymaptic.GeoBlazor.Core.Components.Views.MapView.SpatialReference of the view.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Components.Geometries.SpatialReference?> GetSpatialReference();

Returns

System.Threading.Tasks.Task<SpatialReference>

MapView.GetZoom() Method

Returns the zoom level of the current view.

public System.Threading.Tasks.Task<System.Nullable<double>> GetZoom();

Returns

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

MapView.GoTo(Extent) Method

Changes the view dymaptic.GeoBlazor.Core.Components.Views.MapView.Extent and redraws.

public System.Threading.Tasks.Task GoTo(dymaptic.GeoBlazor.Core.Components.Geometries.Extent extent);

Parameters

extent Extent

The new dymaptic.GeoBlazor.Core.Components.Views.MapView.Extent of the view.

Returns

System.Threading.Tasks.Task

MapView.GoTo(IEnumerable) Method

Changes the view dymaptic.GeoBlazor.Core.Components.Views.MapView.Extent and redraws.

public virtual System.Threading.Tasks.Task GoTo(System.Collections.Generic.IEnumerable<dymaptic.GeoBlazor.Core.Components.Layers.Graphic> graphics);

Parameters

graphics System.Collections.Generic.IEnumerable<Graphic>

The Graphics to zoom to.

Returns

System.Threading.Tasks.Task

MapView.HitTest(Point, HitTestOptions) Method

Returns HitTestResults from each layer that intersects the specified screen coordinates. The results
are organized as an array of objects containing different result types.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Events.HitTestResult> HitTest(dymaptic.GeoBlazor.Core.Components.Geometries.Point mapPoint, dymaptic.GeoBlazor.Core.Events.HitTestOptions? options=null);

Parameters

mapPoint Point

The map point, in the same projection as the map, to check for hits.

options HitTestOptions

Options to specify what is included in or excluded from the hitTest.

Returns

System.Threading.Tasks.Task<HitTestResult>

MapView.HitTest(ClickEvent, HitTestOptions) Method

Returns HitTestResults from each layer that intersects the specified screen coordinates. The results
are organized as an array of objects containing different result types.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Events.HitTestResult> HitTest(dymaptic.GeoBlazor.Core.Events.ClickEvent clickEvent, dymaptic.GeoBlazor.Core.Events.HitTestOptions? options=null);

Parameters

clickEvent ClickEvent

The click event to test for hits.

options HitTestOptions

Options to specify what is included in or excluded from the hitTest.

Returns

System.Threading.Tasks.Task<HitTestResult>

MapView.HitTest(PointerEvent, HitTestOptions) Method

Returns HitTestResults from each layer that intersects the specified screen coordinates. The results
are organized as an array of objects containing different result types.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Events.HitTestResult> HitTest(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent, dymaptic.GeoBlazor.Core.Events.HitTestOptions? options=null);

Parameters

pointerEvent PointerEvent

The pointer event to test for hits.

options HitTestOptions

Options to specify what is included in or excluded from the hitTest.

Returns

System.Threading.Tasks.Task<HitTestResult>

MapView.HitTest(ScreenPoint, HitTestOptions) Method

Returns HitTestResults from each layer that intersects the specified screen coordinates. The results
are organized as an array of objects containing different result types.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Events.HitTestResult> HitTest(dymaptic.GeoBlazor.Core.Events.ScreenPoint screenPoint, dymaptic.GeoBlazor.Core.Events.HitTestOptions? options=null);

Parameters

screenPoint ScreenPoint

The screen point to check for hits.

options HitTestOptions

Options to specify what is included in or excluded from the hitTest.

Returns

System.Threading.Tasks.Task<HitTestResult>

MapView.Load() Method

Manually loads and renders the MapView, if the consumer has also set LoadOnRender to false.
If LoadOnRender is true, this method will function the same as Refresh().

public void Load();

MapView.OnHitTestStreamCallback(IJSStreamReference, Guid) Method

Internal use callback from JavaScript

public System.Threading.Tasks.Task OnHitTestStreamCallback(Microsoft.JSInterop.IJSStreamReference streamReference, System.Guid hitTestId);

Parameters

streamReference Microsoft.JSInterop.IJSStreamReference

hitTestId System.Guid

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptBlur(BlurEvent) Method

JS-Invokable method to return view blur (lost focus) events.

public System.Threading.Tasks.Task OnJavascriptBlur(dymaptic.GeoBlazor.Core.Events.BlurEvent blurEvent);

Parameters

blurEvent BlurEvent

The BlurEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptClick(ClickEvent) Method

JS-Invokable method to return view clicks.

public System.Threading.Tasks.Task OnJavascriptClick(dymaptic.GeoBlazor.Core.Events.ClickEvent clickEvent);

Parameters

clickEvent ClickEvent

The ClickEvent return meta object.

Returns

System.Threading.Tasks.Task

Remarks

Fires after a user clicks on the view. This event emits slightly slower than an immediate-click event to make sure
that a double-click event isn’t triggered instead. The immediate-click event can be used for responding to a click
event without delay.

MapView.OnJavascriptDoubleClick(ClickEvent) Method

JS-Invokable method to return view double-clicks.

public System.Threading.Tasks.Task OnJavascriptDoubleClick(dymaptic.GeoBlazor.Core.Events.ClickEvent clickEvent);

Parameters

clickEvent ClickEvent

The ClickEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptDrag(DragEvent) Method

JS-Invokable method to return view drag events.

public System.Threading.Tasks.Task OnJavascriptDrag(dymaptic.GeoBlazor.Core.Events.DragEvent dragEvent);

Parameters

dragEvent DragEvent

The DragEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptError(JavascriptError) Method

Surfaces JavaScript errors to the .NET Code for debugging.

public void OnJavascriptError(dymaptic.GeoBlazor.Core.Exceptions.JavascriptError error);

Parameters

error JavascriptError

The original Javascript error.

Exceptions

JavascriptException
Wraps the JS Error and throws a .NET Exception.

MapView.OnJavascriptExtentChanged(Extent, Point, double, double, Nullable, Nullable) Method

JS-Invokable method to return when the map view Extent changes.

public virtual System.Threading.Tasks.Task OnJavascriptExtentChanged(dymaptic.GeoBlazor.Core.Components.Geometries.Extent extent, dymaptic.GeoBlazor.Core.Components.Geometries.Point? center, double zoom, double scale, System.Nullable<double> rotation=null, System.Nullable<double> tilt=null);

Parameters

extent Extent

center Point

zoom System.Double

scale System.Double

rotation System.Nullable<System.Double>

tilt System.Nullable<System.Double>

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptFocus(FocusEvent) Method

JS-Invokable method to return view focus events.

public System.Threading.Tasks.Task OnJavascriptFocus(dymaptic.GeoBlazor.Core.Events.FocusEvent focusEvent);

Parameters

focusEvent FocusEvent

The FocusEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptHitTestResult(Guid, string) Method

The callback method for returning a chunk of data from a Blazor Server hit test.

public void OnJavascriptHitTestResult(System.Guid eventId, string chunk);

Parameters

eventId System.Guid

The hit test event id.

chunk System.String

A chunk of hit test data, to be combined with other data before deserialization.

MapView.OnJavascriptHold(ClickEvent) Method

JS-Invokable method to return view hold events.

public System.Threading.Tasks.Task OnJavascriptHold(dymaptic.GeoBlazor.Core.Events.ClickEvent holdEvent);

Parameters

holdEvent ClickEvent

The ClickEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptImmediateClick(ClickEvent) Method

JS-Invokable method to return view immediate-clicks.

public System.Threading.Tasks.Task OnJavascriptImmediateClick(dymaptic.GeoBlazor.Core.Events.ClickEvent clickEvent);

Parameters

clickEvent ClickEvent

The ClickEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptImmediateDoubleClick(ClickEvent) Method

JS-Invokable method to return view immediate-double-clicks.

public System.Threading.Tasks.Task OnJavascriptImmediateDoubleClick(dymaptic.GeoBlazor.Core.Events.ClickEvent clickEvent);

Parameters

clickEvent ClickEvent

The ClickEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptKeyDown(KeyDownEvent) Method

JS-Invokable method to return view key-down events.

public System.Threading.Tasks.Task OnJavascriptKeyDown(dymaptic.GeoBlazor.Core.Events.KeyDownEvent keyDownEvent);

Parameters

keyDownEvent KeyDownEvent

The KeyDownEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptKeyUp(KeyUpEvent) Method

JS-Invokable method to return view key-up events.

public System.Threading.Tasks.Task OnJavascriptKeyUp(dymaptic.GeoBlazor.Core.Events.KeyUpEvent keyUpEvent);

Parameters

keyUpEvent KeyUpEvent

The KeyUpEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptLayerCreateChunk(string, string, int) Method

JS-Invokable method for internal use only.

public void OnJavascriptLayerCreateChunk(string layerUid, string chunk, int chunkIndex);

Parameters

layerUid System.String

chunk System.String

chunkIndex System.Int32

MapView.OnJavascriptLayerViewCreate(LayerViewCreateInternalEvent) Method

JS-Invokable method to return when a layer view is created.

public System.Threading.Tasks.Task OnJavascriptLayerViewCreate(dymaptic.GeoBlazor.Core.Events.LayerViewCreateInternalEvent layerViewCreateEvent);

Parameters

layerViewCreateEvent LayerViewCreateInternalEvent

The new LayerViewCreateEvent

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptLayerViewCreateChunk(string, string, int) Method

JS-Invokable method for internal use only.

public void OnJavascriptLayerViewCreateChunk(string layerUid, string chunk, int chunkIndex);

Parameters

layerUid System.String

chunk System.String

chunkIndex System.Int32

MapView.OnJavascriptLayerViewCreateComplete(Nullable, string, IJSObjectReference, IJSObjectReference, bool) Method

JS-Invokable method for internal use only.

public System.Threading.Tasks.Task OnJavascriptLayerViewCreateComplete(System.Nullable<System.Guid> geoBlazorLayerId, string layerUid, Microsoft.JSInterop.IJSObjectReference layerRef, Microsoft.JSInterop.IJSObjectReference layerViewRef, bool isBasemapLayer);

Parameters

geoBlazorLayerId System.Nullable<System.Guid>

layerUid System.String

layerRef Microsoft.JSInterop.IJSObjectReference

layerViewRef Microsoft.JSInterop.IJSObjectReference

isBasemapLayer System.Boolean

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptLayerViewCreateError(LayerViewCreateErrorEvent) Method

JS-Invokable method to return when a layer view is destroyed.

public System.Threading.Tasks.Task OnJavascriptLayerViewCreateError(dymaptic.GeoBlazor.Core.Events.LayerViewCreateErrorEvent errorEvent);

Parameters

errorEvent LayerViewCreateErrorEvent

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptLayerViewDestroy(LayerViewDestroyEvent) Method

JS-Invokable method to return when a layer view is destroyed.

public System.Threading.Tasks.Task OnJavascriptLayerViewDestroy(dymaptic.GeoBlazor.Core.Events.LayerViewDestroyEvent layerViewDestroyEvent);

Parameters

layerViewDestroyEvent LayerViewDestroyEvent

The destroyed LayerViewDestroyEvent

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptMouseWheel(MouseWheelEvent) Method

JS-Invokable method to return when the mouse wheel is scrolled.

public System.Threading.Tasks.Task OnJavascriptMouseWheel(dymaptic.GeoBlazor.Core.Events.MouseWheelEvent mouseWheelEvent);

Parameters

mouseWheelEvent MouseWheelEvent

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptPointerDown(PointerEvent) Method

JS-Invokable method to return view pointer down events.

public System.Threading.Tasks.Task OnJavascriptPointerDown(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent);

Parameters

pointerEvent PointerEvent

The PointerEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptPointerEnter(PointerEvent) Method

JS-Invokable method to return view pointer enter events.

public System.Threading.Tasks.Task OnJavascriptPointerEnter(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent);

Parameters

pointerEvent PointerEvent

The PointerEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptPointerLeave(PointerEvent) Method

JS-Invokable method to return view pointer leave events.

public System.Threading.Tasks.Task OnJavascriptPointerLeave(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent);

Parameters

pointerEvent PointerEvent

The PointerEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptPointerMove(PointerEvent) Method

JS-Invokable method to return view pointer movement.

public System.Threading.Tasks.Task OnJavascriptPointerMove(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent);

Parameters

pointerEvent PointerEvent

The PointerEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptPointerUp(PointerEvent) Method

JS-Invokable method to return view pointer up events.

public System.Threading.Tasks.Task OnJavascriptPointerUp(dymaptic.GeoBlazor.Core.Events.PointerEvent pointerEvent);

Parameters

pointerEvent PointerEvent

The PointerEvent return meta object.

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptResize(ResizeEvent) Method

JS-Invokable method to return when the map view is resized in the window.

public System.Threading.Tasks.Task OnJavascriptResize(dymaptic.GeoBlazor.Core.Events.ResizeEvent resizeEvent);

Parameters

resizeEvent ResizeEvent

Returns

System.Threading.Tasks.Task

MapView.OnJavascriptSpatialReferenceChanged(SpatialReference) Method

JS-Invokable method to return when the map view Spatial Reference changes.

public System.Threading.Tasks.Task OnJavascriptSpatialReferenceChanged(dymaptic.GeoBlazor.Core.Components.Geometries.SpatialReference spatialReference);

Parameters

spatialReference SpatialReference

The new dymaptic.GeoBlazor.Core.Components.Views.MapView.SpatialReference

Returns

System.Threading.Tasks.Task

MapView.OnJsViewInitialized() Method

JS-Invokable callback that signifies when the view is created but not yet fully rendered.

public System.Threading.Tasks.Task OnJsViewInitialized();

Returns

System.Threading.Tasks.Task

MapView.OnJsViewRendered() Method

JS-Invokable method to return when the map view is fully rendered.

public System.Threading.Tasks.Task OnJsViewRendered();

Returns

System.Threading.Tasks.Task

MapView.OpenPopup(PopupOpenOptions) Method

Opens the popup at the given location with content defined either explicitly with content or driven from the
PopupTemplate of input features. This method sets the popup’s visible property to true. Users can alternatively
open the popup by directly setting the visible property to true.

public System.Threading.Tasks.Task OpenPopup(dymaptic.GeoBlazor.Core.Components.Widgets.PopupOpenOptions? options=null);

Parameters

options PopupOpenOptions

Defines the location and content of the popup when opened.

Returns

System.Threading.Tasks.Task

MapView.QueryFeatures(Query, FeatureLayer, Symbol, PopupTemplate) Method

A custom method to query a provided FeatureLayer on the current map view, and display the results.

public System.Threading.Tasks.Task QueryFeatures(dymaptic.GeoBlazor.Core.Objects.Query query, dymaptic.GeoBlazor.Core.Components.Layers.FeatureLayer featureLayer, dymaptic.GeoBlazor.Core.Components.Symbols.Symbol displaySymbol, dymaptic.GeoBlazor.Core.Components.Popups.PopupTemplate popupTemplate);

Parameters

query Query

The Query to run.

featureLayer FeatureLayer

The FeatureLayer to query against.

displaySymbol Symbol

The Symbol to use to render the results of the query.

popupTemplate PopupTemplate

A PopupTemplate for displaying Popups on rendered results.

Returns

System.Threading.Tasks.Task

MapView.Refresh() Method

Provides a way to externally call StateHasChanged on the component.

public override void Refresh();

MapView.RegisterChildComponent(MapComponent) Method

Called from dymaptic.GeoBlazor.Core.Components.MapComponent.OnInitializedAsync to “Register” the current component with it’s parent.

public override System.Threading.Tasks.Task RegisterChildComponent(dymaptic.GeoBlazor.Core.Components.MapComponent child);

Parameters

child MapComponent

The calling, child component to register

Returns

System.Threading.Tasks.Task

Exceptions

InvalidChildElementException
Throws if the current child is not a valid sub-component to the parent.

Remarks

This method is an implementation detail and should not be called directly by consumers. In future versions, this may be changed to an internal method. If you see no other way to register a child component, please open an issue on GitHub.

MapView.RemoveGraphic(Graphic) Method

Removes a graphic from the current view.

public System.Threading.Tasks.Task RemoveGraphic(dymaptic.GeoBlazor.Core.Components.Layers.Graphic graphic);

Parameters

graphic Graphic

The Graphic to remove.

Returns

System.Threading.Tasks.Task

MapView.RemoveGraphics(IEnumerable) Method

Removes a collection of graphics from the current view.

public System.Threading.Tasks.Task RemoveGraphics(System.Collections.Generic.IEnumerable<dymaptic.GeoBlazor.Core.Components.Layers.Graphic> graphics);

Parameters

graphics System.Collections.Generic.IEnumerable<Graphic>

The Graphics to remove.

Returns

System.Threading.Tasks.Task

MapView.RemoveLayer(Layer, bool) Method

Removes a layer from the current Map

public System.Threading.Tasks.Task RemoveLayer(dymaptic.GeoBlazor.Core.Components.Layers.Layer layer, bool isBasemapLayer=false);

Parameters

layer Layer

The layer to remove

isBasemapLayer System.Boolean

If true, removes the layer as a Basemap

Returns

System.Threading.Tasks.Task

MapView.RemoveWidget(Widget) Method

Removes a widget from the view.

public System.Threading.Tasks.Task RemoveWidget(dymaptic.GeoBlazor.Core.Components.Widgets.Widget widget);

Parameters

widget Widget

Returns

System.Threading.Tasks.Task

MapView.SetCenter(Point) Method

Sets the center Point of the current view.

public virtual System.Threading.Tasks.Task SetCenter(dymaptic.GeoBlazor.Core.Components.Geometries.Point point);

Parameters

point Point

Returns

System.Threading.Tasks.Task

MapView.SetConstraints(Constraints) Method

Sets the dymaptic.GeoBlazor.Core.Components.Views.MapView.Constraints of the view.

public System.Threading.Tasks.Task SetConstraints(dymaptic.GeoBlazor.Core.Components.Constraints constraints);

Parameters

constraints Constraints

Returns

System.Threading.Tasks.Task

MapView.SetCursor(string) Method

Sets the cursor for the view.

public System.Threading.Tasks.Task SetCursor(string cursor);

Parameters

cursor System.String

Returns

System.Threading.Tasks.Task

MapView.SetExtent(Extent) Method

Sets the dymaptic.GeoBlazor.Core.Components.Views.MapView.Extent of the view.

public virtual System.Threading.Tasks.Task SetExtent(dymaptic.GeoBlazor.Core.Components.Geometries.Extent extent);

Parameters

extent Extent

Returns

System.Threading.Tasks.Task

MapView.SetHighlightOptions(HighlightOptions) Method

Sets the dymaptic.GeoBlazor.Core.Components.Views.MapView.HighlightOptions of the view.

public System.Threading.Tasks.Task SetHighlightOptions(dymaptic.GeoBlazor.Core.Objects.HighlightOptions highlightOptions);

Parameters

highlightOptions HighlightOptions

Returns

System.Threading.Tasks.Task

MapView.SetRotation(double) Method

Sets the rotation of the current view.

public System.Threading.Tasks.Task SetRotation(double rotation);

Parameters

rotation System.Double

Returns

System.Threading.Tasks.Task

MapView.SetScale(double) Method

Sets the scale of the current view.

public virtual System.Threading.Tasks.Task SetScale(double scale);

Parameters

scale System.Double

Returns

System.Threading.Tasks.Task

MapView.SetSpatialReference(SpatialReference) Method

Sets the dymaptic.GeoBlazor.Core.Components.Views.MapView.SpatialReference of the view.

public System.Threading.Tasks.Task SetSpatialReference(dymaptic.GeoBlazor.Core.Components.Geometries.SpatialReference spatialReference);

Parameters

spatialReference SpatialReference

Returns

System.Threading.Tasks.Task

MapView.SetZoom(double) Method

Sets the zoom level of the current view.

public virtual System.Threading.Tasks.Task SetZoom(double zoom);

Parameters

zoom System.Double

Returns

System.Threading.Tasks.Task

MapView.ShowPopup(PopupTemplate, Point) Method

Opens a Popup on a particular Point of the map view.

public System.Threading.Tasks.Task ShowPopup(dymaptic.GeoBlazor.Core.Components.Popups.PopupTemplate template, dymaptic.GeoBlazor.Core.Components.Geometries.Point location);

Parameters

template PopupTemplate

The PopupTemplate defining the Popup.

location Point

The Point on which to display the Popup.

Returns

System.Threading.Tasks.Task

MapView.ShowPopupWithGraphic(Graphic, PopupOptions) Method

Opens a Popup with a custom Graphic on a particular Point of the map view.

public System.Threading.Tasks.Task ShowPopupWithGraphic(dymaptic.GeoBlazor.Core.Components.Layers.Graphic graphic, dymaptic.GeoBlazor.Core.Components.Widgets.PopupOptions options);

Parameters

graphic Graphic

The Graphic to display in the Popup

options PopupOptions

A set of PopupOptions that define the position and visible elements of the Popup.

Returns

System.Threading.Tasks.Task

MapView.SolveServiceArea(string, double[], Symbol) Method

A custom method to find and display Service Areas around a given point.

public System.Threading.Tasks.Task SolveServiceArea(string serviceAreaUrl, double[] driveTimeCutOffs, dymaptic.GeoBlazor.Core.Components.Symbols.Symbol serviceAreaSymbol);

Parameters

serviceAreaUrl System.String

A url for a Service Area rest service.

driveTimeCutOffs System.Double[]

A collection of drivable distances, calculated in minutes

serviceAreaSymbol Symbol

The Symbol used to render the service areas.

Returns

System.Threading.Tasks.Task

MapView.ToMap(ScreenPoint) Method

Converts the given screen point to a map point. The screen point represents a point in terms of pixels relative to the top-left corner of the view.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Components.Geometries.Point> ToMap(dymaptic.GeoBlazor.Core.Events.ScreenPoint screenPoint);

Parameters

screenPoint ScreenPoint

Returns

System.Threading.Tasks.Task<Point>

MapView.ToScreen(Point) Method

Converts the given map point to a screen point. The screen point represents a point in terms of pixels relative to the top-left corner of the view.

public System.Threading.Tasks.Task<dymaptic.GeoBlazor.Core.Events.ScreenPoint> ToScreen(dymaptic.GeoBlazor.Core.Components.Geometries.Point mapPoint);

Parameters

mapPoint Point

Returns

System.Threading.Tasks.Task<ScreenPoint>

MapView.UnregisterChildComponent(MapComponent) Method

Undoes the “Registration” of a child with its parent.

public override System.Threading.Tasks.Task UnregisterChildComponent(dymaptic.GeoBlazor.Core.Components.MapComponent child);

Parameters

child MapComponent

The child to unregister

Returns

System.Threading.Tasks.Task

Remarks

This method is an implementation detail and should not be called directly by consumers. In future versions, this may be changed to an internal method.