Exemple #1
0
class GreenMSRPSession(MSRPSession):

    def __init__(self, msrptransport, accept_types=['*']):
        MSRPSession.__init__(self, msrptransport, accept_types)
        self.incoming = ValueQueue()

    def receive_chunk(self):
        return self.incoming.wait()

    def _on_incoming_cb(self, value=None, error=None):
        if error is not None:
            self.incoming.send_exception(error.type, error.value, error.tb)
        else:
            self.incoming.send(value)
Exemple #2
0
 def __init__(self, msrptransport, accept_types=['*']):
     MSRPSession.__init__(self, msrptransport, accept_types)
     self.incoming = ValueQueue()