Disembl and Jronn web services work. Modified to produce raw scores Globplot script...
[jabaws.git] / webservices / compbio / ws / server / AAConWS.java
index a32533f..433728b 100644 (file)
@@ -2,6 +2,7 @@ package compbio.ws.server;
 \r
 import java.io.File;\r
 import java.util.Arrays;\r
+import java.util.HashMap;\r
 import java.util.HashSet;\r
 import java.util.List;\r
 \r
@@ -11,7 +12,7 @@ import javax.xml.ws.WebServiceContext;
 \r
 import org.apache.log4j.Logger;\r
 \r
-import compbio.data.msa.Annotation;\r
+import compbio.data.msa.SequenceAnnotation;\r
 import compbio.data.sequence.FastaSequence;\r
 import compbio.data.sequence.Score;\r
 import compbio.engine.AsyncExecutor;\r
@@ -33,8 +34,8 @@ import compbio.metadata.WrongParameterException;
 import compbio.runner.Util;\r
 import compbio.runner.conservation.AACon;\r
 \r
-@WebService(endpointInterface = "compbio.data.msa.Annotation", targetNamespace = "http://msa.data.compbio/01/12/2010/", serviceName = "AAConWS")\r
-public class AAConWS implements Annotation<AACon> {\r
+@WebService(endpointInterface = "compbio.data.msa.SequenceAnnotation", targetNamespace = "http://msa.data.compbio/01/12/2010/", serviceName = "AAConWS")\r
+public class AAConWS implements SequenceAnnotation<AACon> {\r
 \r
        // Ask for resource injection\r
        @Resource\r
@@ -58,15 +59,17 @@ public class AAConWS implements Annotation<AACon> {
        }\r
 \r
        @Override\r
-       public HashSet<Score> getAnnotation(String jobId)\r
+       public HashMap<String, HashSet<Score>> getAnnotation(String jobId)\r
                        throws ResultNotAvailableException {\r
                WSUtil.validateJobId(jobId);\r
                AsyncExecutor asyncEngine = Configurator.getAsyncEngine(jobId);\r
                ConfiguredExecutable<AACon> aacon = (ConfiguredExecutable<AACon>) asyncEngine\r
                                .getResults(jobId);\r
                HashSet<Score> mas = aacon.getResults();\r
+               HashMap<String, HashSet<Score>> result = new HashMap<String, HashSet<Score>>();\r
+               result.put("Alignment", mas);\r
                log.trace(jobId + " getConservation : " + mas);\r
-               return mas;\r
+               return result;\r
        }\r
        /*\r
         * @SuppressWarnings("unchecked") public JalviewAnnotation\r