xmlrpc02.py (pymol-v2.1.0.tar.bz2) | : | xmlrpc02.py (pymol-open-source-2.2.0) | ||
---|---|---|---|---|
""" simple demo for using the PyMol RPC server | """ simple demo for using the PyMol RPC server | |||
Author: Greg Landrum (Landrum@RationalDiscovery.com) | Author: Greg Landrum (Landrum@RationalDiscovery.com) | |||
Created: February 2004 | Created: February 2004 | |||
$LastChangedDate: 2017-12-05 19:37:16 +0100 (Tue, 05 Dec 2017) $ | $LastChangedDate$ | |||
License: PyMol | License: PyMol | |||
Requires: | Requires: | |||
- a python xmlrpclib distribution containing the SimpleXMLRPCServer | - a python xmlrpclib distribution containing the SimpleXMLRPCServer | |||
module (1.0 or greater should be fine) | module (1.0 or greater should be fine) | |||
RD Version: $Rev: 4183 $ | RD Version: $Rev$ | |||
""" | """ | |||
try: | try: | |||
import xmlrpclib | import xmlrpclib | |||
except ImportError: | except ImportError: | |||
import xmlrpc.client as xmlrpclib | import xmlrpc.client as xmlrpclib | |||
def startServer(host='localhost',startPort=9123,nToTry=5): | def startServer(host='localhost',startPort=9123,nToTry=5): | |||
done = 0 | done = 0 | |||
offset = 0 | offset = 0 | |||
while offset < nToTry: | while offset < nToTry: | |||
End of changes. 2 change blocks. | ||||
2 lines changed or deleted | 2 lines changed or added |