JWS-120 Fixes the exception raised by the ChunkHolder method in GenericMetadataServic...
authorFábio Madeira <fmmarquesmadeira@dundee.ac.uk>
Fri, 26 May 2017 16:19:11 +0000 (17:19 +0100)
committerFábio Madeira <fmmarquesmadeira@dundee.ac.uk>
Fri, 26 May 2017 17:50:35 +0000 (18:50 +0100)
webservices/compbio/ws/server/DisemblWS.java
webservices/compbio/ws/server/GlobPlotWS.java
webservices/compbio/ws/server/IUPredWS.java

index bf75828..bb664c2 100644 (file)
@@ -18,6 +18,7 @@
 package compbio.ws.server;\r
 \r
 import java.util.List;\r
+import java.io.File;\r
 \r
 import javax.jws.WebService;\r
 \r
@@ -33,6 +34,9 @@ import compbio.metadata.Preset;
 import compbio.metadata.UnsupportedRuntimeException;\r
 import compbio.metadata.WrongParameterException;\r
 import compbio.runner.disorder.Disembl;\r
+import compbio.engine.Configurator;\r
+import compbio.runner.conservation.AACon;\r
+import compbio.metadata.ChunkHolder;\r
 \r
 @WebService(endpointInterface = "compbio.data.msa.SequenceAnnotation", targetNamespace = JABAService.V2_SERVICE_NAMESPACE, serviceName = "DisemblWS")\r
 public class DisemblWS extends SequenceAnnotationService<Disembl>\r
@@ -69,5 +73,12 @@ public class DisemblWS extends SequenceAnnotationService<Disembl>
 \r
                return analize(sequences);\r
        }\r
+       @Override\r
+       public ChunkHolder pullExecStatistics(String jobId, long position) {\r
+               WSUtil.validateJobId(jobId);\r
+               String file = Configurator.getWorkDirectory(jobId) + File.separator\r
+                               + AACon.getStatFile();\r
+               return WSUtil.pullFile(file, position);\r
+       }\r
 \r
 }\r
index d54bcd9..084cb89 100644 (file)
@@ -18,6 +18,7 @@
 package compbio.ws.server;\r
 \r
 import java.util.List;\r
+import java.io.File;\r
 \r
 import javax.jws.WebService;\r
 \r
@@ -33,6 +34,9 @@ import compbio.metadata.Preset;
 import compbio.metadata.UnsupportedRuntimeException;\r
 import compbio.metadata.WrongParameterException;\r
 import compbio.runner.disorder.GlobPlot;\r
+import compbio.engine.Configurator;\r
+import compbio.runner.conservation.AACon;\r
+import compbio.metadata.ChunkHolder;\r
 \r
 @WebService(endpointInterface = "compbio.data.msa.SequenceAnnotation", targetNamespace = JABAService.V2_SERVICE_NAMESPACE, serviceName = "GlobPlotWS")\r
 public class GlobPlotWS extends SequenceAnnotationService<GlobPlot>\r
@@ -69,5 +73,12 @@ public class GlobPlotWS extends SequenceAnnotationService<GlobPlot>
 \r
                return analize(sequences);\r
        }\r
+       @Override\r
+       public ChunkHolder pullExecStatistics(String jobId, long position) {\r
+               WSUtil.validateJobId(jobId);\r
+               String file = Configurator.getWorkDirectory(jobId) + File.separator\r
+                               + AACon.getStatFile();\r
+               return WSUtil.pullFile(file, position);\r
+       }\r
 \r
 }\r
index b01137e..dab9245 100644 (file)
@@ -18,6 +18,7 @@
 package compbio.ws.server;\r
 \r
 import java.util.List;\r
+import java.io.File;\r
 \r
 import javax.jws.WebService;\r
 \r
@@ -32,6 +33,9 @@ import compbio.metadata.Preset;
 import compbio.metadata.UnsupportedRuntimeException;\r
 import compbio.metadata.WrongParameterException;\r
 import compbio.runner.disorder.IUPred;\r
+import compbio.engine.Configurator;\r
+import compbio.runner.conservation.AACon;\r
+import compbio.metadata.ChunkHolder;\r
 \r
 @WebService(endpointInterface = "compbio.data.msa.SequenceAnnotation", targetNamespace = JABAService.V2_SERVICE_NAMESPACE, serviceName = "IUPredWS")\r
 public class IUPredWS extends SequenceAnnotationService<IUPred>\r
@@ -56,5 +60,12 @@ public class IUPredWS extends SequenceAnnotationService<IUPred>
 \r
                return analize(sequences);\r
        }\r
+       @Override\r
+       public ChunkHolder pullExecStatistics(String jobId, long position) {\r
+               WSUtil.validateJobId(jobId);\r
+               String file = Configurator.getWorkDirectory(jobId) + File.separator\r
+                               + AACon.getStatFile();\r
+               return WSUtil.pullFile(file, position);\r
+       }\r
 \r
 }\r