Class DelayStrategy$


  • public class DelayStrategy$
    extends java.lang.Object
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static DelayStrategy$ MODULE$
      Static reference to the singleton instance of this Scala object.
    • Constructor Summary

      Constructors 
      Constructor Description
      DelayStrategy$()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      DelayStrategy<java.lang.Object> fixedDelay​(scala.concurrent.duration.FiniteDuration delay)
      Fixed delay strategy, always returns constant delay for any element.
      <T> DelayStrategy<T> linearIncreasingDelay​(scala.concurrent.duration.FiniteDuration increaseStep, scala.Function1<T,​java.lang.Object> needsIncrease, scala.concurrent.duration.FiniteDuration initialDelay, scala.concurrent.duration.Duration maxDelay)
      Strategy with linear increasing delay.
      <T> scala.concurrent.duration.FiniteDuration linearIncreasingDelay$default$3()  
      <T> scala.concurrent.duration.Duration linearIncreasingDelay$default$4()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • MODULE$

        public static final DelayStrategy$ MODULE$
        Static reference to the singleton instance of this Scala object.
    • Constructor Detail

      • DelayStrategy$

        public DelayStrategy$()
    • Method Detail

      • fixedDelay

        public DelayStrategy<java.lang.Object> fixedDelay​(scala.concurrent.duration.FiniteDuration delay)
        Fixed delay strategy, always returns constant delay for any element.
        Parameters:
        delay - value of the delay
      • linearIncreasingDelay

        public <T> DelayStrategy<T> linearIncreasingDelay​(scala.concurrent.duration.FiniteDuration increaseStep,
                                                          scala.Function1<T,​java.lang.Object> needsIncrease,
                                                          scala.concurrent.duration.FiniteDuration initialDelay,
                                                          scala.concurrent.duration.Duration maxDelay)
        Strategy with linear increasing delay. It starts with initialDelay for each element, increases by increaseStep every time when needsIncrease returns true up to maxDelay, when needsIncrease returns false it resets to initialDelay.
        Parameters:
        increaseStep - step by which delay is increased
        needsIncrease - if true delay increases, if false delay resets to initialDelay
        initialDelay - initial delay for each of elements
        maxDelay - limits maximum delay
      • linearIncreasingDelay$default$3

        public <T> scala.concurrent.duration.FiniteDuration linearIncreasingDelay$default$3()
      • linearIncreasingDelay$default$4

        public <T> scala.concurrent.duration.Duration linearIncreasingDelay$default$4()