Advertisement
Guest User

Untitled

a guest
Jan 17th, 2012
67
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.79 KB | None | 0 0
  1.   public static void main(final String[] arguments) {
  2.     try {
  3.       setUp(arguments);
  4.  
  5.       timeRecorder.recordSimulationStartTime();
  6.       while (simulationController.simulationIsNotOver()) {
  7.         simulationController.advanceSimulationBySinglePhase();
  8.  
  9.        
  10.         trafficLightManager.applyTLSPrograms(
  11.             tlsOptimizer.createNewTLSPrograms(
  12.                 trafficLightManager.getCurrentPrograms(),
  13.                 simulationController.getLastPhaseTrafficInformation()));
  14.       }
  15.       timeRecorder.recordSimulationEndTime();
  16.  
  17.     } catch (Exception e) {
  18.       logException(e);
  19.     } finally {
  20.       try {
  21.         simulationController.stopSimulation();
  22.       } catch (Exception e) {
  23.         logException(e);
  24.       }
  25.     }
  26.  
  27.     logger.info("Simulation is over.");
  28.   }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement