X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fws%2Frest%2Fparams%2FAlignment.java;h=4426c5f7e79d041e6e0589bdce37b77d21fe5f30;hb=31ee6e439fa0e6432e812089e092df0cee1eb223;hp=b85073f825fa9abf0ce756043d1dae714361cd3e;hpb=136c0793b90b72b928c4d77dc109dd5c644e00d3;p=jalview.git diff --git a/src/jalview/ws/rest/params/Alignment.java b/src/jalview/ws/rest/params/Alignment.java index b85073f..4426c5f 100644 --- a/src/jalview/ws/rest/params/Alignment.java +++ b/src/jalview/ws/rest/params/Alignment.java @@ -79,11 +79,11 @@ public class Alignment extends InputType try { File fa = File.createTempFile("jvmime", ".fa"); - PrintWriter pw = new PrintWriter( - new OutputStreamWriter(new BufferedOutputStream( - new FileOutputStream(fa)), "UTF-8")); - pw.append(new FormatAdapter().formatSequences(format, - alignment, jvsuffix)); + PrintWriter pw = new PrintWriter(new OutputStreamWriter( + new BufferedOutputStream(new FileOutputStream(fa)), + "UTF-8")); + pw.append(new FormatAdapter().formatSequences(format, alignment, + jvsuffix)); pw.close(); return new FileBody(fa, "text/plain"); } catch (Exception ex) @@ -156,8 +156,8 @@ public class Alignment extends InputType return true; } } - warnings.append("Invalid alignment format '" + val - + "'. Must be one of ("); + warnings.append( + "Invalid alignment format '" + val + "'. Must be one of ("); for (String fmt : FileFormats.getInstance().getWritableFormats(true)) { warnings.append(" ").append(fmt); @@ -172,8 +172,8 @@ public class Alignment extends InputType return true; } catch (Exception x) { - warnings.append("Invalid molecule type '" + val - + "'. Must be one of ("); + warnings.append( + "Invalid molecule type '" + val + "'. Must be one of ("); for (molType v : molType.values()) { warnings.append(" " + v); @@ -195,12 +195,12 @@ public class Alignment extends InputType "Append jalview style /start-end suffix to ID", false, false, writeAsFile, null)); - List writable = FileFormats - .getInstance().getWritableFormats(true); + List writable = FileFormats.getInstance() + .getWritableFormats(true); lst.add(new Option("format", "Alignment upload format", true, - FileFormat.Fasta.toString(), format.getName(), writable, + FileFormat.Fasta.toString(), format.getName(), writable, null)); + lst.add(createMolTypeOption("type", "Sequence type", false, type, null)); - lst.add(createMolTypeOption("type", "Sequence type", false, type, null)); return lst; }