Module javafx.base


The package defines read-only properties and writable properties, plus a number of implementations.

Read-only Properties

Read-only properties have two getters, get() returns the primitive value, getValue() returns the boxed value.

It is possible to observe read-only properties for changes. They define methods to add and remove InvalidationListeners and ChangeListeners.

To get the context of a read-only property, two methods getBean() and getName() are defined. They return the containing bean and the name of a property.

Writable Properties

In addition to the functionality defined for read-only properties, writable properties contain the following methods.

A writable property defines two setters in addition to the getters defined for read-only properties. The setter set() takes a primitive value, the second setter setValue() takes the boxed value.

All properties can be bound to ObservableValues of the same type, which means that the property will always contain the same value as the bound ObservableValue. It is also possible to define a bidirectional binding between two properties, so that both properties always contain the same value. If one of the properties changes, the other one will be updated.