Top Description Constructors Methods
joptsimple

pack-priv Class NoArgumentOptionSpec

extends AbstractOptionSpec<Void>
Class Inheritance
Known Direct Subclasses
joptsimple.OptionSpecBuilder
Imports
java.util.List

A specification for an option that does not accept arguments.
Author
Paul Holser

Constructor Summary

AccessConstructor and Description
pack-priv
pack-priv
NoArgumentOptionSpec(List<String> options, String description)

Method Summary

Modifier and TypeMethod and Description
public boolean
public String
argumentDescription()

Implements joptsimple.OptionDescriptor.argumentDescription.

Gives a short description of the option's argument.
public String
argumentTypeIndicator()

Implements joptsimple.OptionDescriptor.argumentTypeIndicator.

Gives an indication of the expected type of the option's argument.
protected Void
public List<Void>
defaultValues()

Implements joptsimple.OptionDescriptor.defaultValues.

What values will the option take if none are specified on the command line?
pack-priv void
handleOption(OptionParser parser, ArgumentList arguments, OptionSet detectedOptions, String detectedArgument)

Implements abstract joptsimple.AbstractOptionSpec.handleOption.

public boolean
isRequired()

Implements joptsimple.OptionDescriptor.isRequired.

Is this option required on a command line?
public boolean
Inherited from joptsimple.AbstractOptionSpec:
argumentTypeIndicatorFromconvertWithdescriptionequalsforHelphashCodeisForHelpoptionsrepresentsNonOptionstoStringvaluevalues

Constructor Detail

NoArgumentOptionSpecback to summary
pack-priv NoArgumentOptionSpec(String option)
NoArgumentOptionSpecback to summary
pack-priv NoArgumentOptionSpec(List<String> options, String description)

Method Detail

acceptsArgumentsback to summary
public boolean acceptsArguments()

Implements joptsimple.OptionDescriptor.acceptsArguments.

Doc from joptsimple.OptionDescriptor.acceptsArguments.

Does this option accept arguments?

Returns:boolean

whether the option accepts arguments

argumentDescriptionback to summary
public String argumentDescription()

Implements joptsimple.OptionDescriptor.argumentDescription.

Doc from joptsimple.OptionDescriptor.argumentDescription.

Gives a short description of the option's argument.

Returns:String

a description for the option's argument

argumentTypeIndicatorback to summary
public String argumentTypeIndicator()

Implements joptsimple.OptionDescriptor.argumentTypeIndicator.

Doc from joptsimple.OptionDescriptor.argumentTypeIndicator.

Gives an indication of the expected type of the option's argument.

Returns:String

a description for the option's argument type

convertback to summary
protected Void convert(String argument)

Implements abstract joptsimple.AbstractOptionSpec.convert.

Annotations
@Override
defaultValuesback to summary
public List<Void> defaultValues()

Implements joptsimple.OptionDescriptor.defaultValues.

Doc from joptsimple.OptionDescriptor.defaultValues.

What values will the option take if none are specified on the command line?

Returns:List<Void>

any default values for the option

handleOptionback to summary
pack-priv void handleOption(OptionParser parser, ArgumentList arguments, OptionSet detectedOptions, String detectedArgument)

Implements abstract joptsimple.AbstractOptionSpec.handleOption.

Annotations
@Override
isRequiredback to summary
public boolean isRequired()

Implements joptsimple.OptionDescriptor.isRequired.

Doc from joptsimple.OptionDescriptor.isRequired.

Is this option required on a command line?

Returns:boolean

whether the option is required

requiresArgumentback to summary
public boolean requiresArgument()

Implements joptsimple.OptionDescriptor.requiresArgument.

Doc from joptsimple.OptionDescriptor.requiresArgument.

Does this option require an argument?

Returns:boolean

whether the option requires an argument