From: gmungoc Date: Thu, 10 May 2018 14:17:53 +0000 (+0100) Subject: JAL-2629 default HMMBuild to alignment if not specified by args X-Git-Url: http://source.jalview.org/gitweb/?a=commitdiff_plain;h=45ae91e9bc0b3a9046d2f587d7810f5d27c04890;p=jalview.git JAL-2629 default HMMBuild to alignment if not specified by args --- diff --git a/src/jalview/hmmer/HMMBuild.java b/src/jalview/hmmer/HMMBuild.java index 3c3bd40..6de7029 100644 --- a/src/jalview/hmmer/HMMBuild.java +++ b/src/jalview/hmmer/HMMBuild.java @@ -96,11 +96,14 @@ public class HMMBuild extends HmmerCommand AlignViewportI viewport) { List runBuildFor = new ArrayList<>(); + boolean foundArg = false; + for (ArgumentI arg : params) { String name = arg.getName(); if (MessageManager.getString("label.hmmbuild_for").equals(name)) { + foundArg = true; String value = arg.getValue(); if (MessageManager.getString("label.alignment").equals(value)) { @@ -134,6 +137,15 @@ public class HMMBuild extends HmmerCommand } } } + + /* + * default is to build for the whole alignment + */ + if (!foundArg) + { + runBuildFor.add(alignment); + } + return runBuildFor; }