I am very new to JavaFX.
I am working on an application where I have several GUI components which change appearance based on several data values. For example, there might be 3 traffic light components displayed which each change color based on the settings of three different pieces of data, let's call them light1, light2, and light3. The component has a function called updateColor(int data) which will update the color accordingly.
There is a separate thread running which periodically gets the data values and updates the values in light1, light2, and light3.
Now I would like the displayed components to automatically change colors as soon as the separate thread updates those values.
I have read about binding, but none of the examples I've seen seem to address this situation. Any ideas or pointers to some similar examples would be appreciated.