public static enum InvalidUsage.Cause extends java.lang.Enum<InvalidUsage.Cause>
| Enum Constant and Description |
|---|
INVALID_ARGUMENT
When input is invalid
e.g.
|
MISSING_ARGUMENT
When input is valid but not enough
e.g.
|
MISSING_PART_OF_ARGUMENT
When input is valid but not enough (part of argument is missing)
e.g.
|
TOO_MANY_ARGUMENTS
When input is valid but too much
e.g.
|
UNKNOWN_COMMAND
When command is not found
|
| Modifier and Type | Method and Description |
|---|---|
static InvalidUsage.Cause |
valueOf(java.lang.String name)
Returns the enum constant of this type with the specified name.
|
static InvalidUsage.Cause[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final InvalidUsage.Cause UNKNOWN_COMMAND
public static final InvalidUsage.Cause INVALID_ARGUMENT
command: /command [int] input: /command text
public static final InvalidUsage.Cause MISSING_ARGUMENT
command: /command [text] [x y z] input: /command text
public static final InvalidUsage.Cause MISSING_PART_OF_ARGUMENT
command: /command [text] [x y z] input: /command text 10 20
public static final InvalidUsage.Cause TOO_MANY_ARGUMENTS
command: /command [text] [x y z] input: /command text 10 20 30 40
public static InvalidUsage.Cause[] values()
for (InvalidUsage.Cause c : InvalidUsage.Cause.values()) System.out.println(c);
public static InvalidUsage.Cause valueOf(java.lang.String name)
name - the name of the enum constant to be returned.java.lang.IllegalArgumentException - if this enum type has no constant with the specified namejava.lang.NullPointerException - if the argument is null