X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=webservices%2Fcompbio%2Fws%2Fserver%2FRNAalifoldWS.java;h=ed94c23cdc071f3617cf1910dd5f87bdc8a0b3e5;hb=68fe46f278b4ec408d6c68677bd56199aac749b3;hp=beca1dc1a6786e02a63b556d0c8cce60d6571f8d;hpb=191ed00f52901ed7ee6d1137637e66c999913be8;p=jabaws.git diff --git a/webservices/compbio/ws/server/RNAalifoldWS.java b/webservices/compbio/ws/server/RNAalifoldWS.java index beca1dc..ed94c23 100644 --- a/webservices/compbio/ws/server/RNAalifoldWS.java +++ b/webservices/compbio/ws/server/RNAalifoldWS.java @@ -9,47 +9,40 @@ import org.apache.log4j.Logger; import compbio.data.msa.JABAService; import compbio.data.msa.SequenceAnnotation; import compbio.data.sequence.FastaSequence; -import compbio.data.sequence.RNAStructScoreManager; import compbio.engine.client.ConfiguredExecutable; import compbio.metadata.JobSubmissionException; import compbio.metadata.LimitExceededException; import compbio.metadata.Option; import compbio.metadata.Preset; -import compbio.metadata.ResultNotAvailableException; import compbio.metadata.UnsupportedRuntimeException; import compbio.metadata.WrongParameterException; import compbio.runner.conservation.AACon; import compbio.runner.structure.RNAalifold; @WebService(endpointInterface = "compbio.data.msa.SequenceAnnotation", targetNamespace = JABAService.V2_SERVICE_NAMESPACE, serviceName = "RNAalifoldWS") -public class RNAalifoldWS extends SequenceAnnotationService - implements - SequenceAnnotation { +public class RNAalifoldWS extends SequenceAnnotationService implements SequenceAnnotation { private static Logger log = Logger.getLogger(RNAalifoldWS.class); public RNAalifoldWS() { super (new RNAalifold(), log); } - - - // for testing - @Override - public RNAStructScoreManager getAnnotation(String jobId) - throws ResultNotAvailableException { - return WSUtil.getAnnotation(jobId, log); - } + // Only purpose is to replace "analize" with "fold" method + // so that a clustal input file and not fasta will be generated + @SuppressWarnings("unchecked") @Override public String analize(List sequences) throws UnsupportedRuntimeException, LimitExceededException, JobSubmissionException { WSUtil.validateFastaInput(sequences); ConfiguredExecutable confRNAalifold = init(sequences); - return WSUtil.fold(sequences, confRNAalifold, log, "analize", - getLimit("")); + return WSUtil.fold(sequences, confRNAalifold, log, "analize", getLimit("")); } + // Only purpose is to replace "analize" with "fold" method + // so that a clustal input file and not fasta will be generated + @SuppressWarnings("unchecked") @Override public String customAnalize(List sequences, List> options) throws UnsupportedRuntimeException, @@ -57,12 +50,9 @@ public class RNAalifoldWS extends SequenceAnnotationService WrongParameterException { WSUtil.validateFastaInput(sequences); ConfiguredExecutable confRNAalifold = init(sequences); - - List params = WSUtil.getCommands(options, - AACon.KEY_VALUE_SEPARATOR); + List params = WSUtil.getCommands(options, RNAalifold.KEY_VALUE_SEPARATOR); confRNAalifold.addParameters(params); - return WSUtil.fold(sequences, confRNAalifold, log, "customAnalize", - getLimit("")); + return WSUtil.fold(sequences, confRNAalifold, log, "customAnalize", getLimit("")); } @@ -75,9 +65,6 @@ public class RNAalifoldWS extends SequenceAnnotationService Preset preset) throws UnsupportedRuntimeException, LimitExceededException, JobSubmissionException, WrongParameterException { - return analize(sequences); } } - -