Enum Command.CommandType
- java.lang.Object
-
- java.lang.Enum<Command.CommandType>
-
- com.snowflake.connectors.taskreactor.commands.queue.Command.CommandType
-
- All Implemented Interfaces:
Serializable
,Comparable<Command.CommandType>
- Enclosing class:
- Command
public static enum Command.CommandType extends Enum<Command.CommandType>
Valid command types that are recognized and supported by the command processor.
-
-
Enum Constant Summary
Enum Constants Enum Constant Description CANCEL_ONGOING_EXECUTIONS
PAUSE_INSTANCE
RESUME_INSTANCE
SET_WORKERS_NUMBER
UPDATE_WAREHOUSE
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static boolean
isValidType(String commandType)
static Command.CommandType
valueOf(String name)
Returns the enum constant of this type with the specified name.static Command.CommandType[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
-
-
Enum Constant Detail
-
RESUME_INSTANCE
public static final Command.CommandType RESUME_INSTANCE
-
PAUSE_INSTANCE
public static final Command.CommandType PAUSE_INSTANCE
-
UPDATE_WAREHOUSE
public static final Command.CommandType UPDATE_WAREHOUSE
-
SET_WORKERS_NUMBER
public static final Command.CommandType SET_WORKERS_NUMBER
-
CANCEL_ONGOING_EXECUTIONS
public static final Command.CommandType CANCEL_ONGOING_EXECUTIONS
-
-
Method Detail
-
values
public static Command.CommandType[] values()
Returns an array containing the constants of this enum type, in the order they are declared. This method may be used to iterate over the constants as follows:for (Command.CommandType c : Command.CommandType.values()) System.out.println(c);
- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
public static Command.CommandType valueOf(String name)
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is null
-
isValidType
public static boolean isValidType(String commandType)
- Parameters:
commandType
- the type of the command as a literal to be validated whether is supported- Returns:
- boolean with information whether the passed type is valid or not
-
-