Module implementing the eric remote server.
None |
EricServer | Class implementing the eric remote server. |
None |
Class implementing the eric remote server.
None |
None |
EricServer | Constructor |
__acceptIdeConnection | Private method to accept the connection on the listening IDE server socket. |
__closeIdeConnection | Private method to close the connection to an eric-ide. |
__handleEchoRequest | Private method to handle an 'Echo' request. |
__handleRequest | Private method handling or dispatching the received requests. |
__handleServerRequest | Private method to handle a 'Server' request. |
__initializeIdeSocket | Private method to initialize and register the eric-ide server socket. |
__receiveBytes | Private method to receive the given length of bytes. |
__receiveJson | Private method to receive a JSON encoded command and data from the server. |
__registerInternalHandlers | Private method to register request handler categories of this class. |
__serviceIdeConnection | Private method to service the eric-ide connection. |
__shutdown | Private method to shut down the server. |
__unregisterIdeSocket | Private method to unregister the eric-ide server socket because only one connection is allowed. |
getSelector | Public method to get a reference to the selector object. |
isSocketClosed | Public method to check, if a given socket is closed. |
receiveJsonCommand | Public method to receive a JSON encoded command and data. |
registerRequestHandler | Public method to register a request handler method for the given request category. |
run | Public method implementing the remote server main loop. |
sendJson | Public method to send a single refactoring command to the server. |
sendJsonCommand | Public method to send a JSON encoded command/response via a given socket. |
unregisterRequestHandler | Public method to unregister a handler for the given request category. |
None |
Constructor
Private method to accept the connection on the listening IDE server socket.
Private method to close the connection to an eric-ide.
Private method to handle an 'Echo' request.
Private method handling or dispatching the received requests.
Private method to handle a 'Server' request.
Private method to initialize and register the eric-ide server socket.
Private method to receive the given length of bytes.
Private method to receive a JSON encoded command and data from the server.
Private method to register request handler categories of this class.
Private method to service the eric-ide connection.
Private method to shut down the server.
Private method to unregister the eric-ide server socket because only one connection is allowed.
Public method to get a reference to the selector object.
Public method to check, if a given socket is closed.
Public method to receive a JSON encoded command and data.
Public method to register a request handler method for the given request category.
Public method implementing the remote server main loop.
Exiting the inner loop, that receives and dispatches the requests, will cause the server to stop and exit. The main loop handles these requests.
Public method to send a single refactoring command to the server.
Public method to send a JSON encoded command/response via a given socket.
Public method to unregister a handler for the given request category.
Note: This method will raise a KeyError exception in case the request category has not been registered and ignoreError is False (the default).