Package org.testfx.service.query
Interface PointQuery
- All Known Implementing Classes:
BoundsPointQuery,CallableBoundsPointQuery,PointQueryBase
public interface PointQuery
Used to calculate a position within a given
Bounds.-
Method Summary
Modifier and TypeMethodDescriptionatOffset(double offsetX, double offsetY) UpdatesgetOffset()by the combination of the currentoffset'sxvalue andoffsetXand itsyvalue andoffsetY.atOffset(javafx.geometry.Point2D offset) UpdatesgetOffset()to benew Point2D(this.offset.getX() + offset.getX(), this.offset.getY() + offset.getY()).atPosition(double positionX, double positionY) UpdatesgetPosition()to the newposition.atPosition(javafx.geometry.Point2D position) UpdatesgetPosition()to the newposition.atPosition(javafx.geometry.Pos position) UpdatesgetPosition()to a new one based on the givenposition.javafx.geometry.Point2Djavafx.geometry.Point2DonNode(javafx.scene.Node node) javafx.geometry.Point2Dquery()
-
Method Details
-
getPosition
javafx.geometry.Point2D getPosition()- Returns:
- the position that stores the
xandypercentages (0.0 = 0% to 1.0 = 100%) to use when calculating a relative position within aBoundsobject.
-
getOffset
javafx.geometry.Point2D getOffset()- Returns:
- the amount by which to offset the point calculated via
getPosition().
-
atPosition
UpdatesgetPosition()to the newposition.- Parameters:
position- the new position- Returns:
- itself
-
atPosition
UpdatesgetPosition()to the newposition.- Parameters:
positionX- the percentage to use: 0.0 (0%) to 1.0 (100%).positionY- the percentage to use: 0.0 (0%) to 1.0 (100%).- Returns:
- itself
-
atPosition
UpdatesgetPosition()to a new one based on the givenposition.- Parameters:
position- left/up = 0.0 (0%); center = 0.5 (50%); right/down = 1.0 (100%)- Returns:
- itself
-
atOffset
UpdatesgetOffset()to benew Point2D(this.offset.getX() + offset.getX(), this.offset.getY() + offset.getY()).- Parameters:
offset- the amount by which to increase/decrease the offset's x and y values- Returns:
- itself
-
atOffset
UpdatesgetOffset()by the combination of the currentoffset'sxvalue andoffsetXand itsyvalue andoffsetY.- Parameters:
offsetX- the amount by which to increase/decrease the offset's x valueoffsetY- the amount by which to increase/decrease the offset's y value- Returns:
- itself
-
query
javafx.geometry.Point2D query()- Returns:
- a position that offsets the relative position within the initial
Boundsobject that is calculated viagetPosition()bygetOffset()amount.
-
onNode
-
queryMotion
-