]> git.treefish.org Git - phys/latlib.git/blobdiff - writeout.h
added writeout class
[phys/latlib.git] / writeout.h
diff --git a/writeout.h b/writeout.h
new file mode 100644 (file)
index 0000000..48057d4
--- /dev/null
@@ -0,0 +1,27 @@
+#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