class Futureimport { Future } from "https://deno.land/x/gauntlet@v0.0.9/imports/tmonad.ts"; Future ConstructorsnewFuture(promise: Promise<T>)Type ParametersTPropertiesprotected_executor: () => Promise<Result<T, Error>>Executor protected_promise: Promise<T>Promise Methodsextract(): Promise<T>Get the value from the future (can throw) flatMap<U>(f: (val: T) => Future<U>): Future<U>Flatmap flatMapErr<U>(f: (err: Error) => Future<U>): Future<U | T>Flatmap on failure flatMatch<U>(matchObject: FlatMatch<T, U>): Future<U>FlatMatch getOrElse<R>(defaultValue: R): Promise<T | R>Get the value from the future, but if it's a failure, return the defaultValue isFailure(): Promise<boolean>Is a failure isSuccess(): Promise<boolean>Is a success map<U>(f: (val: T) => Promise<U>): Future<U>Map mapErr<U>(f: (err: any) => Promise<U>): Future<U | T>Map on error match<U>(matchObject: Match<T, U>): Future<U>Match run<U>(gen: Generator<Promise<T> | undefined, Promise<U>, T>): Future<U>Run a series of futures into a generator toOption(): Promise<Option<T>>Transform into Option toResult(): Promise<Result<T, Error>>Transform into Result