Definition at line 61 of file _utilities.py.
◆ __init__()
def grpc._utilities._ChannelReadyFuture.__init__ |
( |
|
self, |
|
|
|
channel |
|
) |
| |
◆ __del__()
def grpc._utilities._ChannelReadyFuture.__del__ |
( |
|
self | ) |
|
◆ _block()
def grpc._utilities._ChannelReadyFuture._block |
( |
|
self, |
|
|
|
timeout |
|
) |
| |
|
private |
◆ _update()
def grpc._utilities._ChannelReadyFuture._update |
( |
|
self, |
|
|
|
connectivity |
|
) |
| |
|
private |
◆ add_done_callback()
def grpc._utilities._ChannelReadyFuture.add_done_callback |
( |
|
self, |
|
|
|
fn |
|
) |
| |
Adds a function to be called at completion of the computation.
The callback will be passed this Future object describing the outcome
of the computation. Callbacks will be invoked after the future is
terminated, whether successfully or not.
If the computation has already completed, the callback will be called
immediately.
Exceptions raised in the callback will be logged at ERROR level, but
will not terminate any threads of execution.
Args:
fn: A callable taking this Future object as its single parameter.
Reimplemented from grpc.Future.
Definition at line 147 of file _utilities.py.
◆ cancel()
def grpc._utilities._ChannelReadyFuture.cancel |
( |
|
self | ) |
|
Attempts to cancel the computation.
This method does not block.
Returns:
bool:
Returns True if the computation was canceled.
Returns False under all other circumstances, for example:
1. computation has begun and could not be canceled.
2. computation has finished
3. computation is scheduled for execution and it is impossible
to determine its state without blocking.
Reimplemented from grpc.Future.
Definition at line 107 of file _utilities.py.
◆ cancelled()
def grpc._utilities._ChannelReadyFuture.cancelled |
( |
|
self | ) |
|
Describes whether the computation was cancelled.
This method does not block.
Returns:
bool:
Returns True if the computation was cancelled before its result became
available.
Returns False under all other circumstances, for example:
1. computation was not cancelled.
2. computation's result is available.
Reimplemented from grpc.Future.
Definition at line 126 of file _utilities.py.
◆ done()
def grpc._utilities._ChannelReadyFuture.done |
( |
|
self | ) |
|
Describes whether the computation has taken place.
This method does not block.
Returns:
bool:
Returns True if the computation already executed or was cancelled.
Returns False if the computation is scheduled for execution or
currently executing.
This is exactly opposite of the running() method's result.
Reimplemented from grpc.Future.
Definition at line 134 of file _utilities.py.
◆ exception()
def grpc._utilities._ChannelReadyFuture.exception |
( |
|
self, |
|
|
|
timeout = None |
|
) |
| |
Return the exception raised by the computation.
This method may return immediately or may block.
Args:
timeout: The length of time in seconds to wait for the computation to
terminate or be cancelled. If None, the call will block until the
computations's termination.
Returns:
The exception raised by the computation, or None if the computation
did not raise an exception.
Raises:
FutureTimeoutError: If a timeout value is passed and the computation
does not terminate within the allotted time.
FutureCancelledError: If the computation was cancelled.
Reimplemented from grpc.Future.
Definition at line 141 of file _utilities.py.
◆ result()
def grpc._utilities._ChannelReadyFuture.result |
( |
|
self, |
|
|
|
timeout = None |
|
) |
| |
Returns the result of the computation or raises its exception.
This method may return immediately or may block.
Args:
timeout: The length of time in seconds to wait for the computation to
finish or be cancelled. If None, the call will block until the
computations's termination.
Returns:
The return value of the computation.
Raises:
FutureTimeoutError: If a timeout value is passed and the computation
does not terminate within the allotted time.
FutureCancelledError: If the computation was cancelled.
Exception: If the computation raised an exception, this call will
raise the same exception.
Reimplemented from grpc.Future.
Definition at line 138 of file _utilities.py.
◆ running()
def grpc._utilities._ChannelReadyFuture.running |
( |
|
self | ) |
|
Describes whether the computation is taking place.
This method does not block.
Returns:
Returns True if the computation is scheduled for execution or
currently executing.
Returns False if the computation already executed or was cancelled.
Reimplemented from grpc.Future.
Definition at line 130 of file _utilities.py.
◆ start()
def grpc._utilities._ChannelReadyFuture.start |
( |
|
self | ) |
|
◆ traceback()
def grpc._utilities._ChannelReadyFuture.traceback |
( |
|
self, |
|
|
|
timeout = None |
|
) |
| |
Access the traceback of the exception raised by the computation.
This method may return immediately or may block.
Args:
timeout: The length of time in seconds to wait for the computation
to terminate or be cancelled. If None, the call will block until
the computation's termination.
Returns:
The traceback of the exception raised by the computation, or None
if the computation did not raise an exception.
Raises:
FutureTimeoutError: If a timeout value is passed and the computation
does not terminate within the allotted time.
FutureCancelledError: If the computation was cancelled.
Reimplemented from grpc.Future.
Definition at line 144 of file _utilities.py.
◆ _cancelled
grpc._utilities._ChannelReadyFuture._cancelled |
|
private |
◆ _channel
grpc._utilities._ChannelReadyFuture._channel |
|
private |
◆ _condition
grpc._utilities._ChannelReadyFuture._condition |
|
private |
◆ _done_callbacks
grpc._utilities._ChannelReadyFuture._done_callbacks |
|
private |
◆ _matured
grpc._utilities._ChannelReadyFuture._matured |
|
private |
The documentation for this class was generated from the following file: