Merge branch 'develop' into features/r2_11_2_alphafold/JAL-629
[jalview.git] / src / jalview / io / StructureFile.java
index 7ecbc2d..f498c1e 100644 (file)
@@ -70,6 +70,25 @@ public abstract class StructureFile extends AlignFile
 
   private StructureImportSettings.TFType temperatureFactorType = TFType.DEFAULT;
 
+  private String paeMatrix = null;
+
+  private boolean alphaFoldModel;
+
+  public void setPAEMatrix(String paeFilename)
+  {
+    paeMatrix = paeFilename;
+  }
+
+  public String getPAEMatrix()
+  {
+    return paeMatrix;
+  }
+
+  public boolean hasPAEMatrix()
+  {
+    return paeMatrix != null;
+  }
+
   public void setTemperatureFactorType(StructureImportSettings.TFType t)
   {
     this.temperatureFactorType = t;
@@ -80,6 +99,16 @@ public abstract class StructureFile extends AlignFile
     return temperatureFactorType;
   }
 
+  public void setAlphafoldModel(boolean afm)
+  {
+    alphaFoldModel = afm;
+  }
+
+  public boolean isAlphafoldModel()
+  {
+    return alphaFoldModel;
+  }
+
   public StructureFile(Object inFile, DataSourceType sourceType)
           throws IOException
   {
@@ -89,8 +118,9 @@ public abstract class StructureFile extends AlignFile
   public StructureFile(Object inFile, DataSourceType sourceType,
           StructureImportSettings.TFType tempfacType) throws IOException
   {
-    super(inFile, sourceType);
+    super(false, inFile, sourceType);
     this.setTemperatureFactorType(tempfacType);
+    doParse();
   }
 
   public StructureFile(FileParse fp) throws IOException
@@ -339,6 +369,8 @@ public abstract class StructureFile extends AlignFile
                 .setProcessSecondaryStructure(predictSecondaryStructure);
         StructureImportSettings
                 .setExternalSecondaryStructure(externalSecondaryStructure);
+        StructureImportSettings
+                .setTemperatureFactorType(temperatureFactorType);
         Object jmf = constructor.newInstance(args);
         AlignmentI al = new Alignment((SequenceI[]) cl
                 .getMethod("getSeqsAsArray", new Class[] {}).invoke(jmf));