def __init__(self, client, server, node): """ Create Node """ # inherit pubsub send function self._send = inherit(client.iqset, 'pubsub', to=server) #: node name self.name = node
def __init__(self, socket, iq, sid, blocksize, stream): """ Create IBBSocket to link a socket with XMPP """ self.sid = sid self._socket = socket self._socket.signals['read'].connect(self.read) self._send = inherit(iq, xmlns=NS_IBB, sid=sid, xmppstream=stream) self._bs = int(blocksize) self._send_seq = 0 self._recv_seq = 0