#ifndef already_included_writer_hh
#define already_included_writer_hh
class string;
ABSTRACT class Writer
{
public:
virtual ~Writer() {}
virtual Writer& operator << (char ch) = null;
virtual Writer& operator << (int i) = null;
virtual Writer& operator << (double d) = null;
virtual Writer& operator << (const char* s) = null;
};
Writer& operator<<(Writer& w,bool b);
final class File_Writer : public Writer
{
private:
FILE* f;
bool ours_to_close;
public:
File_Writer(string file_name);
File_Writer(const char* file_name);
File_Writer(FILE* f);
~File_Writer();
Writer& operator << (char ch);
Writer& operator << (int i);
Writer& operator << (double d);
Writer& operator << (const char* s);
};
extern File_Writer cout;
extern File_Writer cerr;
extern File_Writer debug;
const char endl = '\n';
#endif