+#ifndef WRITEOUT_H
+#define WRITEOUT_H
+
+#include <ostream>
+#include <fstream>
+
+using namespace std;
+
+class writeout
+{
+ public:
+ writeout(const string& wdir, const string& signature,
+ const int& rank, const int& procs);
+ ostream *out;
+ ~writeout();
+
+ private:
+ ofstream of;
+ streambuf *buf;
+ string fulldir;
+ char cRank[20];
+ string tstamp();
+ int numprocs;
+ string getdatfile();
+};
+
+#endif