public class Corners extends Object
Represents corners of a square graphical object.
Modifier and Type | Field and Description |
---|---|
static Corners |
Empty
Provides a Corners object with no data.
|
Constructor and Description |
---|
Corners()
Initializes a new instance of Corners class using zero values.
|
Corners(double all)
Initializes a new instance of the Corners class using the supplied value for all corners.
|
Corners(double topLeft,
double topRight,
double bottomLeft,
double bottomRight)
Initializes a new instance of the Corners class using the supplied values.
|
Modifier and Type | Method and Description |
---|---|
Object |
deepClone()
Gets a copy of this object.
|
boolean |
equals(Object obj)
Override equals method
|
double |
getAll()
Gets or sets the value for all corners.
|
double |
getBottomLeft()
Gets or sets bottom left corner value.
|
double |
getBottomRight()
Gets or sets bottom right corner value.
|
double |
getTopLeft()
Gets or sets top left corner value.
|
double |
getTopRight()
Gets or sets top right corner value.
|
int |
hashCode()
Overrides obtaining unique hash code value
|
void |
setAll(double value)
Gets or sets the value for all corners.
|
void |
setBottomLeft(double value)
Gets or sets bottom left corner value.
|
void |
setBottomRight(double value)
Gets or sets bottom right corner value.
|
void |
setTopLeft(double value)
Gets or sets top left corner value.
|
void |
setTopRight(double value)
Gets or sets top right corner value.
|
String |
toString()
Overrides conversion to string.
|
public static final Corners Empty
Provides a Corners object with no data.
public Corners()
Initializes a new instance of Corners class using zero values.
public Corners(double all)
Initializes a new instance of the Corners class using the supplied value for all corners.
all
- The value to be used for padding for all corners.public Corners(double topLeft, double topRight, double bottomLeft, double bottomRight)
Initializes a new instance of the Corners class using the supplied values.
topLeft
- Top left corner value.topRight
- Top right corner value.bottomLeft
- Bottom left corner value.bottomRight
- Bottom right corner value.public final Object deepClone()
Gets a copy of this object.
public boolean equals(Object obj)
Override equals method
public final double getAll()
Gets or sets the value for all corners. Changing of any partial corner like top right makes this property equal 0;
public final double getBottomLeft()
Gets or sets bottom left corner value.
public final double getBottomRight()
Gets or sets bottom right corner value.
public final double getTopLeft()
Gets or sets top left corner value.
public final double getTopRight()
Gets or sets top right corner value.
public int hashCode()
Overrides obtaining unique hash code value
public final void setAll(double value)
Gets or sets the value for all corners. Changing of any partial corner like top right makes this property equal 0;
public final void setBottomLeft(double value)
Gets or sets bottom left corner value.
public final void setBottomRight(double value)
Gets or sets bottom right corner value.
public final void setTopLeft(double value)
Gets or sets top left corner value.
public final void setTopRight(double value)
Gets or sets top right corner value.