Class AbstractRectangularShape1dfx<IT extends AbstractRectangularShape1dfx<?>>
- java.lang.Object
-
- org.arakhne.afc.math.geometry.d1.dfx.AbstractShape1dfx<IT>
-
- org.arakhne.afc.math.geometry.d1.dfx.AbstractRectangularShape1dfx<IT>
-
- Type Parameters:
IT- is the type of the implementation of this shape.
- All Implemented Interfaces:
Serializable,Cloneable,RectangularShape1afp<Shape1dfx<?>,IT,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>,Shape1afp<Shape1dfx<?>,IT,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>,Shape1dfx<IT>,Shape1D<Shape1dfx<?>,IT,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>,JsonableObject
public abstract class AbstractRectangularShape1dfx<IT extends AbstractRectangularShape1dfx<?>> extends AbstractShape1dfx<IT> implements RectangularShape1afp<Shape1dfx<?>,IT,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>
Abstract rectangular shape with 2 double precision floating-point FX properties.- Since:
- 14.0
- Version:
- 17.0 2020-01-04 14:41:49
- Author:
- Stéphane GALLAND
- See Also:
- Serialized Form
- Maven Group Id:
- org.arakhne.afc.advanced
- Maven Artifact Id:
- mathfx
-
-
Field Summary
Fields Modifier and Type Field Description (package private) javafx.beans.property.DoublePropertyheightheight property.(package private) javafx.beans.property.DoublePropertymaxXmaxX property.(package private) javafx.beans.property.DoublePropertymaxYmaxY property.(package private) javafx.beans.property.DoublePropertyminXminX property.(package private) javafx.beans.property.DoublePropertyminYminY property.(package private) javafx.beans.property.DoublePropertywidthwidth property.-
Fields inherited from class org.arakhne.afc.math.geometry.d1.dfx.AbstractShape1dfx
boundingBox, segment
-
-
Constructor Summary
Constructors Constructor Description AbstractRectangularShape1dfx()Construct an empty rectangular shape.AbstractRectangularShape1dfx(RectangularShape2afp<?,?,?,?,?,?> shape)Constructor by copy.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description javafx.beans.property.ObjectProperty<Rectangle1dfx>boundingBoxProperty()Replies the property that contains the bounding box for this shape.ITclone()Clone this shape.doublegetHeight()Replies the height.doublegetMaxX()Replies the max x.doublegetMaxY()Replies the max y.doublegetMinX()Replies the min X.doublegetMinY()Replies the min y.doublegetWidth()Replies the width.inthashCode()javafx.beans.property.DoublePropertyheightProperty()Replies the property that is the height of the box.javafx.beans.property.DoublePropertymaxXProperty()Replies the property that is the maximum x coordinate of the box.javafx.beans.property.DoublePropertymaxYProperty()Replies the property that is the maximum y coordinate of the box.javafx.beans.property.DoublePropertyminXProperty()Replies the property that is the minimum x coordinate of the box.javafx.beans.property.DoublePropertyminYProperty()Replies the property that is the minimum y coordinate of the box.voidsetFromCorners(double x1, double y1, double x2, double y2)Change the frame of the rectangle conserving previous min and max if needed.voidsetMaxX(double x)Set the max X conserving previous max if needed.voidsetMaxY(double y)Set the max Y conserving previous max if needed.voidsetMinX(double x)Set the min X conserving previous min if needed.voidsetMinY(double y)Set the min Y conserving previous min if needed.javafx.beans.property.DoublePropertywidthProperty()Replies the property that is the width of the box.-
Methods inherited from class org.arakhne.afc.math.geometry.d1.dfx.AbstractShape1dfx
equals, getGeomFactory, getSegment, segmentProperty, setSegment, toJson, toString
-
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.arakhne.afc.vmutil.json.JsonableObject
toJson
-
Methods inherited from interface org.arakhne.afc.math.geometry.d1.afp.RectangularShape1afp
clear, getCenter, getCenterX, getCenterY, inflate, isEmpty, set, set, set, setFromCenter, setFromCenter, setFromCorners, setHeight, setWidth, toBoundingBox, translate
-
Methods inherited from interface org.arakhne.afc.math.geometry.d1.afp.Shape1afp
contains, contains, contains, contains, getClosestPointTo, getClosestPointTo, getDistanceSquared, getDistanceSquared, getGeomFactory, intersects, intersects, toBoundingBox, translate
-
Methods inherited from interface org.arakhne.afc.math.geometry.d1.Shape1D
equalsToShape, getClosestPointTo, getDistance, getDistance, getDistanceL1, getDistanceLinf, getDistanceSquared, getFarthestPointTo, getSegment, operator_add, operator_and, operator_and, operator_minus, operator_plus, operator_remove, operator_upTo, setSegment
-
-
-
-
Field Detail
-
minX
javafx.beans.property.DoubleProperty minX
minX property.
-
minY
javafx.beans.property.DoubleProperty minY
minY property.
-
maxX
javafx.beans.property.DoubleProperty maxX
maxX property.
-
maxY
javafx.beans.property.DoubleProperty maxY
maxY property.
-
width
javafx.beans.property.DoubleProperty width
width property.
-
height
javafx.beans.property.DoubleProperty height
height property.
-
-
Constructor Detail
-
AbstractRectangularShape1dfx
public AbstractRectangularShape1dfx()
Construct an empty rectangular shape.
-
AbstractRectangularShape1dfx
public AbstractRectangularShape1dfx(RectangularShape2afp<?,?,?,?,?,?> shape)
Constructor by copy.- Parameters:
shape- the shape to copy.
-
-
Method Detail
-
clone
public IT clone()
Description copied from interface:Shape1DClone this shape.- Specified by:
clonein interfaceShape1D<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Overrides:
clonein classAbstractShape1dfx<IT extends AbstractRectangularShape1dfx<?>>- Returns:
- the clone.
-
setFromCorners
public void setFromCorners(double x1, double y1, double x2, double y2)Description copied from interface:RectangularShape1afpChange the frame of the rectangle conserving previous min and max if needed.- Specified by:
setFromCornersin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Parameters:
x1- is the coordinate of the first corner.y1- is the coordinate of the first corner.x2- is the coordinate of the second corner.y2- is the coordinate of the second corner.
-
getMinX
@Pure public double getMinX()
Description copied from interface:RectangularShape1afpReplies the min X.- Specified by:
getMinXin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the min x.
-
setMinX
public void setMinX(double x)
Description copied from interface:RectangularShape1afpSet the min X conserving previous min if needed.- Specified by:
setMinXin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Parameters:
x- the min x.
-
minXProperty
@Pure public javafx.beans.property.DoubleProperty minXProperty()
Replies the property that is the minimum x coordinate of the box.- Returns:
- the minX property.
-
getMaxX
@Pure public double getMaxX()
Description copied from interface:RectangularShape1afpReplies the max x.- Specified by:
getMaxXin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the max x.
-
setMaxX
public void setMaxX(double x)
Description copied from interface:RectangularShape1afpSet the max X conserving previous max if needed.- Specified by:
setMaxXin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Parameters:
x- the max x.
-
maxXProperty
@Pure public javafx.beans.property.DoubleProperty maxXProperty()
Replies the property that is the maximum x coordinate of the box.- Returns:
- the maxX property.
-
getMinY
@Pure public double getMinY()
Description copied from interface:RectangularShape1afpReplies the min y.- Specified by:
getMinYin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the min y.
-
setMinY
public void setMinY(double y)
Description copied from interface:RectangularShape1afpSet the min Y conserving previous min if needed.- Specified by:
setMinYin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Parameters:
y- the min y.
-
minYProperty
@Pure public javafx.beans.property.DoubleProperty minYProperty()
Replies the property that is the minimum y coordinate of the box.- Returns:
- the minY property.
-
getMaxY
@Pure public double getMaxY()
Description copied from interface:RectangularShape1afpReplies the max y.- Specified by:
getMaxYin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the max y.
-
setMaxY
public void setMaxY(double y)
Description copied from interface:RectangularShape1afpSet the max Y conserving previous max if needed.- Specified by:
setMaxYin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Parameters:
y- the max y.
-
maxYProperty
@Pure public javafx.beans.property.DoubleProperty maxYProperty()
Replies the property that is the maximum y coordinate of the box.- Returns:
- the maxY property.
-
getWidth
public double getWidth()
Description copied from interface:RectangularShape1afpReplies the width.- Specified by:
getWidthin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the width.
-
widthProperty
@Pure public javafx.beans.property.DoubleProperty widthProperty()
Replies the property that is the width of the box.- Returns:
- the width property.
-
getHeight
public double getHeight()
Description copied from interface:RectangularShape1afpReplies the height.- Specified by:
getHeightin interfaceRectangularShape1afp<Shape1dfx<?>,IT extends AbstractRectangularShape1dfx<?>,Point1dfx,Vector1dfx,Segment1D<?,?>,Rectangle1dfx>- Returns:
- the height.
-
heightProperty
@Pure public javafx.beans.property.DoubleProperty heightProperty()
Replies the property that is the height of the box.- Returns:
- the height property.
-
hashCode
@Pure public int hashCode()
- Specified by:
hashCodein classAbstractShape1dfx<IT extends AbstractRectangularShape1dfx<?>>
-
boundingBoxProperty
public javafx.beans.property.ObjectProperty<Rectangle1dfx> boundingBoxProperty()
Description copied from interface:Shape1dfxReplies the property that contains the bounding box for this shape.- Specified by:
boundingBoxPropertyin interfaceShape1dfx<IT extends AbstractRectangularShape1dfx<?>>- Returns:
- the bounding box.
-
-