ObservableListSize
An ObservableInt whose value is the size of an ObservableList.
As example of where this might be useful. Suppose we want to disable a button when a list is empty. Simply bind its disabledProperty to :
ObservableListSize(list).equalTo(0)Content copied to clipboard
Alternatively, we might want a label to contain a list's size, in which case, bind its textProperty to :
ObservableListSize(list).toObservableString()Content copied to clipboard