X-Git-Url: http://source.jalview.org/gitweb/?a=blobdiff_plain;f=src%2Fjalview%2Fio%2FModellerDescription.java;h=13431c17c0433c4f9c9490515a20dde762e1d99f;hb=2d7deb9d3e1ddc98abae846c8ffbc62606b023be;hp=1e4f9056c9f9671782a3bb3d33c9c58da8904662;hpb=91416b3038a6f3fc655791512770da07cb6cb251;p=jalview.git diff --git a/src/jalview/io/ModellerDescription.java b/src/jalview/io/ModellerDescription.java index 1e4f905..13431c1 100755 --- a/src/jalview/io/ModellerDescription.java +++ b/src/jalview/io/ModellerDescription.java @@ -1,3 +1,21 @@ +/* + * Jalview - A Sequence Alignment Editor and Viewer + * Copyright (C) 2006 AM Waterhouse, J Procter, G Barton, M Clamp, S Searle + * + * This program 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 2 + * of the License, or (at your option) any later version. + * + * This program 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 this program; if not, write to the Free Software + * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA + */ package jalview.io; import jalview.datamodel.SequenceI; @@ -224,19 +242,17 @@ public class ModellerDescription if (seq.getDatasetSequence() != null && seq.getDatasetSequence().getDBRef() != null) { - Vector dbr = seq.getDatasetSequence().getDBRef(); + jalview.datamodel.DBRefEntry [] dbr = seq.getDatasetSequence().getDBRef(); int i, j; - for (i = 0, j = dbr.size(); i < j; i++) + for (i = 0, j = dbr.length; i < j; i++) { - jalview.datamodel.DBRefEntry dref = (jalview.datamodel.DBRefEntry) - dbr.elementAt(i); - if (dref != null) + if (dbr[i] != null) { // JBPNote PDB dbRefEntry needs properties to propagate onto ModellerField // JBPNote Need to get info from the user about whether the sequence is the one being modelled, or if it is a template. - if (dref.getSource().equals(jalview.datamodel.DBRefSource.PDB)) + if (dbr[i].getSource().equals(jalview.datamodel.DBRefSource.PDB)) { - fields.put(Fields[LOCALID], dref.getAccessionId()); + fields.put(Fields[LOCALID], dbr[i].getAccessionId()); t = 2; break; }