X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=webservices%2Fcompbio%2Fws%2Fclient%2FJws2Client.java;h=ce4980d1c724c92f8239b199543434f2c88a9af6;hb=191ed00f52901ed7ee6d1137637e66c999913be8;hp=888ec5ffb9d6d07d9602208f7df46b3a8800c5df;hpb=fa61eaad52ffe5ee0db449c3dd9ec5fa67aec43f;p=jabaws.git diff --git a/webservices/compbio/ws/client/Jws2Client.java b/webservices/compbio/ws/client/Jws2Client.java index 888ec5f..ce4980d 100644 --- a/webservices/compbio/ws/client/Jws2Client.java +++ b/webservices/compbio/ws/client/Jws2Client.java @@ -50,7 +50,7 @@ import compbio.data.msa.RegistryWS; import compbio.data.msa.SequenceAnnotation; import compbio.data.sequence.Alignment; import compbio.data.sequence.FastaSequence; -import compbio.data.sequence.RNAstruct; +import compbio.data.sequence.RNAStruct; import compbio.data.sequence.ScoreManager; import compbio.data.sequence.ClustalAlignmentUtil; import compbio.data.sequence.SequenceUtil; @@ -150,7 +150,6 @@ public class Jws2Client { String presetName = CmdHelper.getPresetName(cmd); Metadata msaws = (Metadata) connect(hostname, service); - Metadata foldws = (Metadata) connect(hostname, service); Preset preset = null; if (presetName != null) { preset = MetadataHelper.getPreset(msaws, presetName); @@ -161,8 +160,9 @@ public class Jws2Client { customOptions = MetadataHelper.processParameters(prms, msaws.getRunnerOptions()); } +// System.out.println("The Options read from the command line: " + customOptions); + Alignment alignment = null; - RNAstruct rnastruct = null; if (inputFile != null) { Writer writer = null; if (outFile != null) { @@ -176,17 +176,12 @@ public class Jws2Client { ScoreManager result = analize(inputFile, ((SequenceAnnotation) msaws), preset, customOptions); + System.out.println(result\.asRNAStruct().toString()); IOHelper.writeOut(writer, result); } else if (service.getServiceType() == MsaWS.class) { alignment = align(inputFile, (MsaWS) msaws, preset, customOptions); IOHelper.writeOut(writer, alignment); - } else if (service.getServiceType() == FoldWS.class) { - rnastruct = fold(inputFile, (FoldWS) foldws, preset, customOptions); - // No IOHelper method for rnastruct/String yet - if (writer != null) { - writer.write(rnastruct.toString()); - } } writer.close(); } @@ -532,14 +527,14 @@ public class Jws2Client { * Preset to use optional * @param customOptions * file which contains new line separated list of options - * @return RNAstruct + * @return String */ - static RNAstruct fold(File file, FoldWS foldws, Preset preset, + static String fold(File file, FoldWS foldws, Preset preset, List> customOptions) { FileInputStream instream = null; Alignment alignment = null; - RNAstruct rnastruct = null; + String rnastruct = null; try { instream = new FileInputStream(file); alignment = ClustalAlignmentUtil.readClustalFile(instream); @@ -559,8 +554,6 @@ public class Jws2Client { System.out.println("\n\ncalling fold........."); Thread.sleep(1000); rnastruct = foldws.getResult(jobId); - log.info("log test print results:\n" + rnastruct.toString()); - System.out.println("print test results:\n " + rnastruct.toString()); } catch (IOException e) { System.err.println("Exception while reading the input file. Exception details: ");