X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fstructure%2FStructureImportSettings.java;h=22ecdc723195ffa4e6e0edf7c5a5d381043432d2;hb=bc1a3842b31a35a7794f4afec4911ad421c7c3e4;hp=9662fee4f916e994f01921f423d6aa500f2acf40;hpb=7d67fb613ec026dc9a265e351e7fab542e3f1d61;p=jalview.git diff --git a/src/jalview/structure/StructureImportSettings.java b/src/jalview/structure/StructureImportSettings.java index 9662fee..22ecdc7 100644 --- a/src/jalview/structure/StructureImportSettings.java +++ b/src/jalview/structure/StructureImportSettings.java @@ -20,8 +20,11 @@ */ package jalview.structure; +import java.util.Locale; + import jalview.datamodel.PDBEntry; import jalview.datamodel.PDBEntry.Type; +import jalview.util.MessageManager; /** * bean holding settings for structure IO. TODO: tests for validation of values @@ -57,6 +60,18 @@ public class StructureImportSettings JMOL_PARSER, JALVIEW_PARSER } + public static enum TFType + { + DEFAULT, PLDDT; + + @Override + public String toString() + { + return MessageManager.getString( + "label.tftype_" + this.name().toLowerCase(Locale.ROOT)); + } + } + /** * Determines the default file format for structure files to be downloaded * from the PDB sequence fetcher. Possible options include: PDB|mmCIF @@ -69,6 +84,8 @@ public class StructureImportSettings */ private static StructureParser defaultPDBFileParser = StructureParser.JMOL_PARSER; + private static TFType temperatureFactorType; + public static void addSettings(boolean addAlignmentAnnotations, boolean processSecStr, boolean externalSecStr) { @@ -83,6 +100,11 @@ public class StructureImportSettings return visibleChainAnnotation; } + public static void setTemperatureFactorType(TFType t) + { + StructureImportSettings.temperatureFactorType = t; + } + public static void setVisibleChainAnnotation( boolean visibleChainAnnotation) { @@ -130,7 +152,7 @@ public class StructureImportSettings String defaultStructureFileFormat) { StructureImportSettings.defaultStructureFileFormat = PDBEntry.Type - .valueOf(defaultStructureFileFormat.toUpperCase()); + .valueOf(defaultStructureFileFormat.toUpperCase(Locale.ROOT)); } public static String getDefaultPDBFileParser() @@ -147,7 +169,12 @@ public class StructureImportSettings public static void setDefaultPDBFileParser(String defaultPDBFileParser) { StructureImportSettings.defaultPDBFileParser = StructureParser - .valueOf(defaultPDBFileParser.toUpperCase()); + .valueOf(defaultPDBFileParser.toUpperCase(Locale.ROOT)); + } + + public static TFType getTemperatureFactorType() + { + return temperatureFactorType; } }