Examples of ArgumentParserImpl


Examples of net.sourceforge.argparse4j.internal.ArgumentParserImpl

     *            disable reading arguments from file.
     * @return ArgumentParser object.
     */
    public static ArgumentParser newArgumentParser(String prog,
            boolean addHelp, String prefixChars, String fromFilePrefix) {
        return new ArgumentParserImpl(prog, addHelp, prefixChars,
                fromFilePrefix, cjkWidthHack_
                        && cjkWidthLangs_.contains(Locale.getDefault()
                                .getLanguage()) ? new CJKTextWidthCounter()
                        : new ASCIITextWidthCounter());
    }
View Full Code Here

Examples of net.sourceforge.argparse4j.internal.ArgumentParserImpl

public class ArgumentParsersTest {

    @Test
    public void testNewArgumentParser() {
        ArgumentParserImpl ap = (ArgumentParserImpl) ArgumentParsers
                .newArgumentParser("prog", false, "+", "@");
        assertEquals("prog", ap.getProg());
        assertEquals("+", ap.getPrefixChars());
        assertEquals("@", ap.getFromFilePrefixChars());
        // Check +h can be added because addHelp is false
        ap.addArgument("+h");
    }
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.