49 std::cout <<
TL(
"Another interrupt signal received, hard exit.") << std::endl;
52 std::cout <<
TL(
"Interrupt signal received, trying to exit gracefully.") << std::endl;
57 std::cout <<
"Step #" <<
SIMSTEP << std::endl;
76main(
int argc,
char** argv) {
111 if (std::string(e.what()) != std::string(
"Process Error") && std::string(e.what()) != std::string(
"")) {
119 }
catch (
const std::exception& e) {
120 if (std::string(e.what()) != std::string(
"")) {
SUMOTime string2time(const std::string &r)
convert string to SUMOTime
The simulated network and simulation perfomer.
static MSNet * getInstance()
Returns the pointer to the unique instance of MSNet (singleton).
SimulationState
Possible states of a simulation - running or stopped with different reasons.
@ SIMSTATE_LOADING
The simulation is loading.
static bool hasInstance()
Returns whether the network was already constructed.
const std::string generateStatistics(const SUMOTime start, const long now)
Writes performance output and running vehicle stats.
SimulationState simulate(SUMOTime start, SUMOTime stop)
Simulates from timestep start to stop.
static MsgHandler * getErrorInstance()
Returns the instance to add errors to.
virtual void inform(std::string msg, bool addType=true)
adds a new error to the list
static MsgHandler * getWarningInstance()
Returns the instance to add warnings to.
virtual void clear(bool resetInformed=true)
Clears information whether an error occurred previously and print aggregated message summary.
static void cleanupOnEnd()
Removes pending handler.
static MSNet * init(const bool isLibsumo=false)
A storage for options typed value containers)
void setApplicationName(const std::string &appName, const std::string &fullName)
Sets the application name.
std::string getString(const std::string &name) const
Returns the string-value of the named option (only for Option_String)
void setApplicationDescription(const std::string &appDesc)
Sets the application description.
static OptionsCont & getOptions()
Retrieves the options.
static void setArgs(int argc, char **argv)
Stores the command line arguments for later parsing.
static void closeAll(bool keepErrorRetrievers=false)
static long getCurrentMillis()
Returns the current time in milliseconds.
static void close()
Closes all of an applications subsystems.
static void close()
request termination of connection
static void init()
Initialises the xml-subsystem.
int main(int argc, char **argv)
void signalHandler(int signum)