Serializable
CommandLine.MaxValuesExceededException
, CommandLine.MissingParameterException
, CommandLine.MissingTypeConverterException
, CommandLine.MutuallyExclusiveArgsException
, CommandLine.OverwrittenOptionException
, CommandLine.UnmatchedArgumentException
public static class CommandLine.ParameterException extends CommandLine.PicocliException
Constructor | Description |
---|---|
ParameterException(CommandLine commandLine,
String msg) |
Constructs a new ParameterException with the specified CommandLine and error message.
|
ParameterException(CommandLine commandLine,
String msg,
Throwable t) |
Constructs a new ParameterException with the specified CommandLine and error message.
|
ParameterException(CommandLine commandLine,
String msg,
Throwable t,
CommandLine.Model.ArgSpec argSpec,
String value) |
Constructs a new ParameterException with the specified CommandLine and error message.
|
ParameterException(CommandLine commandLine,
String msg,
CommandLine.Model.ArgSpec argSpec,
String value) |
Constructs a new ParameterException with the specified CommandLine and error message.
|
Modifier and Type | Method | Description |
---|---|---|
CommandLine.Model.ArgSpec |
getArgSpec() |
Returns the
ArgSpec object for the (sub)command whose input could not be parsed. |
CommandLine |
getCommandLine() |
Returns the
CommandLine object for the (sub)command whose input could not be parsed. |
String |
getValue() |
Returns the
String value for the (sub)command whose input could not be parsed. |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
public ParameterException(CommandLine commandLine, String msg)
commandLine
- the command or subcommand whose input was invalidmsg
- describes the problempublic ParameterException(CommandLine commandLine, String msg, Throwable t)
commandLine
- the command or subcommand whose input was invalidmsg
- describes the problemt
- the throwable that caused this ParameterExceptionpublic ParameterException(CommandLine commandLine, String msg, Throwable t, CommandLine.Model.ArgSpec argSpec, String value)
commandLine
- the command or subcommand whose input was invalidmsg
- describes the problemt
- the throwable that caused this ParameterExceptionargSpec
- the argSpec that caused this ParameterExceptionvalue
- the value that caused this ParameterExceptionpublic ParameterException(CommandLine commandLine, String msg, CommandLine.Model.ArgSpec argSpec, String value)
commandLine
- the command or subcommand whose input was invalidmsg
- describes the problemargSpec
- the argSpec that caused this ParameterExceptionvalue
- the value that caused this ParameterExceptionpublic CommandLine getCommandLine()
CommandLine
object for the (sub)command whose input could not be parsed.CommandLine
object for the (sub)command where parsing failed.public CommandLine.Model.ArgSpec getArgSpec()
ArgSpec
object for the (sub)command whose input could not be parsed.ArgSpec
object for the (sub)command where parsing failed.public String getValue()
String
value for the (sub)command whose input could not be parsed.String
value for the (sub)command where parsing failed.Copyright © 2017–2019. All rights reserved.