#include <Molecule.h>
Inheritance diagram for Molecule:

Public Methods | |
| Molecule (const char *, VMDApp *, Displayable *) | |
| constructor ... nothing much to do, just save the source, and pass on the other data. Pass the VMDApp and parent Displayable on to DrawMolecule. More... | |
| virtual | ~Molecule (void) |
| destructor ... just clear out unread files. More... | |
| int | rename (const char *newname) |
| rename the molecule, as shown in the GUI and as accessed by text commands. More... | |
| int | num_files () const |
| Return the number of file components that make up the loaded molecule. More... | |
| const char * | get_type (int i) const |
| Return the file type of the indexed molecule file component. More... | |
| const char * | get_file (int i) const |
| Return the file name of the indexed molecule file component. More... | |
| const char * | get_file_specs (int i) const |
| Return the file loading specs of the indexed molecule file component. More... | |
| const char * | get_database (int i) const |
| Return the source database of the indexed molecule file component. More... | |
| const char * | get_accession (int i) const |
| Return the database accession code of the indexed molecule file component. More... | |
| const char * | get_remarks (int i) const |
| Return the text comments for the indexed molecule file component. More... | |
| void | record_file (const char *filename, const char *filetype, const char *filespecs) |
| Record the file component's name, type, and loading specs in the molecule. More... | |
| void | record_database (const char *dbname, const char *dbcode) |
| Record the file component's source database and accession code in the molecule. More... | |
| void | record_remarks (const char *remarks) |
| Record the file component's text comments in the molecule. More... | |
| void | add_coor_file (CoorData *) |
| add a CoorFile object to the file I/O queue. Molecule will read/write frames until the CoorFileData object says its finished. Then Molecule will delete it. More... | |
| int | get_new_frames () |
| Check for new trajectory frames in I/O queue and IMD. More... | |
| int | next_frame () |
| Read the next frame in the file I/O queue. Return true if any frames were read; otherwise return false. More... | |
| int | cancel () |
| cancel loading/saving of all coordinate files return number of files canceled. More... | |
| int | file_in_progress () |
| return true if file I/O is in progress. More... | |
| virtual void | prepare () |
| prepare for drawing ... do any updates needed right before draw. This possibly reads a new timestep, if requested. More... | |
| void | addForce (int theatom, const float *f) |
| add a force <f> to atom #<theatom> for this display loop only. More... | |
| void | addPersistentForce (int theatom, const float *f) |
| add a persistent force to the given atom; this will stay until cleared (by making the force zero). This force will be added to any other forces coming from addForce. More... | |
Definition at line 37 of file Molecule.h.
|
||||||||||||||||
|
constructor ... nothing much to do, just save the source, and pass on the other data. Pass the VMDApp and parent Displayable on to DrawMolecule.
Definition at line 39 of file Molecule.C. References breakup_filename, BaseMolecule::moleculename, NULL, and stringdup. |
|
|
destructor ... just clear out unread files.
Definition at line 53 of file Molecule.C. References DrawMolecule::app, BaseMolecule::id, VMDApp::imd_disconnect, BaseMolecule::moleculename, ResizeArray< char * >::num, ResizeArray< CoorData * >::num, and ResizeArray< CoorData * >::remove. |
|
|
add a CoorFile object to the file I/O queue. Molecule will read/write frames until the CoorFileData object says its finished. Then Molecule will delete it.
Definition at line 95 of file Molecule.C. References ResizeArray< CoorData * >::append, and data. Referenced by VMDApp::molecule_load, and VMDApp::molecule_savetrajectory. |
|
||||||||||||
|
add a force <f> to atom #<theatom> for this display loop only.
Definition at line 253 of file Molecule.C. References ResizeArray< float >::append, and ResizeArray< int >::append. Referenced by GeometrySpring::prepare, and Tool::tug. |
|
||||||||||||
|
add a persistent force to the given atom; this will stay until cleared (by making the force zero). This force will be added to any other forces coming from addForce.
Definition at line 258 of file Molecule.C. References ResizeArray< float >::append, ResizeArray< int >::append, ResizeArray< int >::find, ResizeArray< float >::remove, ResizeArray< int >::remove, and Displayable::reset_disp_list. |
|
|
cancel loading/saving of all coordinate files return number of files canceled.
Definition at line 101 of file Molecule.C. References ResizeArray< CoorData * >::num, and ResizeArray< CoorData * >::remove. Referenced by VMDApp::molecule_cancel_io. |
|
|
return true if file I/O is in progress.
Definition at line 135 of file Molecule.h. References ResizeArray< CoorData * >::num. Referenced by DrawMolItem::prepare. |
|
|
Return the database accession code of the indexed molecule file component.
Definition at line 88 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by get_accessions, and molinfo_get. |
|
|
Return the source database of the indexed molecule file component.
Definition at line 82 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by get_databases, and molinfo_get. |
|
|
Return the file name of the indexed molecule file component.
Definition at line 70 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by get_filenames, and molinfo_get. |
|
|
Return the file loading specs of the indexed molecule file component.
Definition at line 76 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by molinfo_get. |
|
|
Check for new trajectory frames in I/O queue and IMD.
Definition at line 113 of file Molecule.C. References DrawMolecule::app, ResizeArray::append, ResizeArray< float >::append, ResizeArray< int >::append, VMDApp::background_processing_set, ResizeArray< float >::clear, ResizeArray< int >::clear, DrawMolecule::current, Timestep::force, BaseMolecule::id, VMDApp::imd_connected, VMDApp::imd_sendforces, BaseMolecule::nAtoms, next_frame, ResizeArray::num, ResizeArray< float >::num, and ResizeArray< int >::num. Referenced by prepare, and VMDApp::VMDupdate. |
|
|
Return the text comments for the indexed molecule file component.
Definition at line 94 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by get_remarks, and molinfo_get. |
|
|
Return the file type of the indexed molecule file component.
Definition at line 64 of file Molecule.h. References NULL, and ResizeArray::num. Referenced by get_filetypes, and molinfo_get. |
|
|
Read the next frame in the file I/O queue. Return true if any frames were read; otherwise return false.
Definition at line 215 of file Molecule.C. References DrawMolecule::app, CommandQueue::append, VMDApp::commandQueue, CoorData::CoorDataState, CoorData::DONE, BaseMolecule::id, CoorData::NOTDONE, ResizeArray< CoorData * >::num, and ResizeArray< CoorData * >::remove. Referenced by get_new_frames, and VMDApp::molecule_load. |
|
|
Return the number of file components that make up the loaded molecule.
Definition at line 61 of file Molecule.h. References ResizeArray::num. Referenced by get_accessions, get_databases, get_filenames, get_filetypes, get_remarks, and molinfo_get. |
|
|
prepare for drawing ... do any updates needed right before draw. This possibly reads a new timestep, if requested.
Reimplemented from DrawMolecule. Definition at line 248 of file Molecule.C. References get_new_frames, and DrawMolecule::prepare. |
|
||||||||||||
|
Record the file component's source database and accession code in the molecule.
Definition at line 108 of file Molecule.h. References ResizeArray::append, and stringdup. Referenced by VMDApp::molecule_load, and MolFilePlugin::read_metadata. |
|
||||||||||||||||
|
Record the file component's name, type, and loading specs in the molecule.
Definition at line 100 of file Molecule.h. References ResizeArray::append, and stringdup. Referenced by VMDApp::molecule_load. |
|
|
Record the file component's text comments in the molecule.
Definition at line 114 of file Molecule.h. References ResizeArray::append, and stringdup. Referenced by VMDApp::molecule_load, and MolFilePlugin::read_metadata. |
|
|
rename the molecule, as shown in the GUI and as accessed by text commands.
Definition at line 89 of file Molecule.C. References BaseMolecule::moleculename, and stringdup. Referenced by VMDApp::molecule_rename. |
1.2.14 written by Dimitri van Heesch,
© 1997-2002