Пример #1
0
    def __init__(self, host, port):
        """create a XML-RPC server

Takes two initial inputs:
    host  -- hostname of XML-RPC server host
    port  -- port number for server requests
        """
        Server.__init__(self)
        SimpleXMLRPCDispatcher.__init__(self, allow_none=False, encoding=None)

        self._installSocket(host, port)
        self._activeProcesses = {}  # { fd : pid }
Пример #2
0
    def __init__(self, host, port):
        '''create a XML-RPC server

Takes two initial inputs:
    host  -- hostname of XML-RPC server host
    port  -- port number for server requests
        '''
        Server.__init__(self)
        SimpleXMLRPCDispatcher.__init__(self, allow_none=False, encoding=None)

        self._installSocket(host, port)
        self._activeProcesses = {}  #{ fd : pid }
Пример #3
0
    def serve(self):
        """enter the select loop... and wait for service requests"""

        timeout = 5
        Server.serve(self, 5)
Пример #4
0
    def activate(self):
        """install callbacks"""

        Server.activate(self)
        self._selector.notifyOnReadReady(self._socket, self._onConnection)
        self._selector.notifyWhenIdle(self._onSelectorIdle)
Пример #5
0
    def serve(self):
        """enter the select loop... and wait for service requests"""

        timeout = 5
        Server.serve(self, 5)
Пример #6
0
    def activate(self):
        """install callbacks"""

        Server.activate(self)
        self._selector.notifyOnReadReady(self._socket, self._onConnection)
        self._selector.notifyWhenIdle(self._onSelectorIdle)