public enum Rotation extends Enum<Rotation>
| Enum Constant and Description |
|---|
clockwise
90 degrees clockwise rotation.
|
counterClockwise
90 degrees counter-clockwise rotation.
|
none
No rotation.
|
upsideDown
180 degrees rotation.
|
| Modifier and Type | Method and Description |
|---|---|
Component.BaselineResizeBehavior |
adjust(Component.BaselineResizeBehavior behavior)
Returns baseline resize behavior adjusted according to rotation.
|
boolean |
isVertical()
Return whether orientation vertical or not.
|
Rotation |
rightToLeft()
Returns opposite orientation.
|
Dimension |
transpose(Dimension dimension)
Returns dimension transposed according to rotation.
|
Rectangle |
transpose(Rectangle rectangle)
Returns rectangle transposed according to rotation.
|
static Rotation |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static Rotation[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final Rotation none
public static final Rotation clockwise
public static final Rotation counterClockwise
public static final Rotation upsideDown
public static Rotation[] values()
for (Rotation c : Rotation.values()) System.out.println(c);
public static Rotation valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic boolean isVertical()
public Rotation rightToLeft()
public Rectangle transpose(Rectangle rectangle)
rectangle - rectangle to transposepublic Dimension transpose(Dimension dimension)
dimension - dimension to transposepublic Component.BaselineResizeBehavior adjust(Component.BaselineResizeBehavior behavior)
behavior - baseline resize behaviorCopyright © 2020. All rights reserved.