google.maps.TrafficLayer class
A traffic layer.
This class extends MVCObject.
Constructor
TrafficLayer([opts])
Parameters:
- opts: TrafficLayerOptions optional
A layer that displays current road traffic.
Methods
getMap()
Parameters: None
Return Value: Map
Returns the map on which this layer is displayed.
setMap(map)
Parameters:
- map: Map
Return Value: None
Renders the layer on the specified map. If map is set to null, the layer will be removed.
setOptions(options)
Parameters:
- options: TrafficLayerOptions
Return Value: None