@SuppressWarnings("static-access")
public AvroConvertCli()
{
Option helpOption = OptionBuilder.withLongOpt(HELP_OPT_NAME)
.withDescription("this help screen")
.create(HELP_OPT_CHAR);
Option inpFormatOption = OptionBuilder.withLongOpt(INPUT_FORMAT_OPT_NAME)
.withDescription("Input format: JSON, JSON_LINES, BINARY")
.hasArg()
.withArgName("format")
.create(INPUT_FORMAT_OPT_CHAR);
Option outFormatOption = OptionBuilder.withLongOpt(OUTPUT_FORMAT_OPT_NAME)
.withDescription("Output format: JSON, JSON_LINES, BINARY")
.hasArg()
.withArgName("format")
.create(OUTPUT_FORMAT_OPT_CHAR);
Option inpSchemaOption = OptionBuilder.withLongOpt(INPUT_SCHEMA_OPT_NAME)
.withDescription("Input schema file")
.hasArg()
.withArgName("file")
.create(INPUT_SCHEMA_OPT_CHAR);
Option outSchemaOption = OptionBuilder.withLongOpt(OUTPUT_SCHEMA_OPT_NAME)
.withDescription("Output schema file")
.hasArg()
.withArgName("file")
.create(OUTPUT_SCHEMA_OPT_CHAR);
Option inpFileOption = OptionBuilder.withLongOpt(INPUT_FILE_OPT_NAME)
.withDescription("input file name or - for STDIN")
.hasArg()
.withArgName("file | - ")
.create(INPUT_FILE_OPT_CHAR);
Option outFileOption = OptionBuilder.withLongOpt(OUTPUT_FILE_OPT_NAME)
.withDescription("output file name or - for STDOUT")
.hasArg()
.withArgName("file | - ")
.create(OUTPUT_FILE_OPT_CHAR);
Option verboseOption = OptionBuilder.withDescription("verbose; more occurrences increase verbosity")
.create(VERBOSE_OPT_CHAR);
_options.addOption(helpOption);
_options.addOption(inpFormatOption);
_options.addOption(outFormatOption);