Beispiel #1
0
    def welcome(self, publisher, nodeId, subId):
        try:
            welcomeMsg = ChatMsg()
            welcomeMsg.username = self.username
            welcomeMsg.type = ChatMsg.JOINED

            greeting = self.publisher.prepareMessage("ChatMsg", welcomeMsg)
            greeting.setReceiver(subId)
            greeting.putMeta("subscriber", self.subscriber.getUUID())
            self.publisher.send(greeting)
        except BaseException as e:
            traceback.print_exc(file=sys.stdout)
Beispiel #2
0
    def welcome(self, publisher, nodeId, subId):
        try:
            welcomeMsg = ChatMsg()
            welcomeMsg.username = self.username
            welcomeMsg.type = ChatMsg.JOINED

            greeting = self.publisher.prepareMessage("ChatMsg", welcomeMsg)
            greeting.setReceiver(subId)
            greeting.putMeta("subscriber", self.subscriber.getUUID())
            self.publisher.send(greeting)
        except BaseException as e:
            traceback.print_exc(file=sys.stdout)