diff options
author | Mikael Grankvist <mikael.grankvist@vaadin.com> | 2017-01-26 10:46:28 +0200 |
---|---|---|
committer | Mikael Grankvist <mikael.grankvist@vaadin.com> | 2017-01-26 10:46:28 +0200 |
commit | 6b0ce3d034d321971191ceb48f7a2bca62efe71e (patch) | |
tree | 8457668d565149dcc39a4235ab0fc6539bd81fd4 | |
parent | 5703dc03dc57cf4751360b97307796519bc321b0 (diff) | |
download | vaadin-framework-issue/8307_select_using_collection.tar.gz vaadin-framework-issue/8307_select_using_collection.zip |
Do not stream the collection for a forEach.issue/8307_select_using_collection
-rw-r--r-- | server/src/main/java/com/vaadin/data/SelectionModel.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/src/main/java/com/vaadin/data/SelectionModel.java b/server/src/main/java/com/vaadin/data/SelectionModel.java index 2f22c81aa1..69f143e0f7 100644 --- a/server/src/main/java/com/vaadin/data/SelectionModel.java +++ b/server/src/main/java/com/vaadin/data/SelectionModel.java @@ -187,7 +187,7 @@ public interface SelectionModel<T> extends Serializable { */ public default void selectItems(Collection<T> items) { Objects.requireNonNull(items); - items.stream().forEach(Objects::requireNonNull); + items.forEach(Objects::requireNonNull); updateSelection( new LinkedHashSet<>( @@ -229,7 +229,7 @@ public interface SelectionModel<T> extends Serializable { */ public default void deselectItems(Collection<T> items) { Objects.requireNonNull(items); - items.stream().forEach(Objects::requireNonNull); + items.forEach(Objects::requireNonNull); updateSelection(Collections.emptySet(), new LinkedHashSet<>( items.stream().collect(Collectors.toList()))); |