def recv(self): buf = self.recv_raw() if buf is None: return None frame = Frame.parse(buf, parse_prefix=False) trace("\033[36m<-- %r\033[m" % frame) return frame
def process(self, buf): frame = Frame.parse(buf, parse_prefix=False) trace("\033[36m<-- %r\033[m" % frame) return self.process_frame(frame)
def sendv(self, *args): buf = Frame.join(args) return self.send_raw(buf)