title: Can Apache Commons CLI options parser ignore unknown command-line options?
body: <p>I am writing a Java application that takes command line arguments which are processed using Apache Commons CLI with the GnuParser.  For reasons that are not interesting to get into, I would like it to silently ignore unknown command line options instead of throwing a ParseException but I don't see a way to do that.  I see that there is a stopAtNonOption boolean option on GnuParser.parse() but what I want is more like ignoreAtNonOption where it will keep processing options after encountering an unknown token.</p>
  
  <p>I could implement my own parser to accomplish this but I'm surprised there isn't this functionality built in so I thought I'd check before going down that road.</p>
  
  <p>Example code for what I'm talking about:</p>
  
  <pre><code>try {
    CommandLine commandLine = parser.parse(options, args);
    // stopAtNonOption set to true (below) is also not what I want
    // CommandLine commandLine = parser.parse(options, args, true);
  } catch (ParseException e) {
    LOG.error("error parsing arguments", e);
    throw new RuntimeException(e);
  }
  </code></pre>