/** * The main routnie which creates the data structures for the Columbian * health-care system and executes the simulation for a specified time. * * @param args the command line arguments */ public static void Main(String[] args, ILog ilog) { logger = ilog; parseCmdLine(args); Village.initVillageStatic(); Village top = Village.createVillage(maxLevel, 0, true, 1); if (printMsgs) { logger.InfoFormat("Columbian Health Care Simulator\nWorking..."); } for (int i = 0; i < maxTime; i++) { top.simulate(); } Results r = top.getResults(); if (printResult) { logger.InfoFormat("# People treated: " + (int)r.totalPatients); logger.InfoFormat("Avg. length of stay: " + r.totalTime / r.totalPatients); logger.InfoFormat("Avg. # of hospitals visited: " + r.totalHospitals / r.totalPatients); } logger.InfoFormat("Done!"); }