📌  相关文章
📜  原因:java.lang.IllegalStateException:流已被操作或关闭 - Java 代码示例

📅  最后修改于: 2022-03-11 14:52:17.808000             🧑  作者: Mango

代码示例1
Supplier> streamSupplier 
  = () -> Stream.of("A", "B", "C", "D");
Optional result1 = streamSupplier.get().findAny();
System.out.println(result1.get());
Optional result2 = streamSupplier.get().findFirst();
System.out.println(result2.get());