Skip to content

Instantly share code, notes, and snippets.

@egonw
Created November 4, 2008 19:23
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save egonw/22185 to your computer and use it in GitHub Desktop.
Save egonw/22185 to your computer and use it in GitHub Desktop.
xmpp.connect();
service = xmpp.getService("cdk.ws1.bmc.uu.se");
service.discoverSync(5000);
service.getFunctions();
f = service.getFunction("calculateMass");
ios = f.getIoSchemataSync(90000);
iof = xmpp.getIoFactory(ios);
smiDoc = iof.createSmilesDocument();
smiDoc.setSmiles("CCC");
result = f.invokeSync(smiDoc.toString(), 900000);
obj = iof.getOutputObject(result);
js.print("Mass: " + obj.getStringValue())
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment