Example usage for org.apache.commons.cli Option Option

List of usage examples for org.apache.commons.cli Option Option

Introduction

In this page you can find the example usage for org.apache.commons.cli Option Option.

Prototype

public Option(String opt, String longOpt, boolean hasArg, String description) throws IllegalArgumentException 

Source Link

Document

Creates an Option using the specified parameters.

Usage

From source file:com.netscape.cmstools.kra.KRAKeyFindCLI.java

public void createOptions() {
    Option option = new Option(null, "clientKeyID", true, "Unique client key identifier");
    option.setArgName("client key ID");
    options.addOption(option);/*  ww w  .j  a va  2 s  .  c  om*/

    option = new Option(null, "status", true, "Status");
    option.setArgName("status");
    options.addOption(option);

    option = new Option(null, "maxResults", true, "Maximum results");
    option.setArgName("max results");
    options.addOption(option);

    option = new Option(null, "maxTime", true, "Maximum time");
    option.setArgName("max time");
    options.addOption(option);

    option = new Option(null, "start", true, "Page start");
    option.setArgName("start");
    options.addOption(option);

    option = new Option(null, "size", true, "Page size");
    option.setArgName("size");
    options.addOption(option);

    option = new Option(null, "realm", true, "Realm");
    option.setArgName("realm");
    options.addOption(option);
}

From source file:com.netscape.cmstools.tps.connector.ConnectorShowCLI.java

public void createOptions() {
    Option option = new Option(null, "output", true, "Output file to store connector properties.");
    option.setArgName("file");
    options.addOption(option);/*w w  w . j  av  a  2s.c  o  m*/
}

From source file:com.alibaba.rocketmq.tools.command.message.QueryMsgByOffsetSubCommand.java

@Override
public Options buildCommandlineOptions(Options options) {
    Option opt = new Option("t", "topic", true, "topic name");
    opt.setRequired(true);/*from   w ww .  j  a  v  a 2  s.  co m*/
    options.addOption(opt);

    opt = new Option("b", "brokerName", true, "Broker Name");
    opt.setRequired(true);
    options.addOption(opt);

    opt = new Option("i", "queueId", true, "Queue Id");
    opt.setRequired(true);
    options.addOption(opt);

    opt = new Option("o", "offset", true, "Queue Offset");
    opt.setRequired(true);
    options.addOption(opt);

    return options;
}

From source file:com.netscape.cmstools.tps.cert.TPSCertFindCLI.java

public void createOptions() {
    Option option = new Option(null, "token", true, "Token ID");
    option.setArgName("ID");
    options.addOption(option);//w w w .  j a  va  2 s.c  om

    option = new Option(null, "start", true, "Page start");
    option.setArgName("start");
    options.addOption(option);

    option = new Option(null, "size", true, "Page size");
    option.setArgName("size");
    options.addOption(option);
}

From source file:com.opengamma.bbg.component.BloombergTimeSeriesUpdateTool.java

@Override
protected Options createOptions(boolean mandatoryConfigResource) {
    Options options = super.createOptions(mandatoryConfigResource);
    options.addOption(new Option("r", "reload", false, "Reload complete time series"));
    return options;
}

From source file:com.alibaba.rocketmq.tools.command.consumer.ConsumeStatsSubCommand.java

@Override
public Options buildCommandlineOptions(Options options) {
    Option opt = new Option("g", "groupName", true, "consumer group name");
    opt.setRequired(true);/*w ww .  ja v a2s. c  om*/
    options.addOption(opt);

    return options;
}

From source file:com.alibaba.rocketmq.tools.command.consumer.DeleteSubscriptionGroupCommand.java

@Override
public Options buildCommandlineOptions(Options options) {
    Option opt = new Option("b", "brokerAddr", true, "delete subscription group from which broker");
    opt.setRequired(false);/*from  w ww  . j  a  v  a  2s  .  c  om*/
    options.addOption(opt);

    opt = new Option("c", "clusterName", true, "delete subscription group from which cluster");
    opt.setRequired(false);
    options.addOption(opt);

    opt = new Option("g", "groupName", true, "subscription group name");
    opt.setRequired(true);
    options.addOption(opt);

    return options;
}

From source file:com.netscape.cmstools.tps.profile.ProfileAddCLI.java

public void createOptions() {
    Option option = new Option(null, "input", true, "Input file containing profile properties.");
    option.setArgName("file");
    option.setRequired(true);//from  www  .  ja va  2 s .  c o m
    options.addOption(option);
}

From source file:com.netscape.cmstools.pkcs12.PKCS12ImportCLI.java

public void createOptions() {
    Option option = new Option(null, "pkcs12-file", true, "PKCS #12 file");
    option.setArgName("path");
    options.addOption(option);/*  w  w  w  .  j a  v  a 2 s  . c o  m*/

    option = new Option(null, "pkcs12-password", true, "PKCS #12 password");
    option.setArgName("password");
    options.addOption(option);

    option = new Option(null, "pkcs12-password-file", true, "PKCS #12 password file");
    option.setArgName("path");
    options.addOption(option);

    options.addOption(null, "no-trust-flags", false, "Do not include trust flags");
    options.addOption(null, "overwrite", false, "Overwrite existing certificates");

    options.addOption("v", "verbose", false, "Run in verbose mode.");
    options.addOption(null, "debug", false, "Run in debug mode.");
    options.addOption(null, "help", false, "Show help message.");
}

From source file:com.netscape.cmstools.pkcs7.PKCS7CertFindCLI.java

public void createOptions() {
    Option option = new Option(null, "pkcs7-file", true, "PKCS #7 file");
    option.setArgName("path");
    options.addOption(option);//from  w w  w .  j  ava2 s .c  o  m

    options.addOption("v", "verbose", false, "Run in verbose mode.");
    options.addOption(null, "debug", false, "Run in debug mode.");
    options.addOption(null, "help", false, "Show help message.");
}