62 #ifdef CHECK_MEMORY_LEAKS
64 #endif // CHECK_MEMORY_LEAKS
74 std::string file = oc.
getString(
"net-file");
76 throw ProcessError(
"Missing definition of network to load!");
80 +
"' could not be found.");
95 int main(
int argc,
char* argv[]) {
121 std::string statFile = oc.
getString(
"stat-file");
122 std::string routeFile = oc.
getString(
"output-file");
126 if (oc.
isSet(
"duration-d")) {
129 if (oc.
isSet(
"begin")) {
132 if (oc.
isSet(
"end")) {
144 if (std::string(e.what()) != std::string(
"Process Error") && std::string(e.what()) != std::string(
"")) {
150 }
catch (
const std::exception& e) {
151 if (std::string(e.what()) != std::string(
"")) {
163 std::cout <<
"Success." << std::endl;
static void init()
Initialises the xml-subsystem.
static MsgHandler * getErrorInstance()
Returns the instance to add errors to.
static void getOptions(bool loadConfig, int argc=0, char **argv=0)
Parses the command line arguments and loads the configuration optionally.
unsigned int getEdgeNo() const
Returns the number of edges thenetwork contains.
bool getBool(const std::string &name) const
Returns the boolean-value of the named option (only for Option_Bool)
void makeActivityTrips(int days=1, int beginTime=0, int endTime=0)
build activities and trips of the population and generate routes
static bool runParser(GenericSAXHandler &handler, const std::string &file)
Runs the given handler on the given file; returns if everything's ok.
static void close()
Closes all of an applications subsystems.
Interface for building instances of router-edges.
static OptionsCont & getOptions()
Retrieves the options.
static void initRandGlobal(MTRand *which=0)
Reads the given random number options and initialises the random number generator in accordance...
Central object handling City, Activities and Trips.
Interface for building instances of duarouter-edges.
std::string getString(const std::string &name) const
Returns the string-value of the named option (only for Option_String)
#define PROGRESS_FAILED_MESSAGE()
void setFileName(const std::string &name)
Sets the current file name.
bool processMetaOptions(bool missingOptions)
Checks for help and configuration output, returns whether we should exit.
static bool exists(std::string path)
Checks whether the given file exists.
#define PROGRESS_BEGIN_MESSAGE(msg)
std::string toString(const T &t, std::streamsize accuracy=OUTPUT_ACCURACY)
void loadNet(RONet &toFill, ROAbstractEdgeBuilder &eb)
Loads the network.
void addSeconds(int sec)
addition of seconds to the current moment
static void setValidation(bool enableValidation)
Enables or disables validation.
The router's network representation.
void inform(std::string msg, bool addType=true)
adds a new error to the list
A storage for options typed value containers)
void importInfoCity()
build the internal city
The handler that parses a SUMO-network for its usage in a router.
int getTime()
: returns the number of seconds from the beginning of the first day of simulation this includes ...
#define PROGRESS_DONE_MESSAGE()
int getInt(const std::string &name) const
Returns the int-value of the named option (only for Option_Integer)
#define WRITE_MESSAGE(msg)
static void initOutputOptions()
static void fillOptions()
Inserts options used by ActivityGen into the OptionsCont singleton.
bool isSet(const std::string &name, bool failOnNonExistant=true) const
Returns the information whether the named option is set.
int main(int argc, char *argv[])