JAL-3063 Save/Load user colour scheme using JAXB
[jalview.git] / src / jalview / project / Jalview2XML.java
index 5106e45..c4ad897 100644 (file)
@@ -4815,7 +4815,7 @@ public class Jalview2XML
         if (filters != null)
         {
           FeatureMatcherSetI filter = Jalview2XML
-                  .unmarshalFilter(featureType, filters);
+                  .parseFilter(featureType, filters);
           if (!filter.isEmpty())
           {
             fr.setFeatureFilter(featureType, filter);
@@ -5873,7 +5873,7 @@ public class Jalview2XML
    * @param fcol
    * @return
    */
-  protected static Colour marshalColour(
+  public static Colour marshalColour(
           String featureType, FeatureColourI fcol)
   {
     Colour col = new Colour();
@@ -5930,7 +5930,7 @@ public class Jalview2XML
    * @param and
    *          if true, conditions are and-ed, else or-ed
    */
-  protected static jalview.xml.binding.jalview.FeatureMatcherSet marshalFilter(
+  public static jalview.xml.binding.jalview.FeatureMatcherSet marshalFilter(
           FeatureMatcherI firstMatcher, Iterator<FeatureMatcherI> filters,
           boolean and)
   {
@@ -5996,14 +5996,14 @@ public class Jalview2XML
    * @param matcherSetModel
    * @return
    */
-  protected static FeatureMatcherSetI unmarshalFilter(
+  public static FeatureMatcherSetI parseFilter(
           String featureType,
           jalview.xml.binding.jalview.FeatureMatcherSet matcherSetModel)
   {
     FeatureMatcherSetI result = new FeatureMatcherSet();
     try
     {
-      unmarshalFilterConditions(result, matcherSetModel, true);
+      parseFilterConditions(result, matcherSetModel, true);
     } catch (IllegalStateException e)
     {
       // mixing AND and OR conditions perhaps
@@ -6027,7 +6027,7 @@ public class Jalview2XML
    * @throws IllegalStateException
    *           if AND and OR conditions are mixed
    */
-  protected static void unmarshalFilterConditions(
+  protected static void parseFilterConditions(
           FeatureMatcherSetI matcherSet,
           jalview.xml.binding.jalview.FeatureMatcherSet matcherSetModel,
           boolean and)
@@ -6080,13 +6080,12 @@ public class Jalview2XML
        * compound condition
        */
       List<jalview.xml.binding.jalview.FeatureMatcherSet> matchers = matcherSetModel
-              .getCompoundMatcher()
-              .getMatcherSet();
+              .getCompoundMatcher().getMatcherSet();
       boolean anded = matcherSetModel.getCompoundMatcher().isAnd();
       if (matchers.size() == 2)
       {
-        unmarshalFilterConditions(matcherSet, matchers.get(0), anded);
-        unmarshalFilterConditions(matcherSet, matchers.get(1), anded);
+        parseFilterConditions(matcherSet, matchers.get(0), anded);
+        parseFilterConditions(matcherSet, matchers.get(1), anded);
       }
       else
       {
@@ -6101,7 +6100,7 @@ public class Jalview2XML
    * @param colourModel
    * @return
    */
-  protected static FeatureColourI unmarshalColour(Colour colourModel)
+  public static FeatureColourI parseColour(Colour colourModel)
   {
     FeatureColourI colour = null;