BALL 1.5.0
trajectoryFile.h
Go to the documentation of this file.
1// -*- Mode: C++; tab-width: 2; -*-
2// vi: set ts=2:
3//
4
5#ifndef BALL_FORMAT_TRAJECTORYFILE_H
6#define BALL_FORMAT_TRAJECTORYFILE_H
7
8#ifndef BALL_SYSTEM_FILE_H
9# include <BALL/SYSTEM/file.h>
10#endif
11
12#ifndef BALL_MOLMEC_COMMON_SNAPSHOT_H
14#endif
15
16namespace BALL
17{
18 class SnapShot;
19 class SnapShotManager;
20
29 : public File
30 {
31
32 public:
33
35
36
39
47 TrajectoryFile(const String& filename,
48 File::OpenMode open_mode = std::ios::in);
49
51 virtual ~TrajectoryFile();
52
54
56
58 virtual void clear();
59
61
63
65 bool operator == (const TrajectoryFile& file) const;
66
68
70
75
80
82
84
88 virtual bool readHeader();
89
93 virtual bool writeHeader();
94
100 virtual bool append(const SnapShot& snapshot);
101
106 virtual bool read(SnapShot& snapshot);
107
113 virtual bool flushToDisk(const std::vector<SnapShot>& buffer);
115
116 private:
117 const TrajectoryFile& operator = (const TrajectoryFile& file);
118
119 protected:
120
121 //_ @name Protected Members
123
124 //_ The number of snapshots stored in that file
126
127 //_ The number of atoms covered by the snapshots
129
131
132 };
133} // namespace BALL
134
135#endif // BALL_FORMAT_TRAJECTORYFILE_H
Definition: constants.h:13
BALL_EXPORT bool operator==(const String &s1, const String &s2)
virtual bool readHeader()
virtual bool writeHeader()
TrajectoryFile()
Default constructor.
virtual bool flushToDisk(const std::vector< SnapShot > &buffer)
virtual ~TrajectoryFile()
Destructor.
virtual bool read(SnapShot &snapshot)
TrajectoryFile(const String &filename, File::OpenMode open_mode=std::ios::in)
virtual Size getNumberOfSnapShots()
virtual bool append(const SnapShot &snapshot)
virtual void clear()
Clear method.
Size getNumberOfAtoms() const
std::ios::openmode OpenMode
Definition: file.h:165
#define BALL_EXPORT
Definition: COMMON/global.h:50