Interface Rotation
- All Superinterfaces:
Shiftable<Rotation>
,ValueProvider<Rotation>
Represents a rotation.
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionint
degree()
Rotation represented as positive int value.static Rotation
Get a string as rotation value.default @NotNull Rotation
value()
Get the current valuedefault void
Change the current value.static Rotation
valueOf
(int value) Get a string as rotation value.default Rotation
Returns a new valueMethods inherited from interface de.eldoria.schematicbrush.brush.config.util.Shiftable
shift, shiftable
Methods inherited from interface de.eldoria.schematicbrush.brush.config.util.ValueProvider
refresh
-
Field Details
-
ROT_ZERO
Represents a rotation of 0. -
ROT_LEFT
Represents a rotation of 90 degrees counterclockwise. Alterantive a rotation of -90 or 270 degrees. -
ROT_HALF
Represents a rotation of 180 degrees. -
ROT_RIGHT
Represents a rotation of 90 degrees clockwise. Alterantive a rotation of 90 degrees.
-
-
Method Details
-
parse
Get a string as rotation value.- Parameters:
value
- value to parse- Returns:
- rotation enum
- Throws:
IllegalArgumentException
- when value can't be parsedCommandException
- when the value can't be parsed
-
valueOf
Get a string as rotation value.- Parameters:
value
- value to parse- Returns:
- rotation enum
- Throws:
IllegalArgumentException
- when value can't be parsed
-
degree
int degree()Rotation represented as positive int value.- Returns:
- rotation as positive integer
-
value
Description copied from interface:ValueProvider
Change the current value.- Specified by:
value
in interfaceValueProvider<Rotation>
- Parameters:
value
- value to set
-
value
Description copied from interface:ValueProvider
Get the current value- Specified by:
value
in interfaceValueProvider<Rotation>
- Returns:
- the value
-
valueProvider
Description copied from interface:ValueProvider
Returns a new value- Specified by:
valueProvider
in interfaceValueProvider<Rotation>
- Returns:
- new value
-