To take it further, decreasing the cost of rarely used properties in the Node 
class (or the Node class hierarchy should this idea gains traction) would make 
it possible to add more convenience properties such as boundsOnScreen, 
owningWindow, etc.

-andy



From: openjfx-dev <[email protected]> on behalf of Andy Goryachev 
<[email protected]>
Date: Wednesday, February 4, 2026 at 13:17
To: OpenJFX <[email protected]>
Subject: Experiment: Node properties

I would like to share the results of a little experiment involving optimization 
of storage of Node properties.  The basic idea is to create a compact fast 
map-like container to hold the rarely instantiated properties in order to 
reduce the application memory footprint.

The savings are not overwhelming, but not exactly zero.  I would imagine this 
optimization might be more interesting in any resource constrained environment 
such as Android / iOS / RaspberryPi.  Please refer to [0] for the details.

I encourage you to try it with your application, to see whether you notice any 
change in memory consumption and/or performance.  Let me know what you think!

Cheers,
-andy


References

[0] 
https://github.com/andy-goryachev-oracle/Test/blob/main/doc/Experiments/NodeProperties.md

Reply via email to