mapToDouble abstract method

DoubleStream mapToDouble(
  1. double mapper(
    1. int
    )
)

Returns a DoubleStream consisting of the results of applying the given function to the elements of this stream.

Example

final halves = IntStream.range(1, 5)
    .mapToDouble((n) => n / 2.0);

Implementation

DoubleStream mapToDouble(double Function(int) mapper);