- java.lang.Object
-
- com.github.tix320.skimp.api.interval.IntervalRepeater<T>
-
public final class IntervalRepeater<T> extends Object
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description TdoNext()Optional<T>doUntilSuccess(int maxCount)static IntervalRepeater<None>of(Interval interval, CheckedRunnable runnable)static <T> IntervalRepeater<T>of(Interval interval, CheckedSupplier<T> runnable)
-
-
-
Method Detail
-
doNext
public T doNext() throws ThreadInterruptedException, ActionFailedException
-
doUntilSuccess
public Optional<T> doUntilSuccess(int maxCount) throws ThreadInterruptedException
- Throws:
ThreadInterruptedException
-
of
public static <T> IntervalRepeater<T> of(Interval interval, CheckedSupplier<T> runnable)
-
of
public static IntervalRepeater<None> of(Interval interval, CheckedRunnable runnable)
-
-