What is the closest equivalent to Java's Future<T>
in C#?
For example, what would the closest reconstruction of the following be in C#:
public class FutureMethodCall implements Future {
private Future<APIResponse> methodCall;
public boolean cancel(boolean mayInterruptIfRunning) {
return this.methodCall.cancel(mayInterruptIfRunning);
}
public APIResponse get() throws ExecutionException, InterruptedException {
return this.methodCall.get();
}
...
}
Thanks in advance!