Merge branch 'releases/Release_2_10_Branch' into develop
[jalview.git] / src / jalview / io / gff / ExonerateHelper.java
index f7805fd..eb74eea 100644 (file)
@@ -1,3 +1,23 @@
+/*
+ * 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 <http://www.gnu.org/licenses/>.
+ * The Jalview Authors are detailed in the 'AUTHORS' file.
+ */
 package jalview.io.gff;
 
 import jalview.datamodel.AlignedCodonFrame;
@@ -64,8 +84,8 @@ public class ExonerateHelper extends Gff2Helper
 
     try
     {
-      processGffSimilarity(set, seq, gffColumns,
-              align, newseqs, relaxedIdMatching);
+      processGffSimilarity(set, seq, gffColumns, align, newseqs,
+              relaxedIdMatching);
     } catch (IOException ivfe)
     {
       System.err.println(ivfe);
@@ -98,8 +118,7 @@ public class ExonerateHelper extends Gff2Helper
    *          if true allow fuzzy search for a matching target sequence
    * @throws IOException
    */
-  protected void processGffSimilarity(
-          Map<String, List<String>> set,
+  protected void processGffSimilarity(Map<String, List<String>> set,
           SequenceI seq, String[] gff, AlignmentI align,
           List<SequenceI> newseqs, boolean relaxedIdMatching)
           throws IOException
@@ -228,15 +247,17 @@ public class ExonerateHelper extends Gff2Helper
     int alignFromStart;
     int alignToStart;
     int alignCount;
-    try {
+    try
+    {
       alignFromStart = Integer.parseInt(tokens[0]);
       alignToStart = Integer.parseInt(tokens[1]);
       alignCount = Integer.parseInt(tokens[2]);
-    } catch (NumberFormatException nfe) {
+    } catch (NumberFormatException nfe)
+    {
       System.err.println(nfe.toString());
       return null;
     }
-    
+
     int fromStart;
     int fromEnd;
     int toStart;
@@ -290,10 +311,8 @@ public class ExonerateHelper extends Gff2Helper
     {
       result = MappingType.PeptideToNucleotide;
     }
-    else if (model.contains(CODING2CODING)
-            || model.contains(CODING2GENOME)
-            || model.contains(CDNA2GENOME)
-            || model.contains(GENOME2GENOME))
+    else if (model.contains(CODING2CODING) || model.contains(CODING2GENOME)
+            || model.contains(CDNA2GENOME) || model.contains(GENOME2GENOME))
     {
       result = MappingType.NucleotideToNucleotide;
     }
@@ -323,10 +342,8 @@ public class ExonerateHelper extends Gff2Helper
     {
       String mdl = model.toLowerCase();
       if (mdl.contains(PROTEIN2DNA) || mdl.contains(PROTEIN2GENOME)
-              || mdl.contains(CODING2CODING)
-              || mdl.contains(CODING2GENOME)
-              || mdl.contains(CDNA2GENOME)
-              || mdl.contains(GENOME2GENOME))
+              || mdl.contains(CODING2CODING) || mdl.contains(CODING2GENOME)
+              || mdl.contains(CDNA2GENOME) || mdl.contains(GENOME2GENOME))
       {
         return true;
       }