invokeWithTakeout<T extends TlObject> method
Invoke With Takeout.
ID: aca9fd2e
.
Implementation
Future<Result<T>> invokeWithTakeout<T extends TlObject>({
required int takeoutId,
required TlMethod query,
}) async {
// Preparing the request.
final request = InvokeWithTakeout(
takeoutId: takeoutId,
query: query,
);
// Invoke and wait for response.
final response = await invoke(request);
// Return the result.
return response._to<T>();
}