From: <mk...@us...> - 2003-09-16 06:57:35
|
Update of /cvsroot/csp/APPLICATIONS/CSPSim/Bin In directory sc8-pr-cvs1:/tmp/cvs-serv15155/Bin Modified Files: Tag: systems CSPSim.py Log Message: Index: CSPSim.py =================================================================== RCS file: /cvsroot/csp/APPLICATIONS/CSPSim/Bin/CSPSim.py,v retrieving revision 1.11 retrieving revision 1.11.2.1 diff -C2 -d -r1.11 -r1.11.2.1 *** CSPSim.py 16 Aug 2003 10:23:12 -0000 1.11 --- CSPSim.py 16 Sep 2003 06:57:30 -0000 1.11.2.1 *************** *** 46,49 **** --- 46,50 ---- print " --log=classes set the logging classes" print " --slog=level set the simdata logging level" + print " --dump-data show the contents of sim.dar" print " --help help message" *************** *** 92,100 **** def compileData(args): datapath = CSP.getDataPath() cachepath = CSP.getCachePath() dar = os.path.join(cachepath, "sim.dar") ! XML = os.path.join(datapath, "XML") CSP.csplog().setLogLevels(CSP.CSP_ALL, SimData.LOG_ALERT) #print "compile %s %s" % (XML, dar) --- 93,113 ---- + def dumpData(args): + cachepath = CSP.getCachePath() + dar = os.path.join(cachepath, "sim.dar") + for arg in args: + if arg.startswith('--dump-data='): + dar = arg[12:] + archive = SimData.DataArchive(dar, 1) + archive.dump() + archive.getObject("sim:terrain.balkan") + archive.getObject("sim:theater.balkan") + + def compileData(args): datapath = CSP.getDataPath() cachepath = CSP.getCachePath() dar = os.path.join(cachepath, "sim.dar") ! XML = os.path.join(cachepath, "XML") CSP.csplog().setLogLevels(CSP.CSP_ALL, SimData.LOG_ALERT) #print "compile %s %s" % (XML, dar) *************** *** 220,223 **** --- 233,241 ---- if arg == '--compile-data': action = compileData + elif arg == '--dump-data': + action = dumpData + elif arg.startswith('--dump-data='): + action = dumpData + other_args.append(arg) elif arg in ("--help", "-h", "-help"): if action == None: |