Exemple #1
0
 def insert_outbox_file(self, filename, description='', result_defer=None, keep_alive=True):
     from transport.udp import udp_session
     self.outboxQueue.insert(0, (filename, description, result_defer, keep_alive))
     if _Debug:
         lg.out(18, 'udp_file_queue.insert_outbox_file %s for %s : %s, streams=%d, queue=%d' % (
             os.path.basename(filename), self.session.peer_id, description, len(self.streams), len(self.outboxQueue)))
     udp_session.process_sessions([self.session, ])
 def insert_outbox_file(
         self,
         filename,
         description='',
         result_defer=None,
         single=False):
     from transport.udp import udp_session
     self.outboxQueue.insert(
         0, (filename, description, result_defer, single))
     if _Debug:
         lg.out(18, 'udp_file_queue.insert_outbox_file %s for %s : %s, streams=%d, queue=%d' % (
             os.path.basename(filename), self.session.peer_id, description, len(
                 self.streams), len(self.outboxQueue)))
     udp_session.process_sessions([self.session, ])
Exemple #3
0
 def append_outbox_file(self,
                        filename,
                        description='',
                        result_defer=None,
                        single=False):
     from transport.udp import udp_session
     self.outboxQueue.append((filename, description, result_defer, single))
     if _Debug:
         lg.out(
             18,
             'udp_file_queue.append_outbox_file %s for %s : %s, streams=%d, queue=%d'
             % (os.path.basename(filename), self.session.peer_id,
                description, len(self.streams), len(self.outboxQueue)))
     udp_session.process_sessions([
         self.session,
     ])