May 2018
Intermediate to advanced
268 pages
6h 43m
English
JavaFX 10 supports three main collection types—List, Map, and Set.
You can make any Java collection observable using FXCollections helper methods:
List observableList = FXCollections.observableArrayList(collection);
This makes a collection trigger a listener on every addition, removal, or change in the elements order.
The FXCollections class mimics java.util.Collections a lot, providing observable counterparts for java.util.Collections methods.
Note you can go even deeper, observing not only a collection but the collection elements' changes as well, using the following method:
<E> ObservableList<E> observableList(List<E> list, Callback<E, Observable[]> extractor)
Here, you need to additionally provide the ...
Read now
Unlock full access