CompletableFuture<T>.delayed constructor

  1. @Deprecated("CompletableFuture will be removed in 2.0.0. " "Use ResultFuture with Future.delayed instead.\n" "See package:my_utility/async/result_future.dart")
CompletableFuture<T>.delayed(
  1. Duration duration, [
  2. FutureOrResultCallback<T>? computation
])

Same as Future.delayed.

Implementation

@Deprecated(
  "CompletableFuture will be removed in 2.0.0. "
  "Use ResultFuture with Future.delayed instead.\n"
  "See package:my_utility/async/result_future.dart",
)
factory CompletableFuture.delayed(
  Duration duration, [
  FutureOrResultCallback<T>? computation,
]) {
  return CompletableFuture.fromFuture(Future.delayed(duration, computation));
}