Loading...
Searching...
No Matches
trajectoryFile.h
Go to the documentation of this file.
// -*- Mode: C++; tab-width: 2; -*-
// vi: set ts=2:
//
#ifndef BALL_FORMAT_TRAJECTORYFILE_H
#define BALL_FORMAT_TRAJECTORYFILE_H
#ifndef BALL_SYSTEM_FILE_H
# include <BALL/SYSTEM/file.h>
#endif
#ifndef BALL_MOLMEC_COMMON_SNAPSHOT_H
# include <BALL/MOLMEC/COMMON/snapShot.h>
#endif
namespace BALL
{
class SnapShot;
class SnapShotManager;
class BALL_EXPORT TrajectoryFile
: public File
{
public:
TrajectoryFile();
TrajectoryFile(const String& filename,
File::OpenMode open_mode = std::ios::in);
virtual ~TrajectoryFile();
virtual void clear();
bool operator == (const TrajectoryFile& file) const;
virtual Size getNumberOfSnapShots();
Size getNumberOfAtoms() const;
virtual bool readHeader();
virtual bool writeHeader();
virtual bool append(const SnapShot& snapshot);
virtual bool read(SnapShot& snapshot);
virtual bool flushToDisk(const std::vector<SnapShot>& buffer);
private:
const TrajectoryFile& operator = (const TrajectoryFile& file);
protected:
//_ @name Protected Members
//_ The number of snapshots stored in that file
Size number_of_snapshots_;
//_ The number of atoms covered by the snapshots
Size number_of_atoms_;
};
} // namespace BALL
#endif // BALL_FORMAT_TRAJECTORYFILE_H
BALL_EXPORT
#define BALL_EXPORT
Definition COMMON/global.h:50
BALL::File::File
File()
BALL::File::OpenMode
std::ios::openmode OpenMode
Definition file.h:165
BALL::SnapShotManager
Definition snapShotManager.h:34
BALL::SnapShot
Definition snapShot.h:30
BALL::String
Definition string.h:57
BALL::TrajectoryFile::readHeader
virtual bool readHeader()
BALL::TrajectoryFile::writeHeader
virtual bool writeHeader()
BALL::TrajectoryFile::number_of_atoms_
Size number_of_atoms_
Definition trajectoryFile.h:128
BALL::TrajectoryFile::TrajectoryFile
TrajectoryFile()
Default constructor.
BALL::TrajectoryFile::flushToDisk
virtual bool flushToDisk(const std::vector< SnapShot > &buffer)
BALL::TrajectoryFile::number_of_snapshots_
Size number_of_snapshots_
Definition trajectoryFile.h:125
BALL::TrajectoryFile::~TrajectoryFile
virtual ~TrajectoryFile()
Destructor.
BALL::TrajectoryFile::read
virtual bool read(SnapShot &snapshot)
BALL::TrajectoryFile::TrajectoryFile
TrajectoryFile(const String &filename, File::OpenMode open_mode=std::ios::in)
BALL::TrajectoryFile::getNumberOfSnapShots
virtual Size getNumberOfSnapShots()
BALL::TrajectoryFile::append
virtual bool append(const SnapShot &snapshot)
BALL::TrajectoryFile::clear
virtual void clear()
Clear method.
BALL::TrajectoryFile::getNumberOfAtoms
Size getNumberOfAtoms() const
file.h
BALL
Definition constants.h:13
BALL::Size
BALL_SIZE_TYPE Size
Definition COMMON/global.h:114
snapShot.h