class WebSocket(tornado.websocket.WebSocketHandler): socketManager = None def check_origin(self, origin): print(origin) return True def add(self): pass def remove(self): pass def open(self): self.socketManager = SocketManager() self.add() logger() def on_message(self, message): self.socketManager.addMessage(self, message) def on_close(self): self.remove() logger()
def open(self): self.socketManager = SocketManager() self.add() logger()