org.strbio.mol
Class AtomNode

java.lang.Object
  extended by org.strbio.mol.Atom
      extended by org.strbio.mol.AtomNode
All Implemented Interfaces:
DLinkedList.Node

public class AtomNode
extends Atom
implements DLinkedList.Node

Class to represent a node in a list of atoms.

 Version 1.1, 4/16/98 - uses DlinkedList class, renamed from AtomList to AtomNode
 Version 1.0, 3/31/98 - original version
 

Version:
1.1, 4/16/98
Author:
JMC
See Also:
Atom, Molecule, Monomer, Residue, Protein

Field Summary
 AtomNode next
          the next atom in the list
 AtomNode prev
          the previous atom in the list
 
Fields inherited from class org.strbio.mol.Atom
altLoc, coord, n, name, occupancy, tempFactor
 
Constructor Summary
AtomNode()
          constructor sets next, prev to null
AtomNode(Atom x)
          when constructed from an Atom, it makes a new copy of the data in the Atom, but doesn't set next, prev.
 
Method Summary
 DLinkedList.Node copyNode()
          Return a node with a copy of the same atom.
 void insertNodeQuickly(AtomNode x)
          Inserts another AtomNode in the linked list after this atom, without going through the DLinkedList routines.
 DLinkedList.Node next()
          return the next AtomNode
 DLinkedList.Node prev()
          return the previous AtomNode
 void removeQuickly()
          Removes this atom from the linked list, without going through the DLinkedList routines.
 void setNext(DLinkedList.Node x)
          set the next AtomNode
 void setPrev(DLinkedList.Node x)
          set the previous AtomNode
 
Methods inherited from class org.strbio.mol.Atom
bondAngle, dihedralAngle, distance, find4, find4, readPDB, rotate, transform, translate, writePDB, x, y, z
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

next

public AtomNode next
the next atom in the list


prev

public AtomNode prev
the previous atom in the list

Constructor Detail

AtomNode

public AtomNode()
constructor sets next, prev to null


AtomNode

public AtomNode(Atom x)
when constructed from an Atom, it makes a new copy of the data in the Atom, but doesn't set next, prev. There's no constructor from AtomNode because I can't think of why anybody would want to copy all aspects of an AtomNode.

Method Detail

copyNode

public DLinkedList.Node copyNode()
Return a node with a copy of the same atom.

Specified by:
copyNode in interface DLinkedList.Node

next

public DLinkedList.Node next()
return the next AtomNode

Specified by:
next in interface DLinkedList.Node

prev

public DLinkedList.Node prev()
return the previous AtomNode

Specified by:
prev in interface DLinkedList.Node

setNext

public void setNext(DLinkedList.Node x)
set the next AtomNode

Specified by:
setNext in interface DLinkedList.Node

setPrev

public void setPrev(DLinkedList.Node x)
set the previous AtomNode

Specified by:
setPrev in interface DLinkedList.Node

removeQuickly

public final void removeQuickly()
Removes this atom from the linked list, without going through the DLinkedList routines.


insertNodeQuickly

public final void insertNodeQuickly(AtomNode x)
Inserts another AtomNode in the linked list after this atom, without going through the DLinkedList routines.