If a non-multiplexed processor connects to the server and wants to communicate, use the given processor to handle it. This mechanism allows servers to upgrade from non-multiplexed to multiplexed in a backwards-compatible way and still handle old clients.
(self, processor)
| 28 | self.services = {} |
| 29 | |
| 30 | def registerDefault(self, processor): |
| 31 | """ |
| 32 | If a non-multiplexed processor connects to the server and wants to |
| 33 | communicate, use the given processor to handle it. This mechanism |
| 34 | allows servers to upgrade from non-multiplexed to multiplexed in a |
| 35 | backwards-compatible way and still handle old clients. |
| 36 | """ |
| 37 | self.defaultProcessor = processor |
| 38 | |
| 39 | def registerProcessor(self, serviceName, processor): |
| 40 | self.services[serviceName] = processor |
no outgoing calls