Class: LeafletView

OSH.UI. LeafletView

new OSH.UI.LeafletView()

Example

var leafletMapView = new OSH.UI.LeafletView("",
[{
styler : pointMarker,
contextMenuId: circularContextMenuId,
name : "Android Phone GPS",
entityId : androidEntity.id
},
{
styler : new OSH.UI.Styler.Polyline({
locationFunc : {
dataSourceIds : [androidPhoneGpsDataSource.getId()],
handler : function(rec) {
return {
x : rec.lon,
y : rec.lat,
z : rec.alt
};
}
},
color : 'rgba(0,0,255,0.5)',
weight : 10,
opacity : .5,
smoothFactor : 1,
maxPoints : 200
}),
name : "Android Phone GPS Path",
entityId : androidEntity.id
}]
);

Extends

Methods

addPolyline(properties){string}

Name Type Description
properties
Returns:
Type Description
string

inherited addViewItem(viewItem)

Add viewItem to the view

Name Type Description
viewItem

attachTo($super, parentElement)

Name Type Description
$super
parentElement

beforeAddingItems($super, options)

Name Type Description
$super
options

inherited getDataSourcesId(){Array}

Returns:
Type Description
Array

getDefaultBaseLayers(){Object}

Returns:
Type Description
Object

inherited getDivId(){string|*}

Returns:
Type Description
string | *
Returns:
Type Description
string | *
Name Type Description
options
Name Type Description
$super
Name Type Description
$super

inherited selectDataView($super, dataSourcesIds, entitiesIds)

Should be called after receiving osh:SELECT_VIEW event

Name Type Description
$super
dataSourcesIds
entitiesIds

inherited setData(dataSourceId, data)

Name Type Description
dataSourceId
data

Show the view by removing display:none style if any.

Name Type Description
properties
Name Type Description
properties
Name Type Description
styler
Name Type Description
styler