Interface DoubleSupplier

All Superinterfaces:
DoubleSupplier

public interface DoubleSupplier extends DoubleSupplier
Enhanced IntSupplier.
Author:
Paul Ferraro
  • Field Details

    • ZERO

      static final DoubleSupplier ZERO
      A supplier that always returns zero.
  • Method Details

    • thenAccept

      default Runner thenAccept(DoubleConsumer consumer)
      Returns a runner that accepts the value returned by this supplier via the specified consumer.
      Parameters:
      consumer - a integer consumer
      Returns:
      a runner that accepts the value returned by this supplier via the specified consumer.
    • thenApply

      default <V> Supplier<V> thenApply(DoubleFunction<V> function)
      Returns a supplier that applies the specified function to the value returned by this supplier.
      Type Parameters:
      V - the mapped value type
      Parameters:
      function - a mapping function
      Returns:
      a supplier that applies the specified function to the value returned by this supplier.
    • thenApplyAsDouble

      default DoubleSupplier thenApplyAsDouble(DoubleUnaryOperator operator)
      Returns a supplier that applies the specified operator to the value returned by this supplier.
      Parameters:
      operator - a mapping operator
      Returns:
      a supplier that applies the specified operator to the value returned by this supplier.
    • thenApplyAsInt

      default IntSupplier thenApplyAsInt(DoubleToIntFunction function)
      Returns a supplier that applies the specified function to the value returned by this supplier.
      Parameters:
      function - a mapping function
      Returns:
      a supplier that applies the specified function to the value returned by this supplier.
    • thenApplyAsLong

      default LongSupplier thenApplyAsLong(DoubleToLongFunction function)
      Returns a supplier that applies the specified function to the value returned by this supplier.
      Parameters:
      function - a mapping function
      Returns:
      a supplier that applies the specified function to the value returned by this supplier.
    • thenTest

      default BooleanSupplier thenTest(DoublePredicate predicate)
      Returns a supplier that applies the specified predicate to the value returned by this supplier.
      Parameters:
      predicate - a predicate
      Returns:
      a supplier that applies the specified predicate to the value returned by this supplier.
    • boxed

      default Supplier<Double> boxed()
      Returns a boxed version of this supplier.
      Returns:
      a boxed version of this supplier.
    • handle

      Returns a new supplier that delegates to this supplier using the specified exception handler.
      Parameters:
      handler - an exception handler
      Returns:
      a new supplier that delegates to this supplier using the specified exception handler.
    • of

      static DoubleSupplier of(double value)
      Returns a supplier of the specified value.
      Parameters:
      value - the supplied value
      Returns:
      a supplier of the specified value.