- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- java.lang.RuntimeException
-
- net.morimekta.terminal.args.ArgException
-
- All Implemented Interfaces:
Serializable
public class ArgException extends RuntimeException
Argument exception. Usually a result of the parsing, but may be caused by invalid initialization.- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ArgException(String format, Object... args)
ArgException(Throwable cause, String format, Object... args)
Deprecated, for removal: This API element is subject to removal in a future version.UseArgException(String, Object...)
instead.ArgException(ArgParser parser, String format, Object... args)
ArgException(ArgParser parser, Throwable cause, String format, Object... args)
Deprecated, for removal: This API element is subject to removal in a future version.UseArgException(ArgParser, String, Object...)
instead.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ArgParser
getParser()
-
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toString
-
-
-
-
Constructor Detail
-
ArgException
public ArgException(String format, Object... args)
- Parameters:
format
- String message format.args
- String format args.
-
ArgException
public ArgException(ArgParser parser, String format, Object... args)
- Parameters:
parser
- The parser where the exception occurred.format
- String message format.args
- String format args.
-
ArgException
@Deprecated(forRemoval=true, since="4.1.0") public ArgException(Throwable cause, String format, Object... args)
Deprecated, for removal: This API element is subject to removal in a future version.UseArgException(String, Object...)
instead.- Parameters:
cause
- Throwable cause of exception.format
- String message format.args
- String format args.
-
ArgException
@Deprecated(forRemoval=true, since="4.1.0") public ArgException(ArgParser parser, Throwable cause, String format, Object... args)
Deprecated, for removal: This API element is subject to removal in a future version.UseArgException(ArgParser, String, Object...)
instead.- Parameters:
parser
- The parser where the exception occurred.cause
- Throwable cause of exception.format
- String message format.args
- String format args.
-
-
Method Detail
-
getParser
public ArgParser getParser()
- Returns:
- The underlying parser, if any.
-
-