Package io.scanbot.sdk.geometry
Class RectangleF
java.lang.Object
io.scanbot.sdk.geometry.RectangleF
Represents a rectangle with float coordinates in 2D space.
-
Constructor Summary
ConstructorsConstructorDescriptionRectangleF(float x, float y, float width, float height) Constructs a rectangle with given coordinates and dimensions. -
Method Summary
Modifier and TypeMethodDescriptionfloatReturns the height of the rectangle.floatgetWidth()Returns the width of the rectangle.floatgetX()Returns the x-coordinate of the top-left corner of the rectangle.floatgetY()Returns the y-coordinate of the top-left corner of the rectangle.voidsetHeight(float height) Sets the height of the rectangle.voidsetWidth(float width) Sets the width of the rectangle.voidsetX(float x) Sets the x-coordinate of the top-left corner of the rectangle.voidsetY(float y) Sets the y-coordinate of the top-left corner of the rectangle.
-
Constructor Details
-
RectangleF
public RectangleF(float x, float y, float width, float height) Constructs a rectangle with given coordinates and dimensions.- Parameters:
x- x-coordinate of the top-left cornery- y-coordinate of the top-left cornerwidth- widthheight- height
-
-
Method Details
-
getX
public float getX()Returns the x-coordinate of the top-left corner of the rectangle.- Returns:
- x-coordinate
-
setX
public void setX(float x) Sets the x-coordinate of the top-left corner of the rectangle.- Parameters:
x- x-coordinate
-
getY
public float getY()Returns the y-coordinate of the top-left corner of the rectangle.- Returns:
- y-coordinate
-
setY
public void setY(float y) Sets the y-coordinate of the top-left corner of the rectangle.- Parameters:
y- y-coordinate
-
getWidth
public float getWidth()Returns the width of the rectangle.- Returns:
- width
-
setWidth
public void setWidth(float width) Sets the width of the rectangle.- Parameters:
width- width
-
getHeight
public float getHeight()Returns the height of the rectangle.- Returns:
- height
-
setHeight
public void setHeight(float height) Sets the height of the rectangle.- Parameters:
height- height
-