/*
- * Jalview - A Sequence Alignment Editor and Viewer (Version 2.8.2b1)
- * Copyright (C) 2014 The Jalview Authors
+ * Jalview - A Sequence Alignment Editor and Viewer ($$Version-Rel$$)
+ * Copyright (C) $$Year-Rel$$ The Jalview Authors
*
* This file is part of Jalview.
*
*/
package MCview;
-import java.util.*;
+import java.util.Vector;
public class Residue
{
- Vector atoms = new Vector();
+ Vector<Atom> atoms;
int number;
int count;
- int seqnumber;
-
- public Residue(Vector atoms, int number, int count)
+ public Residue(Vector<Atom> resAtoms, int number, int count)
{
- this.atoms = atoms;
+ this.atoms = resAtoms;
this.number = number;
this.count = count;
}
public Atom findAtom(String name)
{
- for (int i = 0; i < atoms.size(); i++)
+ for (Atom atom : atoms)
{
- if (((Atom) atoms.elementAt(i)).name.equals(name))
+ if (atom.name.equals(name))
{
- return (Atom) atoms.elementAt(i);
+ return atom;
}
}
return null;
}
+
+ public Vector<Atom> getAtoms()
+ {
+ return this.atoms;
+ }
}