Reference Source
public class | source

MapRealtime

Extends:

L~L.Realtime → MapRealtime

Realtime track class

Constructor Summary

Public Constructor
public

constructor(src: String, options: Object)

Constructor

Method Summary

Public Methods
public

addToMapView(mapview: MapView): Null

Add to the mapview

public

Is getting the data

public

Remove from mapview

public

setFollow(flag: Boolean): Null

Set following

public

start(): Null

Start getting data

public

stop(): Null

Stop getting data

Public Constructors

public constructor(src: String, options: Object) source

Constructor

Params:

NameTypeAttributeDescription
src String

Url or null

options Object

Config params

options.interval Number

Sets the time interval for updates in milliseconds.

options.is_init_popup Boolean

Whether popup info box at the beginning.

options.is_show_log Boolean

Whether the log is displayed in the background.

options.popup_label String

The title of the pop-up box.

options.popup_img String

The path of the image of the pop-up box.

options.style Object

Track style.

options.extraIcon Object

Advanced icon options.

options.icon Object

Basic ICONS options, if set extraIcon will ignore this setting.

options.max_track_number Number

The max number of points to be displayed.

options.label_latlng String

The labels of latitude and longitude.

options.label_latlng_precision Number

Precision setting of latitude and longitude.

options.tooltipOffset [Number, Number]

The offset of the prompt box. ([0, -24])

options.popupOffset [Number, Number]

The offset of the pop-up box. ([0, 0])

Public Methods

public addToMapView(mapview: MapView): Null source

Add to the mapview

Params:

NameTypeAttributeDescription
mapview MapView

mapview object

Return:

Null

public isRunning(): Boolean source

Is getting the data

Return:

Boolean

public removeFromMapView(): Null source

Remove from mapview

Return:

Null

public setFollow(flag: Boolean): Null source

Set following

Params:

NameTypeAttributeDescription
flag Boolean

If set to true, the screen will follow

Return:

Null

public start(): Null source

Start getting data

Return:

Null

public stop(): Null source

Stop getting data

Return:

Null