Example usage for java.util.stream DoubleStream forEachOrdered

List of usage examples for java.util.stream DoubleStream forEachOrdered

Introduction

In this page you can find the example usage for java.util.stream DoubleStream forEachOrdered.

Prototype

void forEachOrdered(DoubleConsumer action);

Source Link

Document

Performs an action for each element of this stream, guaranteeing that each element is processed in encounter order for streams that have a defined encounter order.

Usage

From source file:Main.java

public static void main(String[] args) {
    DoubleStream d = DoubleStream.of(1.2, 2.3, 4.5);
    d.forEachOrdered(System.out::println);

}