#include <trajectoryFile.h>
Inheritance diagram for TrajectoryFile:
Public Member Functions | |
Constructors and Destructor | |
TrajectoryFile () throw () | |
Default constructor. | |
TrajectoryFile (const TrajectoryFile &file) throw () | |
Copy constructor. | |
TrajectoryFile (const String &filename, File::OpenMode open_mode=std::ios::in) throw (Exception::FileNotFound) | |
Detailed constructor requiring a filename and the mode in which this file should be opened. | |
virtual | ~TrajectoryFile () throw () |
Destructor. | |
Assignment | |
const TrajectoryFile & | operator= (const TrajectoryFile &file) throw () |
Assignment operator. | |
virtual void | clear () throw () |
Clear method. | |
Predicates | |
bool | operator== (const TrajectoryFile &file) const throw () |
Equality operator. | |
Accessors | |
Size | getNumberOfSnapShots () const throw () |
get the number of snapshots stored in this instance. | |
Size | getNumberOfAtoms () const throw () |
get the number of atoms coverd by each snapshot. | |
Public methods for file handling | |
virtual bool | readHeader () throw () |
Read the header of an existing file. | |
virtual bool | writeHeader () throw () |
Write a header. | |
virtual bool | append (const SnapShot &snapshot) throw () |
Append a SnapShot to an existing file. | |
virtual bool | read (SnapShot &snapshot) throw () |
Read the next SnapShot from the file. | |
virtual bool | flushToDisk (const std::vector< SnapShot > &buffer) throw (File::CannotWrite) |
Write several SnapShots to disk. | |
Protected Attributes | |
Size | number_of_snapshots_ |
Size | number_of_atoms_ |
This is more an interface definition than an actual class, because it would not make too much sense to create yet-another-trajectory-format. This class will be specialized by actual formats, like DCD.
|
Detailed constructor requiring a filename and the mode in which this file should be opened.
|
|
Append a SnapShot to an existing file. Note that this method does note update the header.
|
|
Write several SnapShots to disk.
|
|
get the number of atoms coverd by each snapshot.
|
|
get the number of snapshots stored in this instance.
|
|
Read the next SnapShot from the file.
|
|
Read the header of an existing file.
Reimplemented in DCDFile. |
|
Write a header.
Reimplemented in DCDFile. |