return true;
}
public static void main(String[] args) {
try {
CommandLineParser clp = createCmdLineParser();
clp.parseCmdLine(args);
if (!checkCmdLineSyntax(clp)) {
printUsage();
System.exit(2);
}
String lookAndFeel = null;
if (clp.isInArgsList(LOOK_AND_FEEL_PARAM)) {
lookAndFeel = clp.getParamArgument(LOOK_AND_FEEL_PARAM);
try {
UIManager.setLookAndFeel(lookAndFeel);
} catch (UnsupportedLookAndFeelException e) {
System.err.println(e.getMessage());
}
}
MainFrame frame = createMainFrame();
if (clp.isInArgsList(TEXT_FILE_PARAM)) {
frame.loadTextFile(new File(clp.getParamArgument(TEXT_FILE_PARAM)));
}
if (clp.isInArgsList(DATA_PATH_PARAM)) {
frame.setDataPath(clp.getParamArgument(DATA_PATH_PARAM));
} else {
String dataProp = System.getProperty(RelativePathResolver.UIMA_DATAPATH_PROP);
if (dataProp != null) {
frame.setDataPath(dataProp);
}
}
if (clp.isInArgsList(DESC_FILE_PARAM)) {
frame.loadAEDescriptor(new File(clp.getParamArgument(DESC_FILE_PARAM)));
}
if (clp.isInArgsList(EXECUTE_SWITCH)) {
frame.runAE(true);
}
} catch (Exception e) {
e.printStackTrace();
System.exit(1);