Class Rotation
- java.lang.Object
-
- net.coobird.thumbnailator.filters.Rotation
-
public class Rotation extends java.lang.ObjectA class containing rotation filters.Aside from the three
Rotation.Rotators provided as class constants, aRotation.Rotatorwhich performs a rotation by an arbituary angle can be obtained through thenewRotator(double)method.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classRotation.RotatorAnImageFilterwhich applies a rotation to an image.
-
Field Summary
Fields Modifier and Type Field Description static Rotation.RotatorLEFT_90_DEGREESARotatorwhich will rotate a specified image to the left 90 degrees.static Rotation.RotatorRIGHT_90_DEGREESARotatorwhich will rotate a specified image to the right 90 degrees.static Rotation.RotatorROTATE_180_DEGREESARotatorwhich will rotate a specified image to the 180 degrees.
-
Constructor Summary
Constructors Modifier Constructor Description privateRotation()This class is not intended to be instantiated.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Rotation.RotatornewRotator(double angle)Creates a new instance ofRotatorwhich rotates an image at the specified angle.
-
-
-
Field Detail
-
LEFT_90_DEGREES
public static final Rotation.Rotator LEFT_90_DEGREES
ARotatorwhich will rotate a specified image to the left 90 degrees.
-
RIGHT_90_DEGREES
public static final Rotation.Rotator RIGHT_90_DEGREES
ARotatorwhich will rotate a specified image to the right 90 degrees.
-
ROTATE_180_DEGREES
public static final Rotation.Rotator ROTATE_180_DEGREES
ARotatorwhich will rotate a specified image to the 180 degrees.
-
-
Method Detail
-
newRotator
public static Rotation.Rotator newRotator(double angle)
Creates a new instance ofRotatorwhich rotates an image at the specified angle.When the
Rotation.Rotatorreturned by this method is applied, the image will be rotated clockwise by the specified angle.- Parameters:
angle- The angle at which the instance ofRotatoris to rotate a image it acts upon.- Returns:
- An instance of
Rotatorwhich will rotate a given image.
-
-