Package com.beust.jcommander

Examples of com.beust.jcommander.JCommander.usage()


        .setProgramName("Splout Tablespaces Generator. Generates tablespaces, ready to be deployed to a Splout Cluster.");
    try {
      jComm.parse(args);
    } catch(Throwable t) {
      t.printStackTrace();
      jComm.usage();
      return -1;
    }

    if (parallelism <1) {
      System.err.println("Parallelism must be greater than 0.");
View Full Code Here


            throws ClassNotFoundException, InstantiationException, IllegalAccessException,
            IOException {
        Args parsedArgs = new Args();
        JCommander jc = new JCommander(parsedArgs, args);
        if (parsedArgs.help) {
            jc.usage();
            return;
        }
        Generator generator = new Generator();
        parsedArgs.processors.forEach(generator::addProcessor);
        generator.setDefaultTypes(parsedArgs.defaultTypes)
View Full Code Here

        CommandLineParams commandLineParams = new CommandLineParams();

        JCommander jCommander = new JCommander(commandLineParams, args);

        if (commandLineParams.help) {
            jCommander.usage();
            System.exit(1);
        }
       
        // default to src/main/webapp
        if (commandLineParams.paths.size() == 0) {
View Full Code Here

       
        File war = new File(path);
       
        if (!war.exists()) {
            System.err.println("The specified path \"" + path + "\" does not exist.");
            jCommander.usage();
            System.exit(1);
        }
       
        // Use the commandline context-path (or default)
        // warn if the contextPath doesn't start with a '/'. This causes issues serving content at the context root.
View Full Code Here

    try {
      jComm.parse(args);
    } catch(ParameterException e) {
      System.out.println(e.getMessage());
      System.out.println();
      jComm.usage();
      System.exit(-1);
    } catch(Throwable t) {
      t.printStackTrace();
      jComm.usage();
      System.exit(-1);
View Full Code Here

      System.out.println();
      jComm.usage();
      System.exit(-1);
    } catch(Throwable t) {
      t.printStackTrace();
      jComm.usage();
      System.exit(-1);
    }

    benchmarkTool.start();
    System.exit(0);
View Full Code Here

    jComm.setProgramName("Splout Page Counts example");
    try {
      jComm.parse(args);
    } catch(ParameterException e) {
      System.err.println(e.getMessage());
      jComm.usage();
      System.exit(-1);
    }

    boolean generate = !noGenerate; // just for clarifying
View Full Code Here

    boolean generate = !noGenerate; // just for clarifying

    if(generateTupleFiles && deploy) {
      System.err.println("Can't run a 'dry' TupleFile generation and deploy it.");
      jComm.usage();
      System.exit(-1);
    }
   
    Path outPath = new Path(outputPath);
    FileSystem outFs = outPath.getFileSystem(getConf());
View Full Code Here

    jComm.setProgramName("Splout Tablespace View Generator");
    try {
      jComm.parse(args);
    } catch(Throwable t) {
      t.printStackTrace();
      jComm.usage();
      return -1;
    }

    log.info("Parsing input parameters...");
View Full Code Here

    // because Schema is now optional (it can be derived from Cascading or Hive tables),
    // check that it is provided when using TEXT as input.
    if(this.inputType.equals(InputType.TEXT) && this.schema == null) {
      System.err.println("A Pangool Schema must be provided for parsing text files.");
      jComm.usage();
      return -1;
    }

    // all input types except Hive require input paths
    if(!this.inputType.equals(InputType.HIVE) && this.input == null) {
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.