- All Implemented Interfaces:
Serializable
,Comparable<ImageOrientation>
Image orientation specification.
These constants determine an output stream should contain the image
as is or if it should rotate the image clockwise or
counterclockwise by 90 degrees. These enumeration constants are
used by OutputStream Graphics to control the orientation of images
when they are outputed.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAn image should be rotated 90 degrees clockwise.An image should be rotated 90 degrees counterclockwise, The height and width will be swapped and the image will be translated so that points that fall within a bounding box whose edges are at (0,0), (WIDTH, 0), (0, HEIGHT), and (WIDTH, HEIGHT) for a NORMAL orientation will appear within a bounding box whose edges are (0,0), (HEIGHT, 0), (0, WIDTH), and (HEIGHT, WIDTH) for this orientation.No transformation is performed. -
Method Summary
Modifier and TypeMethodDescriptionstatic ImageOrientation
Returns the enum constant of this type with the specified name.static ImageOrientation[]
values()
Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
NORMAL
No transformation is performed. This is the default. -
COUNTERCLOCKWISE90
An image should be rotated 90 degrees counterclockwise, The height and width will be swapped and the image will be translated so that points that fall within a bounding box whose edges are at (0,0), (WIDTH, 0), (0, HEIGHT), and (WIDTH, HEIGHT) for a NORMAL orientation will appear within a bounding box whose edges are (0,0), (HEIGHT, 0), (0, WIDTH), and (HEIGHT, WIDTH) for this orientation. -
CLOCKWISE90
An image should be rotated 90 degrees clockwise. The height and width will be swapped and the image will be translated so that points that fall within a bounding box whose edges are at (0,0), (WIDTH, 0), (0, HEIGHT), and (WIDTH, HEIGHT) for a NORMAL orientation will appear within a bounding box whose edges are (0,0), (HEIGHT, 0), (0, WIDTH), and (HEIGHT, WIDTH) for this orientation.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
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
-