package jalview.ws; /** *

Title: JalviewX

*

Description: Jalview Re-engineered

*

Copyright: Copyright (c) 2004

*

Company: Dundee University

* @author not attributable * @version 1.0 * Commenced 14th January 2005, Jim Procter * Contains and depends on GPL-2 jemboss classes * see http://www.rfcgr.mrc.ac.uk/Software/EMBOSS/Jemboss/index.html */ /** * Philosophy * Jemboss webservices are implemented here as re-entrant synchronous SOAP * exchanges. It is up to the user of the class whether these exchanges * are executed in their own thread to effect background processing * functionality. * * Things to do * Standardise the exceptions (currently errors are output on stdout) * Allow server configuration * Throw away JembossParams and Jemboss dependence * Generalise results to return collections of objects - alignments, trees, annotations, etc. */ import java.net.*; import java.security.*; import java.util.*; import ext.jemboss.*; import ext.jemboss.soap.*; import jalview.datamodel.*; import jalview.io.*; public class Jemboss { private static ext.jemboss.JembossParams vamsas_server; public Jemboss() { // Set up default jalview-jemboss server properties // vamsas_server = new JembossParams(); vamsas_server.setCurrentMode("interactive"); System.out.println("Jemboss Server Init\n" + vamsas_server.serverDescription() + "\nUser Authorisation ? " + vamsas_server.getUseAuth() +"\n"); } /* public void updateServer(JembossParams props) { vamsas_server.updateJembossPropStrings ( props.getEmbossEnvironmentArray()); } */ private Hashtable uniquify(SequenceI[] sequences) { // Generate a safely named sequence set and a hash to recover the sequence names Hashtable map = new Hashtable(); for (int i=0; i