X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fdatamodel%2Ffeatures%2FFeatureMatcherSet.java;h=eae366492f15a79d59f8ee039625ce0f169d0bb5;hb=a3f65dbb5ba8bd470a31ba2af72db6d8ddf60546;hp=b51f2f0a5cc95e3de1f9e3be3404709d1cea6781;hpb=14b1b2a878190d5fffda298c4b9a901c72c74ad3;p=jalview.git diff --git a/src/jalview/datamodel/features/FeatureMatcherSet.java b/src/jalview/datamodel/features/FeatureMatcherSet.java index b51f2f0..eae3664 100644 --- a/src/jalview/datamodel/features/FeatureMatcherSet.java +++ b/src/jalview/datamodel/features/FeatureMatcherSet.java @@ -1,5 +1,27 @@ +/* + * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$) + * Copyright (C) $$Year-Rel$$ The Jalview Authors + * + * This file is part of Jalview. + * + * Jalview is free software: you can redistribute it and/or + * modify it under the terms of the GNU General Public License + * as published by the Free Software Foundation, either version 3 + * of the License, or (at your option) any later version. + * + * Jalview is distributed in the hope that it will be useful, but + * WITHOUT ANY WARRANTY; without even the implied warranty + * of MERCHANTABILITY or FITNESS FOR A PARTICULAR + * PURPOSE. See the GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with Jalview. If not, see . + * The Jalview Authors are detailed in the 'AUTHORS' file. + */ package jalview.datamodel.features; +import java.util.Locale; + import jalview.datamodel.SequenceFeature; import jalview.util.MessageManager; @@ -71,7 +93,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI if (spacePos == -1) { // trailing junk after a match condition - System.err.println(invalid); + jalview.bin.Console.errPrintln(invalid); return null; } String conjunction = leftToParse.substring(0, spacePos); @@ -87,7 +109,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI else { // not an AND or an OR - invalid - System.err.println(invalid); + jalview.bin.Console.errPrintln(invalid); return null; } } @@ -101,7 +123,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI int closePos = leftToParse.indexOf(CLOSE_BRACKET); if (closePos == -1) { - System.err.println(invalid); + jalview.bin.Console.errPrintln(invalid); return null; } nextCondition = leftToParse.substring(1, closePos); @@ -115,7 +137,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI FeatureMatcher fm = FeatureMatcher.fromString(nextCondition); if (fm == null) { - System.err.println(invalid); + jalview.bin.Console.errPrintln(invalid); return null; } try @@ -132,7 +154,7 @@ public class FeatureMatcherSet implements FeatureMatcherSetI } catch (IllegalStateException e) { // thrown if OR and AND are mixed - System.err.println(invalid); + jalview.bin.Console.errPrintln(invalid); return null; } @@ -237,7 +259,8 @@ public class FeatureMatcherSet implements FeatureMatcherSetI if (!first) { String joiner = andConditions ? AND_18N : OR_I18N; - sb.append(SPACE).append(joiner.toLowerCase()).append(SPACE); + sb.append(SPACE).append(joiner.toLowerCase(Locale.ROOT)) + .append(SPACE); } first = false; if (multiple)