traci.polygon
index
/build/buildd/sumo-0.15.0~dfsg/tools/traci/polygon.py

@file    polygon.py
@author  Michael Behrisch
@date    2011-03-16
@version $Id: polygon.py 11453 2011-11-02 09:40:25Z behrisch $
 
Python implementation of the TraCI interface.
 
SUMO, Simulation of Urban MObility; see http://sumo.sourceforge.net/
Copyright (C) 2011 DLR (http://www.dlr.de/) and contributors
All rights reserved

 
Modules
       
struct
traci.constants
traci

 
Functions
       
add(polygonID, shape, color, fill=False, polygonType='', layer=0)
getColor(polygonID)
getColor(string) -> (integer, integer, integer, integer)
 
.
getIDList()
getIDList() -> list(string)
 
Returns a list of all polygons in the network.
getShape(polygonID)
getShape(string) -> list((double, double))
 
.
getSubscriptionResults(polygonID=None)
getSubscriptionResults(string) -> dict(integer: <value_type>)
 
Returns the subscription results for the last time step and the given poi.
If no polygon id is given, all subscription results are returned in a dict.
If the polygon id is unknown or the subscription did for any reason return no data,
'None' is returned.
It is not possible to retrieve older subscription results than the ones
from the last time step.
getType(polygonID)
getType(string) -> string
 
.
remove(polygonID, layer=0)
setColor(polygonID, color)
setShape(polygonID, shape)
setType(polygonID, polygonType)
subscribe(polygonID, varIDs=(78,), begin=0, end=2147483647L)
subscribe(string, list(integer), double, double) -> None
 
Subscribe to one or more polygon values for the given interval.
A call to this method clears all previous subscription results.

 
Data
        subscriptionResults = {}