commit | 0bc256f575ca533886bd313756d2739bc4c8bf4d | [log] [tgz] |
---|---|---|
author | HIGUCHI Yuta <y-higuchi@ak.jp.nec.com> | Fri May 06 15:28:26 2016 -0700 |
committer | Gerrit Code Review <gerrit@onlab.us> | Fri May 06 23:08:50 2016 +0000 |
tree | 352248ba3ad8e9b8fcd2c05153f1e626c124220b | |
parent | 9e61bd99e6931b9bc9cd4eb4c582840711ba79f3 [diff] |
Help type inference. - Build was failing with eclipse ECJ Change-Id: I506e90b52b0c0f63081e75cfa98a83bf294261ba
diff --git a/utils/misc/src/main/java/org/onlab/util/Tools.java b/utils/misc/src/main/java/org/onlab/util/Tools.java index b516459..73d2a36 100644 --- a/utils/misc/src/main/java/org/onlab/util/Tools.java +++ b/utils/misc/src/main/java/org/onlab/util/Tools.java
@@ -660,7 +660,7 @@ * @return optional as a stream */ public static <T> Stream<T> stream(Optional<? extends T> optional) { - return optional.map(x -> Stream.of(x)).orElse(Stream.empty()); + return optional.map(x -> Stream.<T>of(x)).orElse(Stream.empty()); } // Auxiliary path visitor for recursive directory structure copying.