List of usage examples for org.apache.commons.cli MissingOptionException toString
public String toString()
From source file:jamm.tools.JammCleaner.java
/** * Our main method/*from ww w . j a v a2s . c o m*/ * * @param argv command line arguments */ public static final void main(String argv[]) { Options opts = getOptions(); CommandLine cmdl = null; Parser parser = new GnuParser(); boolean sane = true; BasicConfigurator.configure(); try { cmdl = parser.parse(opts, argv); } catch (MissingOptionException e) { LOG.error("Missing required options." + e.toString()); sane = false; } catch (MissingArgumentException e) { LOG.error("Missing required Arguments." + e.toString()); sane = false; } catch (ParseException e) { LOG.error("Error parsing command line", e); sane = false; } // Load properties first loadProperties(); // Allow command line args to override properties file parseArgs(opts, cmdl); sane = sane && sanityCheck(); if (!sane) { printHelp(opts); System.exit(1); } AccountCleaner ac = new AccountCleaner(); ac.cleanUp(); DomainCleaner dc = new DomainCleaner(); dc.cleanUp(); }