org.proteinshader.structure.visitor
Class BondDestroyerVisitor
java.lang.Object
org.proteinshader.structure.visitor.Visitor
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.
Usage
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).
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 |
BondDestroyerVisitor
public BondDestroyerVisitor()
- Constructs a BondDestroyerVisitor.
visit
public void visit(Atom atom)
throws VisitorException
- Removes all Bonds on the Atom.
- Overrides:
visit
in class Visitor
- Parameters:
atom
- the Atom to visit.
- Throws:
VisitorException
- will not happen.
Copyright © 2007-2008