diff -r 91b171fdd85f -r d51e810107ec RefactoringRope/Documentation/source/Plugin_Refactoring_Rope.RefactoringRope.JsonClient.html --- a/RefactoringRope/Documentation/source/Plugin_Refactoring_Rope.RefactoringRope.JsonClient.html Fri Oct 11 19:05:23 2019 +0200 +++ b/RefactoringRope/Documentation/source/Plugin_Refactoring_Rope.RefactoringRope.JsonClient.html Fri Oct 11 19:05:59 2019 +0200 @@ -18,153 +18,200 @@ </style> </head> -<body><a NAME="top" ID="top"></a> +<body> +<a NAME="top" ID="top"></a> <h1>Plugin_Refactoring_Rope.RefactoringRope.JsonClient</h1> + <p> Module implementing the JSON based client base class. </p> <h3>Global Attributes</h3> + <table> <tr><td>None</td></tr> </table> <h3>Classes</h3> + <table> + <tr> <td><a href="#JsonClient">JsonClient</a></td> <td>Class implementing the JSON based client base class.</td> </tr> </table> <h3>Functions</h3> + <table> <tr><td>None</td></tr> </table> -<hr /><hr /> +<hr /> +<hr /> <a NAME="JsonClient" ID="JsonClient"></a> <h2>JsonClient</h2> + <p> Class implementing the JSON based client base class. </p> <h3>Derived from</h3> object <h3>Class Attributes</h3> + <table> <tr><td>None</td></tr> </table> <h3>Class Methods</h3> + <table> <tr><td>None</td></tr> </table> <h3>Methods</h3> + <table> + <tr> <td><a href="#JsonClient.__init__">JsonClient</a></td> <td>Constructor</td> -</tr><tr> +</tr> +<tr> <td><a href="#JsonClient.__receiveJson">__receiveJson</a></td> <td>Private method to receive a JSON encode command and data from the server.</td> -</tr><tr> +</tr> +<tr> <td><a href="#JsonClient.handleCall">handleCall</a></td> <td>Public method to handle a method call from the server.</td> -</tr><tr> +</tr> +<tr> <td><a href="#JsonClient.poll">poll</a></td> <td>Public method to check and receive one message (if available).</td> -</tr><tr> +</tr> +<tr> <td><a href="#JsonClient.run">run</a></td> <td>Public method implementing the main loop of the client.</td> -</tr><tr> +</tr> +<tr> <td><a href="#JsonClient.sendJson">sendJson</a></td> <td>Public method to send a single refactoring command to the server.</td> </tr> </table> <h3>Static Methods</h3> + <table> <tr><td>None</td></tr> </table> + <a NAME="JsonClient.__init__" ID="JsonClient.__init__"></a> <h4>JsonClient (Constructor)</h4> <b>JsonClient</b>(<i>host, port, idString=""</i>) + <p> Constructor -</p><dl> +</p> +<dl> + <dt><i>host</i> (str)</dt> <dd> ip address the background service is listening -</dd><dt><i>port</i> (int)</dt> +</dd> +<dt><i>port</i> (int)</dt> <dd> port of the background service -</dd><dt><i>idString</i> (str)</dt> +</dd> +<dt><i>idString</i> (str)</dt> <dd> assigned client id to be sent back to the server in order to identify the connection </dd> -</dl><a NAME="JsonClient.__receiveJson" ID="JsonClient.__receiveJson"></a> +</dl> +<a NAME="JsonClient.__receiveJson" ID="JsonClient.__receiveJson"></a> <h4>JsonClient.__receiveJson</h4> <b>__receiveJson</b>(<i></i>) + <p> Private method to receive a JSON encode command and data from the server. -</p><dl> +</p> +<dl> <dt>Returns:</dt> <dd> tuple containing the received command and a dictionary containing the associated data </dd> -</dl><dl> +</dl> +<dl> <dt>Return Type:</dt> <dd> tuple of (str, dict) </dd> -</dl><a NAME="JsonClient.handleCall" ID="JsonClient.handleCall"></a> +</dl> +<a NAME="JsonClient.handleCall" ID="JsonClient.handleCall"></a> <h4>JsonClient.handleCall</h4> <b>handleCall</b>(<i>method, params</i>) + <p> Public method to handle a method call from the server. -</p><p> +</p> +<p> Note: This is an empty implementation that must be overridden in derived classes. -</p><dl> +</p> +<dl> + <dt><i>method</i> (str)</dt> <dd> requested method name -</dd><dt><i>params</i> (dict)</dt> +</dd> +<dt><i>params</i> (dict)</dt> <dd> dictionary with method specific parameters </dd> -</dl><a NAME="JsonClient.poll" ID="JsonClient.poll"></a> +</dl> +<a NAME="JsonClient.poll" ID="JsonClient.poll"></a> <h4>JsonClient.poll</h4> <b>poll</b>(<i>waitMethod=""</i>) + <p> Public method to check and receive one message (if available). -</p><dl> +</p> +<dl> + <dt><i>waitMethod</i> (str)</dt> <dd> name of a method to wait for </dd> -</dl><dl> +</dl> +<dl> <dt>Returns:</dt> <dd> dictionary containing the data of the waited for method </dd> -</dl><dl> +</dl> +<dl> <dt>Return Type:</dt> <dd> dict </dd> -</dl><a NAME="JsonClient.run" ID="JsonClient.run"></a> +</dl> +<a NAME="JsonClient.run" ID="JsonClient.run"></a> <h4>JsonClient.run</h4> <b>run</b>(<i></i>) + <p> Public method implementing the main loop of the client. -</p><a NAME="JsonClient.sendJson" ID="JsonClient.sendJson"></a> +</p> +<a NAME="JsonClient.sendJson" ID="JsonClient.sendJson"></a> <h4>JsonClient.sendJson</h4> <b>sendJson</b>(<i>command, params</i>) + <p> Public method to send a single refactoring command to the server. -</p><dl> +</p> +<dl> + <dt><i>command</i> (str)</dt> <dd> command name to be sent -</dd><dt><i>params</i> (dict)</dt> +</dd> +<dt><i>params</i> (dict)</dt> <dd> dictionary of named parameters for the command </dd>