Created
June 21, 2014 10:06
-
-
Save ryanjaeb/841bb08c0c5fa1bea946 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import javafx.collections.FXCollections; | |
import javafx.collections.ObservableList; | |
import javafx.collections.transformation.FilteredList; | |
public class FilteredListWithoutPredicate { | |
public static void main(String[] args) { | |
ObservableList<String> source = FXCollections.observableArrayList(); | |
source.addAll("one", "two", "three"); | |
System.out.println("source size: " + source.size()); | |
System.out.println("without predicate: " | |
+ new FilteredList<>(source).size()); | |
System.out.println("with predicate: " | |
+ new FilteredList<>(source, t -> true).size()); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment