/** * Computes the routes saving them */ void computeRoutes(RONet &net, ROLoader &loader, OptionsCont &oc) { // initialise the loader loader.openRoutes(net); // prepare the output try { net.openOutput(oc.getString("output"), false); } catch (IOError &e) { throw e; } // build the router ROJTRRouter router(net, oc.getBool("continue-on-unbuild"), oc.getBool("accept-all-destinations")); // the routes are sorted - process stepwise if (!oc.getBool("unsorted")) { loader.processRoutesStepWise(string2time(oc.getString("begin")), string2time(oc.getString("end")), net, router); } // the routes are not sorted: load all and process else { loader.processAllRoutes(string2time(oc.getString("begin")), string2time(oc.getString("end")), net, router); } // end the processing net.closeOutput(); }