MapLayerBuilder
Methods
DataSource(System.Action)
Defines the DataSource of the Map layer.
Parameters
configurator - System.Action<MapLayerDataSourceBuilder>
The action that configures of the DataSource settings.
RETURNS
Returns the current MapLayerBuilder instance.
Example
@(Html.Kendo().Map()
.Name("map")
.Layers(layers =>
{
layers.Add()
.Type(MapLayerType.Marker)
.DataSource(dataSource => dataSource.Read(read => read.Action("_StoreLocations", "Map")))
);
})
)
Shape(System.String)
Sets the marker shape. The available shapes are "pin" and "pinTarget".
Parameters
name - System.String
The name of the marker shape.
RETURNS
Returns the current MapLayerBuilder instance.
Example
@(Html.Kendo().Map()
.Name("map")
.Layers(layers =>
{
layers.Add().Shape("pin"));
})
)
Symbol(System.String)
Defines the bubble layer symbol type. The possible values are "circle" and "square".
Parameters
symbol - System.String
The value that configures the symbol type.
RETURNS
Returns the current MapLayerBuilder instance.
Example
@(Html.Kendo().Map()
.Name("map")
.Layers(layers =>
{
layers.Add()
.Type(MapLayerType.Bubble)
.Symbol("square");
})
)
SymbolHandler(System.String)
Sets a client-side function that will draw the bubble layer symbol type.
Parameters
handler - System.String
The name of the JavaScript function that will draw the symbol.
RETURNS
Returns the current MapLayerBuilder instance.
Example
@(Html.Kendo().Map()
.Name("map")
.Layers(layers =>
{
layers.Add()
.Type(MapLayerType.Bubble)
.SymbolHandler("getSymbolType");
})
)
<script>
function getSymbolType(data) {
...//return kendo.drawing.Shape
}
</script>
Tooltip(System.Action)
Configures the Tooltip component options for data-bound markers.
Parameters
configurator - System.Action<MapMarkerTooltipBuilder>
The action that configures the tooltip settings.
RETURNS
Returns the current MapLayerBuilder instance.
Example
@(Html.Kendo().Map()
.Name("map")
.Layers(layers =>
{
layers.Add()
.Type(MapLayerType.Marker)
.Tooltip(tooltip => tooltip.Content("City X"));
})
)
Attribution(System.String)
The attribution for the layer. Accepts valid HTML.
Parameters
value - System.String
The value for Attribution
RETURNS
Returns the current MapLayerBuilder instance.
AutoBind(System.Boolean)
If set to false the layer will not bind to the data source during initialization. In this case data binding will occur when the change event of the data source is fired. By default the widget will bind to the data source specified in the configuration.
Parameters
value - System.Boolean
The value for AutoBind
RETURNS
Returns the current MapLayerBuilder instance.
Extent(System.Double[])
Specifies the extent of the region covered by this layer. The layer will be hidden when the specified area is out of view.Accepts a four-element array that specifies the extent covered by this layer: North-West lat, longitude, South-East latitude, longitude.If not specified, the layer is always visible.
Parameters
value - System.Double[]
The value for Extent
RETURNS
Returns the current MapLayerBuilder instance.
Key(System.String)
The API key for the layer. Currently supported only for Bing (tm) tile layers.
Parameters
value - System.String
The value for Key
RETURNS
Returns the current MapLayerBuilder instance.
Culture(System.String)
The culture to be used for the bing map tiles.
Parameters
value - System.String
The value for Culture
RETURNS
Returns the current MapLayerBuilder instance.
LocationField(System.String)
The data item field which contains the marker (symbol) location. The field should be an array with two numbers - latitude and longitude in decimal degrees.Requires the dataSource option to be set.Only applicable to "marker" and "bubble" layers.
Parameters
value - System.String
The value for LocationField
RETURNS
Returns the current MapLayerBuilder instance.
TileSize(System.Double)
The size of the image tile in pixels.
Parameters
value - System.Double
The value for TileSize
RETURNS
Returns the current MapLayerBuilder instance.
TitleField(System.String)
The data item field which contains the marker title. Requires the dataSource option to be set.
Parameters
value - System.String
The value for TitleField
RETURNS
Returns the current MapLayerBuilder instance.
MaxSize(System.Double)
The maximum symbol size for bubble layer symbols.
Parameters
value - System.Double
The value for MaxSize
RETURNS
Returns the current MapLayerBuilder instance.
MinSize(System.Double)
The minimum symbol size for bubble layer symbols.
Parameters
value - System.Double
The value for MinSize
RETURNS
Returns the current MapLayerBuilder instance.
MaxZoom(System.Double)
The maximum zoom level at which to show this layer.
Parameters
value - System.Double
The value for MaxZoom
RETURNS
Returns the current MapLayerBuilder instance.
MinZoom(System.Double)
The minimum zoom level at which to show this layer.
Parameters
value - System.Double
The value for MinZoom
RETURNS
Returns the current MapLayerBuilder instance.
Opacity(System.Double)
The the opacity for the layer.
Parameters
value - System.Double
The value for Opacity
RETURNS
Returns the current MapLayerBuilder instance.
Subdomains(System.String[])
A list of subdomains to use for loading tiles. Alternating between different subdomains allows more requests to be executed in parallel.
Parameters
value - System.String[]
The value for Subdomains
RETURNS
Returns the current MapLayerBuilder instance.
Style(System.Action)
The default style for shapes.
Parameters
configurator - System.Action<MapLayerStyleSettingsBuilder>
The configurator for the style setting.
RETURNS
Returns the current instance of MapLayerBuilder .
UrlTemplate(System.String)
The URL template for tile layers. Template variables: x - X coordinate of the tile; y - Y coordinate of the tile; zoom - zoom level or subdomain - Subdomain for this tile. See subdomains.
Parameters
value - System.String
The value for UrlTemplate
RETURNS
Returns the current MapLayerBuilder instance.
UrlTemplateId(System.String)
The URL template for tile layers. Template variables: x - X coordinate of the tile; y - Y coordinate of the tile; zoom - zoom level or subdomain - Subdomain for this tile. See subdomains.
Parameters
templateId - System.String
The ID of the template element for UrlTemplate
RETURNS
Returns the current MapLayerBuilder instance.
UrlTemplateView(Microsoft.AspNetCore.Html.IHtmlContent)
The URL template for tile layers. Template variables: x - X coordinate of the tile; y - Y coordinate of the tile; zoom - zoom level or subdomain - Subdomain for this tile. See subdomains.
Parameters
templateView - Microsoft.AspNetCore.Html.IHtmlContent
The view that contains the template for UrlTemplate
RETURNS
Returns the current MapLayerBuilder instance.
UrlTemplateHandler(System.String)
The URL template for tile layers. Template variables: x - X coordinate of the tile; y - Y coordinate of the tile; zoom - zoom level or subdomain - Subdomain for this tile. See subdomains.
Parameters
templateHandler - System.String
The handler that returs the template for UrlTemplate
RETURNS
Returns the current MapLayerBuilder instance.
UrlTemplate(Kendo.Mvc.UI.Fluent.TemplateBuilder)
The URL template for tile layers. Template variables: x - X coordinate of the tile; y - Y coordinate of the tile; zoom - zoom level or subdomain - Subdomain for this tile. See subdomains.
Parameters
template - TemplateBuilder<TModel>
A Template component that configures the urltemplate.
RETURNS
Returns the current MapLayerBuilder instance.
ValueField(System.String)
The value field for bubble layer symbols. The data item field should be a number.
Parameters
value - System.String
The value for ValueField
RETURNS
Returns the current MapLayerBuilder instance.
ZIndex(System.Double)
The zIndex for this layer.Layers are normally stacked in declaration order (last one is on top).
Parameters
value - System.Double
The value for ZIndex
RETURNS
Returns the current MapLayerBuilder instance.
Type(Kendo.Mvc.UI.MapLayerType)
The layer type. Supported types are "tile", "bing", "shape", "marker" and "bubble".
Parameters
value - MapLayerType
The value for Type
RETURNS
Returns the current MapLayerBuilder instance.
ImagerySet(Kendo.Mvc.UI.MapLayersImagerySet)
The bing map tile types. Possible options.
Parameters
value - MapLayersImagerySet
The value for ImagerySet
RETURNS
Returns the current MapLayerBuilder instance.
Shape(Kendo.Mvc.UI.MapMarkersShape)
The marker shape. Supported shapes are "pin" and "pinTarget".
Parameters
value - MapMarkersShape
The value for Shape
RETURNS
Returns the current MapLayerBuilder instance.
Symbol(Kendo.Mvc.UI.MapSymbol)
The bubble layer symbol type. Supported symbols are "circle" and "square".
Parameters
value - MapSymbol
The value for Symbol
RETURNS
Returns the current MapLayerBuilder instance.