new cercalia.Control.Traffic()
Extends
Members
-
staticcercalia.Control.Traffic.PoisCategories{Object.<string, Array.<string>>}
-
-
staticcercalia.Control.Traffic.SctDgtLevels{string}
-
Properties:
Name Type Default Description YELLOW
string yellow ORANGE
string orange RED
string red BLACK
string black ROADWORKS
string accident INCIDENCE
string incidences ACCIDENT
string accident
Methods
-
closePopups()
-
Close popups.
-
disable(option)
-
Disables the traffic layer option selected by parameter
Options:
cercalia.MapControls.TrafficOptions.LIVE
Live traffic
cercalia.MapControls.TrafficOptions.PREDICTED
Predicted traffic
cercalia.MapControls.TrafficOptions.CAMERAS
Live traffic cams (only Spain)
cercalia.MapControls.TrafficOptions.PKS
Highway location marker
cercalia.MapControls.TrafficOptions.WORKS
Road works (only Spain)Name Type Description option
string -
enable(option)
-
Enables the traffic layer option selected by parameter
Options:
cercalia.MapControls.TrafficOptions.LIVE
Live traffic
cercalia.MapControls.TrafficOptions.PREDICTED
Predicted traffic
cercalia.MapControls.TrafficOptions.CAMERAS
Live traffic cams (only Spain)
cercalia.MapControls.TrafficOptions.PKS
Highway location marker
cercalia.MapControls.TrafficOptions.WORKS
Road works (only Spain)Name Type Description option
string -
getClass(){string} inherited
-
Returns:
class
-
getElement(){HTMLElement} inherited
-
Obtain the control DOM element
Returns:
DOM Element
-
getGeojsonStrategy_(extent, resolution)
-
Name Type Description extent
Array.<number> resolution
number -
getName(){string} inherited
-
Returns the control name
Returns:
Control name
-
hide() inherited
-
Hide the control
-
isTrafficOptionEnabled(option){boolean}
-
Return boolean if parameter traffic option is enabled or not. Options:
cercalia.MapControls.TrafficOptions.LIVE
Live traffic
cercalia.MapControls.TrafficOptions.PREDICTED
Predicted traffic
cercalia.MapControls.TrafficOptions.CAMERAS
Live traffic cams (only Spain)
cercalia.MapControls.TrafficOptions.PKS
Highway location marker
cercalia.MapControls.TrafficOptions.WORKS
Road works (only Spain)Name Type Description option
string -
setTopBar(idTopBar)
-
Create the button in the tools topbar
Name Type Description idTopBar
string Div element ID where the control will be embedded
-
show() inherited
-
Shows the control
-
showAffectationPopup(feature)
-
Name Type Description feature
ol.Feature