On Tue, 25 Nov 2025 16:11:16 GMT, Michael Strauß <[email protected]> wrote:
>> modules/javafx.graphics/src/main/java/javafx/animation/Interpolator.java >> line 98: >> >>> 96: >>> 97: /** >>> 98: * Returns a piecewise-linear interpolator with the specified >>> control points. >> >> Question: do we need to specify that a new instance is returned each time >> (as opposed to some sort of caching as with `Integer.valueOf`)? > > I've changed the wording here to give us more flexibility in terms of how we > implement this in the future. While we are returning a new instance each > time, we don't need to: all our currently implemented interpolators are > stateless and safe to share, even across threads. is this something worth mentioning in the javadoc, at least for the linear interpolator? ------------- PR Review Comment: https://git.openjdk.org/jfx/pull/1977#discussion_r2560605162
