grpc: updates to wrapper classes to help write client code in a more simple way using the consolidated api, updated examples to used the wrapped client
This commit is contained in:
parent
38e162aec5
commit
917c45e70b
8 changed files with 196 additions and 235 deletions
|
@ -352,6 +352,10 @@ class CoreGrpcClient:
|
|||
response = self.stub.StopSession(request)
|
||||
return response.result
|
||||
|
||||
def add_session(self, session_id: int = None) -> wrappers.Session:
|
||||
session_id = self.create_session(session_id)
|
||||
return self.get_session(session_id)
|
||||
|
||||
def create_session(self, session_id: int = None) -> int:
|
||||
"""
|
||||
Create a session.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue