MCPcopy Create free account
hub / github.com/ActiveState/code / client

Method client

recipes/Python/496872_zservicepy/recipe-496872.py:105–112  ·  view source on GitHub ↗

Takes care of incoming connections.

(self, sock)

Source from the content-addressed store, hash-verified

103 thread.start_new_thread(self.processor, ())
104
105 def client(self, sock):
106 'Takes care of incoming connections.'
107 name, args, kwargs = self.recv(sock)
108 sync = z_sync.Sync(2)
109 item = [name, args, kwargs, sync]
110 self.queue.put(item)
111 sync.sync()
112 self.send(sock, item[4])
113
114 def processor(self):
115 'Processes clients\' requests in sequential order.'

Callers

nothing calls this directly

Calls 4

syncMethod · 0.95
recvMethod · 0.45
putMethod · 0.45
sendMethod · 0.45

Tested by

no test coverage detected