Package org.apache.commons.cli2

Examples of org.apache.commons.cli2.Argument.canProcess()


                    // TODO: why do we iterate over all anonymous arguments?
                    // canProcess will always return true?
                    for (final Iterator i = anonymous.iterator(); i.hasNext();) {
                        final Argument argument = (Argument) i.next();

                        if (argument.canProcess(commandLine, arguments)) {
                            argument.process(commandLine, arguments);
                        }
                    }
                } // [END argument is NOT anonymous
            } // [END option NOT found
View Full Code Here


        // check if bursting is required
        for (final Iterator iter = tailMap.values().iterator(); iter.hasNext();) {
            final Option option = (Option) iter.next();

            if (option.canProcess(commandLine, arg)) {
                return true;
            }
        }

        if (commandLine.looksLikeOption(arg)) {
View Full Code Here

                    boolean foundMemberOption = false;

                    for (Iterator i = values.iterator(); i.hasNext() && !foundMemberOption;) {
                        final Option option = (Option) i.next();

                        if (option.canProcess(commandLine, arg)) {
                            foundMemberOption = true;
                            arguments.previous();
                            option.process(commandLine, arguments);
                        }
                    }
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.