Both x and y and integers, while getX() and getY() returns a doubles.
Why aren't there e.g. getXIntValue(), getXDoubleValue() and vice versa for y?
Note the @since in the Javadoc -- 1.0
There is broad consensus that Point was very poorly designed.
Point extends Point2D and Point2D has getX() and getY() defined as returning double. As @Dilum mentions above, its bad design from the stone ages of java.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With