argumentsList.add(0, "start");
arguments = argumentsList.toArray(new String[argumentsList.size()]);
}
}
JCommander commander = new JCommander();
ObfuscateOptions obfuscateOptions = new ObfuscateOptions();
commander.addCommand("obfuscate", obfuscateOptions);
StartOptions startOptions = new StartOptions();
commander.addCommand("start", startOptions);
StopOptions stopOptions = new StopOptions();
commander.addCommand("stop", stopOptions);
CheckConfigOptions checkConfigOptions = new CheckConfigOptions();
commander.addCommand("checkConfig", checkConfigOptions);
commander.parse(arguments);
switch (commander.getParsedCommand()) {
case "start":
startTc(startOptions);
break;
case "stop":
stopTc(stopOptions);
break;
case "obfuscate":
ObfuscateUtil.obfuscate(obfuscateOptions);
break;
case "checkConfig":
CheckConfig.check(checkConfigOptions);
break;
default:
commander.usage();
break;
}
}