Public Member Functions | Private Member Functions | Private Attributes | List of all members
grpc_testing._time.StrictRealTime Class Reference
Inheritance diagram for grpc_testing._time.StrictRealTime:
Inheritance graph
[legend]

Public Member Functions

def __init__ (self)
 
def call_at (self, behavior, time)
 
def call_in (self, behavior, delay)
 
def sleep_for (self, duration)
 
def sleep_until (self, time)
 
def time (self)
 

Private Member Functions

def _activity (self)
 
def _call_at (self, behavior, time)
 
def _ensure_called_through (self, time)
 

Private Attributes

 _active
 
 _calling
 
 _state
 

Detailed Description

Definition at line 128 of file _time.py.

Constructor & Destructor Documentation

◆ __init__()

def grpc_testing._time.StrictRealTime.__init__ (   self)

Definition at line 130 of file _time.py.

Member Function Documentation

◆ _activity()

def grpc_testing._time.StrictRealTime._activity (   self)
private

Definition at line 135 of file _time.py.

◆ _call_at()

def grpc_testing._time.StrictRealTime._call_at (   self,
  behavior,
  time 
)
private

Definition at line 161 of file _time.py.

◆ _ensure_called_through()

def grpc_testing._time.StrictRealTime._ensure_called_through (   self,
  time 
)
private

Definition at line 154 of file _time.py.

◆ call_at()

def grpc_testing._time.StrictRealTime.call_at (   self,
  behavior,
  time 
)
Adds a behavior to be called at a specific time.

Args:
  behavior: A behavior to be called with no arguments.
  time: The test time at which to call the behavior.

Returns:
  A grpc.Future with which the call of the behavior may be cancelled
    before it is executed.

Reimplemented from grpc_testing.Time.

Definition at line 178 of file _time.py.

◆ call_in()

def grpc_testing._time.StrictRealTime.call_in (   self,
  behavior,
  delay 
)
Adds a behavior to be called after some time.

Args:
  behavior: A behavior to be called with no arguments.
  delay: A duration of time in seconds after which to call the behavior.

Returns:
  A grpc.Future with which the call of the behavior may be cancelled
    before it is executed.

Reimplemented from grpc_testing.Time.

Definition at line 175 of file _time.py.

◆ sleep_for()

def grpc_testing._time.StrictRealTime.sleep_for (   self,
  duration 
)
Blocks for some length of test time.

Args:
  duration: A duration of test time in seconds for which to block.

Reimplemented from grpc_testing.Time.

Definition at line 181 of file _time.py.

◆ sleep_until()

def grpc_testing._time.StrictRealTime.sleep_until (   self,
  time 
)
Blocks until some test time.

Args:
  time: The test time until which to block.

Reimplemented from grpc_testing.Time.

Definition at line 186 of file _time.py.

◆ time()

def grpc_testing._time.StrictRealTime.time (   self)
Accesses the current test time.

Returns:
  The current test time (over which this object has authority).

Reimplemented from grpc_testing.Time.

Definition at line 172 of file _time.py.

Member Data Documentation

◆ _active

grpc_testing._time.StrictRealTime._active
private

Definition at line 132 of file _time.py.

◆ _calling

grpc_testing._time.StrictRealTime._calling
private

Definition at line 133 of file _time.py.

◆ _state

grpc_testing._time.StrictRealTime._state
private

Definition at line 131 of file _time.py.


The documentation for this class was generated from the following file:


grpc
Author(s):
autogenerated on Fri May 16 2025 03:03:40