Rectangle

Inheritance: java.lang.Object, com.aspose.ms.System.ValueType, com.aspose.ms.lang.Struct

public class Rectangle extends Struct<Rectangle>

A set of four integers that represent the location and size of a rectangle.

Constructors

Constructor Description
Rectangle()

Methods

Method Description
getEmpty() Gets the empty rectangle.
getX() Gets the x.
getY() Gets the y.
getWidth() Gets the width.
getHeight() Gets the height.
getLeft() Gets the x-coordinate of the left edge of the rectangle.
getTop() Gets the y-coordinate that is the sum of the Y and Height property values of the rectangle.
getRight() Gets the x-coordinate that is the sum of X and Width property values of the rectangle.
getBottom() Gets the y-coordinate that is the sum of the Y and Height property values of the rectangle.
isEmpty() Gets a value indicating whether this instance is empty.
toString() Returns a System.String that represents this instance.
CloneTo(Rectangle that)
Clone()
clone()
equals(Object obj)
equals(Rectangle obj1, Rectangle obj2)

Rectangle()

public Rectangle()

getEmpty()

public static Rectangle getEmpty()

Gets the empty rectangle.

Returns: Rectangle - The empty rectangle.

getX()

public final int getX()

Gets the x.

Returns: int - The x.

getY()

public final int getY()

Gets the y.

Returns: int - The y.

getWidth()

public final int getWidth()

Gets the width.

Returns: int - The width.

getHeight()

public final int getHeight()

Gets the height.

Returns: int - The height.

getLeft()

public final int getLeft()

Gets the x-coordinate of the left edge of the rectangle.

Returns: int - The x-coordinate of the left edge of the rectangle.

getTop()

public final int getTop()

Gets the y-coordinate that is the sum of the Y and Height property values of the rectangle.

Returns: int - The y-coordinate that is the sum of the Y and Height property values of the rectangle.

getRight()

public final int getRight()

Gets the x-coordinate that is the sum of X and Width property values of the rectangle.

Returns: int - The x-coordinate that is the sum of X and Width property values of the rectangle.

getBottom()

public final int getBottom()

Gets the y-coordinate that is the sum of the Y and Height property values of the rectangle.

Returns: int - The y-coordinate that is the sum of the Y and Height property values of the rectangle.

isEmpty()

public final boolean isEmpty()

Gets a value indicating whether this instance is empty.

Returns: boolean - true if this instance is empty; otherwise, false .

toString()

public String toString()

Returns a System.String that represents this instance.

Returns: java.lang.String - A System.String that represents this instance.

CloneTo(Rectangle that)

public void CloneTo(Rectangle that)

Parameters:

Parameter Type Description
that Rectangle

Clone()

public Rectangle Clone()

Returns: Rectangle

clone()

public Object clone()

Returns: java.lang.Object

equals(Object obj)

public boolean equals(Object obj)

Parameters:

Parameter Type Description
obj java.lang.Object

Returns: boolean

equals(Rectangle obj1, Rectangle obj2)

public static boolean equals(Rectangle obj1, Rectangle obj2)

Parameters:

Parameter Type Description
obj1 Rectangle
obj2 Rectangle

Returns: boolean