|
|
|
@ -69,6 +69,14 @@ class LinphoneCommunicationSocket():
@@ -69,6 +69,14 @@ class LinphoneCommunicationSocket():
|
|
|
|
|
else: |
|
|
|
|
raise RuntimeError(answer["error"]) |
|
|
|
|
|
|
|
|
|
def call(self, sip_address): |
|
|
|
|
self.socket.send("call {sip_address}".format(sip_address=sip_address).encode("ascii")) |
|
|
|
|
answer = self._await_answer() |
|
|
|
|
if answer["status"]: |
|
|
|
|
return answer["data"][0].split(":", 1)[1].strip() |
|
|
|
|
else: |
|
|
|
|
raise RuntimeError(answer["error"]) |
|
|
|
|
|
|
|
|
|
def process_event(self): |
|
|
|
|
self.socket.send("pop-event".encode("ascii")) |
|
|
|
|
answer = self._await_answer() |
|
|
|
@ -150,3 +158,15 @@ class LinphoneCommunicationSocket():
@@ -150,3 +158,15 @@ class LinphoneCommunicationSocket():
|
|
|
|
|
print("dummy onLinphoneCallStreamsRunning") |
|
|
|
|
pass |
|
|
|
|
|
|
|
|
|
def onLinphoneCallOutgoingInit(self, event): |
|
|
|
|
print("dummy onLinphoneCallOutgoingInit") |
|
|
|
|
pass |
|
|
|
|
|
|
|
|
|
def onLinphoneCallOutgoingProgress(self, event): |
|
|
|
|
print("dummy onLinphoneCallOutgoingProgress") |
|
|
|
|
pass |
|
|
|
|
|
|
|
|
|
def onLinphoneCallOutgoingRinging(self, event): |
|
|
|
|
print("dummy onLinphoneCallOutgoingRinging") |
|
|
|
|
pass |
|
|
|
|
|
|
|
|
|