scripps.vvm.manager
Class VVM_HighLevels

java.lang.Object
  |
  +--scripps.vvm.manager.VVM_HighLevels

public class VVM_HighLevels
extends java.lang.Object

A set of high level functions for controling nearly everything that can be controled from the GUI. This is intended for use with Java or Jython macros, but they can be used by extending ap-mods too.


Constructor Summary
VVM_HighLevels()
          Ensures VincentVanMol module is loaded
 
Method Summary
 void addElements(VVM_RepShape rep, TreeNodeSet set)
          Add the elements to the rendition.
 AtomSet allAtoms(Molecule mol)
          All atoms in molecule
 ChainSet allChains(Molecule mol)
          All chains in molecule
 ResidueSet allResidues(Molecule mol)
          All residue in molecule
 AtomSet coerseToAtoms(TreeNodeSet defSet)
          Atoms from another set
 BondSet coerseToBonds(TreeNodeSet defSet)
          Bonds from another set
 ChainSet coerseToChains(TreeNodeSet defSet)
          Chains from another set
 ResidueSet coerseToResidues(TreeNodeSet defSet)
          Residues from another set
 Molecule findLoadedMol(java.lang.String name)
          Find molecule by name (this is its filename)
 Molecule getCurrentMol()
          Return the "current" molecule in the gui
 TreeNodeSet interpret(java.lang.String expression, Molecule mol)
          Return set of elements from expression.
 AtomSet interpretAtoms(java.lang.String expression, AtomSet superset)
          Atoms matching expression
 AtomSet interpretAtoms(java.lang.String expression, Molecule mol)
          Atoms matching expression
 ChainSet interpretChains(java.lang.String expression, ChainSet superset)
          Chains matching expression
 ChainSet interpretChains(java.lang.String expression, Molecule mol)
          Chains matching expression
 ResidueSet interpretResidues(java.lang.String expression, Molecule mol)
          Residues matching expression
 ResidueSet interpretResidues(java.lang.String expression, ResidueSet superset)
          Residues matching expression
 Molecule loadMol(java.lang.String filename)
          Load a protein or dna given a filename
 AtomLabelShape newAtomLabels(Molecule mol)
          Make a new AtomLabelShape visuization of the molecule, add it to database if set to
 AtomLabelShape newAtomLabels(Molecule mol, TreeNodeSet set)
           
 BASShape newBAS(Molecule mol)
          Make a new BASShape visuization of the molecule, add it to database if set to, and add all atoms and bonds of of the molecule if "showAllBAS" is true
 BASShape newBAS(Molecule mol, TreeNodeSet set)
           
 CPKShape newCPK(Molecule mol)
          Make a new CPKShape visuization of the molecule, add it to database if set to, and add all atoms of of the molecule if "showAllCPK" is true
 CPKShape newCPK(Molecule mol, TreeNodeSet set)
           
 MolSurfaceShape newMolSurface(Molecule mol)
          Make a new MolSurfaceShape visuization of the molecule, add it to database if set to, and add all atoms of of the molecule if "showAllMolSurface" is true
 MolSurfaceShape newMolSurface(Molecule mol, TreeNodeSet set)
           
 ResidueLabelShape newResidueLabels(Molecule mol)
          Make a new ResidueLabelShape visuization of the molecule, add it to database if set to
 ResidueLabelShape newResidueLabels(Molecule mol, TreeNodeSet set)
           
 RibbonBackboneShape newRibbons(Molecule mol)
          Make a new RibbonBackboneShape visuization of the molecule, add it to database if set to, and add all residues of of the molecule if "showAllRibbons" is true
 RibbonBackboneShape newRibbons(Molecule mol, TreeNodeSet set)
           
 TubeBackboneShape newTubes(Molecule mol)
          Make a new TubeBackboneShape visuization of the molecule, add it to database if set to, and add all residues of of the molecule if "showAllTubes" is true
 TubeBackboneShape newTubes(Molecule mol, TreeNodeSet set)
           
 WireShape newWire(Molecule mol)
          Make a new WireShape visuization of the molecule, add it to database if set to, and add all atoms and bonds of of the molecule if "showAllWire" is true
 WireShape newWire(Molecule mol, TreeNodeSet set)
           
 void removeElements(VVM_RepShape rep, TreeNodeSet set)
          Remove the elements from the rendition.
 void removeMol(Molecule mol)
          Remove the molecule and any visualizations of it
 void savePDB(Protein mol, java.lang.String filename)
          Save molecule as PDB file
 void setAutoAdd(boolean bAutoAdd)
           
 void setCurrentMol(Molecule mol)
          Make this the "current" molecule in the gui
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VVM_HighLevels

public VVM_HighLevels()
Ensures VincentVanMol module is loaded

Method Detail

setAutoAdd

public void setAutoAdd(boolean bAutoAdd)

loadMol

public Molecule loadMol(java.lang.String filename)
Load a protein or dna given a filename


savePDB

public void savePDB(Protein mol,
                    java.lang.String filename)
             throws java.io.IOException
Save molecule as PDB file

java.io.IOException

removeMol

public void removeMol(Molecule mol)
Remove the molecule and any visualizations of it


findLoadedMol

public Molecule findLoadedMol(java.lang.String name)
Find molecule by name (this is its filename)


setCurrentMol

public void setCurrentMol(Molecule mol)
Make this the "current" molecule in the gui


getCurrentMol

public Molecule getCurrentMol()
Return the "current" molecule in the gui


newCPK

public CPKShape newCPK(Molecule mol)
Make a new CPKShape visuization of the molecule, add it to database if set to, and add all atoms of of the molecule if "showAllCPK" is true


newCPK

public CPKShape newCPK(Molecule mol,
                       TreeNodeSet set)

newMolSurface

public MolSurfaceShape newMolSurface(Molecule mol)
Make a new MolSurfaceShape visuization of the molecule, add it to database if set to, and add all atoms of of the molecule if "showAllMolSurface" is true


newMolSurface

public MolSurfaceShape newMolSurface(Molecule mol,
                                     TreeNodeSet set)

newAtomLabels

public AtomLabelShape newAtomLabels(Molecule mol)
Make a new AtomLabelShape visuization of the molecule, add it to database if set to


newAtomLabels

public AtomLabelShape newAtomLabels(Molecule mol,
                                    TreeNodeSet set)

newTubes

public TubeBackboneShape newTubes(Molecule mol)
Make a new TubeBackboneShape visuization of the molecule, add it to database if set to, and add all residues of of the molecule if "showAllTubes" is true


newTubes

public TubeBackboneShape newTubes(Molecule mol,
                                  TreeNodeSet set)

newRibbons

public RibbonBackboneShape newRibbons(Molecule mol)
Make a new RibbonBackboneShape visuization of the molecule, add it to database if set to, and add all residues of of the molecule if "showAllRibbons" is true


newRibbons

public RibbonBackboneShape newRibbons(Molecule mol,
                                      TreeNodeSet set)

newResidueLabels

public ResidueLabelShape newResidueLabels(Molecule mol)
Make a new ResidueLabelShape visuization of the molecule, add it to database if set to


newResidueLabels

public ResidueLabelShape newResidueLabels(Molecule mol,
                                          TreeNodeSet set)

newBAS

public BASShape newBAS(Molecule mol)
Make a new BASShape visuization of the molecule, add it to database if set to, and add all atoms and bonds of of the molecule if "showAllBAS" is true


newBAS

public BASShape newBAS(Molecule mol,
                       TreeNodeSet set)

newWire

public WireShape newWire(Molecule mol)
Make a new WireShape visuization of the molecule, add it to database if set to, and add all atoms and bonds of of the molecule if "showAllWire" is true


newWire

public WireShape newWire(Molecule mol,
                         TreeNodeSet set)

addElements

public void addElements(VVM_RepShape rep,
                        TreeNodeSet set)
Add the elements to the rendition. If the elements are in the wrong domain, the set is casted to a set of the right domain, for example if a residue set is passed into the CPK shape, the set is casted to an atom set first


removeElements

public void removeElements(VVM_RepShape rep,
                           TreeNodeSet set)
Remove the elements from the rendition. If the elements are in the wrong domain, the set is casted to a set of the right domain, for example if a residue set is passed into the CPK shape, the set is casted to an atom set first


interpret

public TreeNodeSet interpret(java.lang.String expression,
                             Molecule mol)
Return set of elements from expression. String is broken up in the traditional way like this: MOLSET:RESSET:ATOMSET. Each group after a colon is depenant on the context of the colon before it.


allChains

public ChainSet allChains(Molecule mol)
All chains in molecule


interpretChains

public ChainSet interpretChains(java.lang.String expression,
                                Molecule mol)
Chains matching expression


interpretChains

public ChainSet interpretChains(java.lang.String expression,
                                ChainSet superset)
Chains matching expression


coerseToChains

public ChainSet coerseToChains(TreeNodeSet defSet)
Chains from another set


allResidues

public ResidueSet allResidues(Molecule mol)
All residue in molecule


interpretResidues

public ResidueSet interpretResidues(java.lang.String expression,
                                    Molecule mol)
Residues matching expression


interpretResidues

public ResidueSet interpretResidues(java.lang.String expression,
                                    ResidueSet superset)
Residues matching expression


coerseToResidues

public ResidueSet coerseToResidues(TreeNodeSet defSet)
Residues from another set


allAtoms

public AtomSet allAtoms(Molecule mol)
All atoms in molecule


interpretAtoms

public AtomSet interpretAtoms(java.lang.String expression,
                              Molecule mol)
Atoms matching expression


interpretAtoms

public AtomSet interpretAtoms(java.lang.String expression,
                              AtomSet superset)
Atoms matching expression


coerseToAtoms

public AtomSet coerseToAtoms(TreeNodeSet defSet)
Atoms from another set


coerseToBonds

public BondSet coerseToBonds(TreeNodeSet defSet)
Bonds from another set