Package org.apache.commons.cli2.util

Examples of org.apache.commons.cli2.util.HelpFormatter


  private static void parseCommand(String[] args)
  {
    Parser parser = new Parser();

    // configure a HelpFormatter
    HelpFormatter hf = new HelpFormatter();
    DefaultOptionBuilder oBuilder = new DefaultOptionBuilder();
    ;

    // configure a parser
    Parser p = new Parser();
View Full Code Here


public final class CommandLineUtil {
 
  private CommandLineUtil() { }
 
  public static void printHelp(Group group) {
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.print();
  }
View Full Code Here

    }
   
  }
 
  private static void printHelp(Group group) {
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.print();
  }
View Full Code Here

    }
   
  }
 
  private static void printHelp(Group group) {
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.print();
  }
View Full Code Here

public final class CommandLineUtil {
 
  private CommandLineUtil() { }
 
  public static void printHelp(Group group) {
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.print();
  }
View Full Code Here

    org.apache.commons.cli.HelpFormatter fmt = new org.apache.commons.cli.HelpFormatter();
    fmt.printHelp("<command> [Generic Options] [Job-Specific Options]",
        "Generic Options:", ops, "");
   
    PrintWriter pw = new PrintWriter(System.out);
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.setPrintWriter(pw);
    formatter.printHelp();
    formatter.setFooter("Specify HDFS directories while running on hadoop; else specify local file system directories");
    formatter.printFooter();

    pw.flush();
  }
View Full Code Here

    org.apache.commons.cli.HelpFormatter fmt = new org.apache.commons.cli.HelpFormatter();
    fmt.printHelp("<command> [Generic Options] [Job-Specific Options]",
        "Generic Options:", ops, "");

    PrintWriter pw = new PrintWriter(System.out);
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.setPrintWriter(pw);
    formatter.setException(oe);
    formatter.printHelp();
    pw.flush();
  }
View Full Code Here

    Parser parser = new Parser();
    parser.setHelpOption(help);
    parser.setHelpTrigger("--help");
    parser.setGroup(normalArgs);
    parser.setHelpFormatter(new HelpFormatter(" ", "", " ", 130));
    CommandLine cmdLine = parser.parseAndHelp(args);

    if (cmdLine == null) {
      return false;
    }
View Full Code Here

    Parser parser = new Parser();
    parser.setHelpOption(help);
    parser.setHelpTrigger("--help");
    parser.setGroup(normalArgs);
    parser.setHelpFormatter(new HelpFormatter(" ", "", " ", 130));
    CommandLine cmdLine = parser.parseAndHelp(args);

    if (cmdLine == null) {
      return false;
    }
View Full Code Here

  public static void main(String[] args) throws Exception {
    new SequenceFileDumper().run(args);
  }

  private static void printHelp(Group group) {
    HelpFormatter formatter = new HelpFormatter();
    formatter.setGroup(group);
    formatter.print();
  }
View Full Code Here

TOP

Related Classes of org.apache.commons.cli2.util.HelpFormatter

Copyright © 2018 www.massapicom. 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.