Class BondDestroyerVisitor

  extended by org.proteinshader.structure.visitor.Visitor
      extended by org.proteinshader.structure.visitor.BondDestroyerVisitor

public class BondDestroyerVisitor
extends Visitor

Removes Bonds on all Atoms that it visits.

The default is to remove the Bonds on all Atoms, but the setRestriction() method can be called to specify that only a subset of Atoms have their Bonds removed.


structure.accept( new BondDestroyerVisitor() );

would remove Bonds on all Residues, while

Visitor visitor = new BondDestroyerVisitor();
visitor.setRestriction( ResidueEnum.AMINO_ACIDS );
structure.accept( visitor );

would only remove Bonds for the AminoAcids.

Note on Exception Handling

Currently, the VisitorException in the visit( Atom ) method is only there to satisfy the Visitor API (other Visitors such as the SFWriterVisitor do need an exception in the visit() method declaration).

Constructor Summary
          Constructs a BondDestroyerVisitor.
Method Summary
 void visit(Atom atom)
          Removes all Bonds on the Atom.
Methods inherited from class org.proteinshader.structure.visitor.Visitor
clear, includeAAHetAndWater, setDebug, setMode, setMode, setMode, setMode, setMode, setMode, setVisitSegments, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit, visit
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public BondDestroyerVisitor()
Constructs a BondDestroyerVisitor.

Method Detail


public void visit(Atom atom)
           throws VisitorException
Removes all Bonds on the Atom.

visit in class Visitor
atom - the Atom to visit.
VisitorException - will not happen.

Copyright © 2007-2008