X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Fjalview%2Fio%2FStructureFile.java;h=084f8869e5a85e6468bdef9ec61574ef8e7db6fc;hb=fa8140d4e0510b5c91284ad38f296cbf14ba29a5;hp=778c68340e61c60fce1b2c604219ef152a48a5ca;hpb=c945c9641de88cad01b09b3db19e45667dfe751e;p=jalview.git diff --git a/src/jalview/io/StructureFile.java b/src/jalview/io/StructureFile.java index 778c683..084f886 100644 --- a/src/jalview/io/StructureFile.java +++ b/src/jalview/io/StructureFile.java @@ -38,7 +38,7 @@ import java.lang.reflect.Constructor; import java.util.List; import java.util.Vector; -import MCview.PDBChain; +import mc_view.PDBChain; public abstract class StructureFile extends AlignFile { @@ -341,8 +341,15 @@ public abstract class StructureFile extends AlignFile } StructureImportSettings.setShowSeqFeatures(true); } - - public PDBChain findChain(String id) throws Exception + + /** + * Answers the first PDBChain found matching the given id, or null if none + * is found + * + * @param id + * @return + */ + public PDBChain findChain(String id) { for (PDBChain chain : getChains()) { @@ -351,7 +358,7 @@ public abstract class StructureFile extends AlignFile return chain; } } - throw new Exception("PDB chain not Found!"); + return null; } public void makeResidueList()