Class SfMaps
Class implementation of Maps
Inheritance
Namespace: Com.Syncfusion.Maps
Assembly: Syncfusion.SfMaps.Android.dll
Syntax
public class SfMaps : FrameLayout
Constructors
SfMaps(Context)
Initializes a new instance of the SfMaps class.
Declaration
public SfMaps(Context context)
Parameters
Type | Name | Description |
---|---|---|
Android.Content.Context | context | To set context |
SfMaps(Context, IAttributeSet)
Initializes a new instance of the SfMaps class.
Declaration
public SfMaps(Context context, IAttributeSet attribute)
Parameters
Type | Name | Description |
---|---|---|
Android.Content.Context | context | To set the context |
Android.Util.IAttributeSet | attribute | To set the value for corresponding field |
SfMaps(Context, IAttributeSet, Int32)
Initializes a new instance of the SfMaps class.
Declaration
public SfMaps(Context context, IAttributeSet attribute, int style)
Parameters
Type | Name | Description |
---|---|---|
Android.Content.Context | context | To set the context |
Android.Util.IAttributeSet | attribute | To set the value for corresponding field |
System.Int32 | style | To set the value for respective field |
Properties
Adapter
Gets or sets the adapter
Declaration
public MapsAdapter Adapter { get; set; }
Property Value
Type |
---|
MapsAdapter |
BaseMapIndex
Gets or sets the base map index
Declaration
public int BaseMapIndex { get; set; }
Property Value
Type |
---|
System.Int32 |
EnablePanning
Gets or sets a value indicating whether to enable panning
Declaration
public bool EnablePanning { get; set; }
Property Value
Type |
---|
System.Boolean |
EnableZooming
Gets or sets a value indicating whether to enable zooming
Declaration
public bool EnableZooming { get; set; }
Property Value
Type |
---|
System.Boolean |
Layers
Gets or sets the collection of shape layer
Declaration
public ObservableCollection<MapLayer> Layers { get; set; }
Property Value
Type |
---|
System.Collections.ObjectModel.ObservableCollection<MapLayer> |
MaxZoom
Gets or sets maximum zoom value
Declaration
public float MaxZoom { get; set; }
Property Value
Type |
---|
System.Single |
MinZoom
Gets or sets minimum zoom value
Declaration
public float MinZoom { get; set; }
Property Value
Type |
---|
System.Single |
OSMType
Gets or sets a value indicating whether OSM type
Declaration
public bool OSMType { get; set; }
Property Value
Type |
---|
System.Boolean |
ShowTooltip
Gets or sets a value indicating whether to show tooltip
Declaration
public bool ShowTooltip { get; set; }
Property Value
Type |
---|
System.Boolean |
ZoomLevel
Gets or sets a value for zoom level
Declaration
public float ZoomLevel { get; set; }
Property Value
Type |
---|
System.Single |
Methods
Dispose(Boolean)
To dispose the objects
Declaration
protected override void Dispose(bool disposing)
Parameters
Type | Name | Description |
---|---|---|
System.Boolean | disposing | to get dispose |
OnSizeChanged(Int32, Int32, Int32, Int32)
This method is called size of map is changed
Declaration
protected override void OnSizeChanged(int w, int h, int oldw, int oldh)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | w | To set new width |
System.Int32 | h | To set new height |
System.Int32 | oldw | To set old width |
System.Int32 | oldh | To set old height |
Pan(PanPosition)
This method is used for panning
Declaration
public void Pan(PanPosition panPosition)
Parameters
Type | Name | Description |
---|---|---|
PanPosition | panPosition | To set the pan position |
Refresh()
This method is used to refresh map
Declaration
public void Refresh()
Zoom(Single)
This method is used fir zooming
Declaration
public void Zoom(float level)
Parameters
Type | Name | Description |
---|---|---|
System.Single | level | To set the zoom level |
ZoomIn()
This method is used for zoom in
Declaration
public void ZoomIn()
ZoomOut()
This method is used for zoom out
Declaration
public void ZoomOut()
Events
Tooltip
Event corresponding to tooltip drawing
Declaration
public event EventHandler<TooltipDrawingEventArgs> Tooltip
Event Type
Type |
---|
System.EventHandler<TooltipDrawingEventArgs> |
TooltipOpening
Declare the Tooltip opening event
Declaration
public event EventHandler<TooltipOpeningEventArgs> TooltipOpening
Event Type
Type |
---|
System.EventHandler<TooltipOpeningEventArgs> |