traci
index
/build/sumo-O79YsN/sumo-0.25.0+dfsg1/tools/traci/__init__.py

@file    __init__.py
@author  Michael Behrisch
@author  Lena Kalleske
@author  Mario Krumnow
@author  Daniel Krajzewicz
@author  Jakob Erdmann
@date    2008-10-09
@version $Id: __init__.py 18717 2015-08-25 12:39:40Z behrisch $
 
Python implementation of the TraCI interface.
 
SUMO, Simulation of Urban MObility; see http://sumo.dlr.de/
Copyright (C) 2008-2015 DLR (http://www.dlr.de/) and contributors
 
This file is part of SUMO.
SUMO is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 3 of the License, or
(at your option) any later version.

 
Package Contents
       
areal
constants
edge
gui
inductionloop
junction
lane
multientryexit
person
poi
polygon
rebuildConstants
route
simulation
traciToHex
trafficlights
vehicle
vehicletype

 
Classes
       
exceptions.Exception(exceptions.BaseException)
FatalTraCIError
TraCIException
Message
Storage
SubscriptionResults

 
class FatalTraCIError(exceptions.Exception)
    Exception class for all TraCI errors which do not allow for continuation
 
 
Method resolution order:
FatalTraCIError
exceptions.Exception
exceptions.BaseException
__builtin__.object

Methods defined here:
__init__(self, desc)

Data descriptors defined here:
__weakref__
list of weak references to the object (if defined)

Data and other attributes inherited from exceptions.Exception:
__new__ = <built-in method __new__ of type object>
T.__new__(S, ...) -> a new object with type S, a subtype of T

Methods inherited from exceptions.BaseException:
__delattr__(...)
x.__delattr__('name') <==> del x.name
__getattribute__(...)
x.__getattribute__('name') <==> x.name
__getitem__(...)
x.__getitem__(y) <==> x[y]
__getslice__(...)
x.__getslice__(i, j) <==> x[i:j]
 
Use of negative indices is not supported.
__reduce__(...)
__repr__(...)
x.__repr__() <==> repr(x)
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value
__setstate__(...)
__str__(...)
x.__str__() <==> str(x)
__unicode__(...)

Data descriptors inherited from exceptions.BaseException:
__dict__
args
message

 
class Message
    A named tuple for internal usage.
 
Simple "struct" for the composed message string
together with a list of TraCI commands which are inside.
 
  Data and other attributes defined here:
queue = []
string = ''

 
class Storage
     Methods defined here:
__init__(self, content)
printDebug(self)
read(self, format)
readDouble(self)
readInt(self)
readLength(self)
readShape(self)
readString(self)
readStringList(self)
ready(self)

 
class SubscriptionResults
     Methods defined here:
__init__(self, valueFunc)
__repr__(self)
add(self, refID, varID, data)
addContext(self, refID, domain, objID, varID=None, data=None)
get(self, refID=None)
getContext(self, refID=None)
reset(self)

 
class TraCIException(exceptions.Exception)
    Exception class for all TraCI errors which keep the connection intact
 
 
Method resolution order:
TraCIException
exceptions.Exception
exceptions.BaseException
__builtin__.object

Methods defined here:
__init__(self, command, errorType, desc)
getCommand(self)
getType(self)

Data descriptors defined here:
__weakref__
list of weak references to the object (if defined)

Data and other attributes inherited from exceptions.Exception:
__new__ = <built-in method __new__ of type object>
T.__new__(S, ...) -> a new object with type S, a subtype of T

Methods inherited from exceptions.BaseException:
__delattr__(...)
x.__delattr__('name') <==> del x.name
__getattribute__(...)
x.__getattribute__('name') <==> x.name
__getitem__(...)
x.__getitem__(y) <==> x[y]
__getslice__(...)
x.__getslice__(i, j) <==> x[i:j]
 
Use of negative indices is not supported.
__reduce__(...)
__repr__(...)
x.__repr__() <==> repr(x)
__setattr__(...)
x.__setattr__('name', value) <==> x.name = value
__setstate__(...)
__str__(...)
x.__str__() <==> str(x)
__unicode__(...)

Data descriptors inherited from exceptions.BaseException:
__dict__
args
message

 
Functions
       
close()
getParameterAccessors(cmdGetID, cmdSetID)
getVersion()
init(port=8813, numRetries=10, host='localhost', label='default')
isEmbedded()
simulationStep(step=0)
Make a simulation step and simulate up to the given millisecond in sim time.
If the given value is 0 or absent, exactly one step is performed.
Values smaller than or equal to the current sim time result in no action.
switch(label)

 
Data
        print_function = _Feature((2, 6, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 65536)