Enum Class SetPacket.Operation
- All Implemented Interfaces:
Serializable,Comparable<SetPacket.Operation>,Constable
- Enclosing class:
- SetPacket
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAdds value to the current value of the key on the server, if both the current value and value are arrays then value will be appended to the current @value.Applies a bitwise AND to the current value on the server of the key with @value.If the key has no value yet, Sets the current value of the key on the server to the default of the Set's package (@value is ignored).Applies a bitwise left-shift to the current value of the key on the server by @value.Sets the current value of the key on the server to @value if @value is bigger.Sets the current value of the key on the server to @value if @value is lower.Sets the current value of the key on the server to the remainder after division by @value.Multiplies the current value of the key on the server by @value.Applies a bitwise OR to the current value of the key on the server with @value.List or Dict: for lists it will remove the index of the @value given.Multiplies the current value of the key on the server to the power of @value.List only: removes the first instance of @value found in the list.Sets the current value of the key on the server to the value given inaddDataStorageOperation(Operation, Value).Applies a bitwise right-shift to the current value of the key on the server by @value.Dict only: Updates the dictionary with the specified elements given in @value creating new keys, or updating old ones if they previously existed.Applies a bitwise Exclusive OR to the current value of the key on the server with @value. -
Method Summary
Modifier and TypeMethodDescriptionstatic SetPacket.OperationReturns the enum constant of this class with the specified name.static SetPacket.Operation[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
REPLACE
Sets the current value of the key on the server to the value given inaddDataStorageOperation(Operation, Value). -
DEFAULT
If the key has no value yet, Sets the current value of the key on the server to the default of the Set's package (@value is ignored). -
ADD
Adds value to the current value of the key on the server, if both the current value and value are arrays then value will be appended to the current @value. -
MULTIPLY
Multiplies the current value of the key on the server by @value. -
POWER
Multiplies the current value of the key on the server to the power of @value. -
MODULO
Sets the current value of the key on the server to the remainder after division by @value. -
MAX
Sets the current value of the key on the server to @value if @value is bigger. -
MIN
Sets the current value of the key on the server to @value if @value is lower. -
AND
Applies a bitwise AND to the current value on the server of the key with @value. -
OR
Applies a bitwise OR to the current value of the key on the server with @value. -
XOR
Applies a bitwise Exclusive OR to the current value of the key on the server with @value. -
LEFT_SHIFT
Applies a bitwise left-shift to the current value of the key on the server by @value. -
RIGHT_SHIFT
Applies a bitwise right-shift to the current value of the key on the server by @value. -
REMOVE
List only: removes the first instance of @value found in the list. -
POP
List or Dict: for lists it will remove the index of the @value given. for dicts it removes the element with the specified key of value. -
UPDATE
Dict only: Updates the dictionary with the specified elements given in @value creating new keys, or updating old ones if they previously existed.
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (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 class has no constant with the specified nameNullPointerException- if the argument is null
-