Main Page   Class Hierarchy   Compound List   File List   Compound Members  

OstreamManager.h

00001 #ifndef OSTREAM_MANAGER_H
00002 #define OSTREAM_MANAGER_H
00003 
00004 #include <string>
00005 #include "IOException.h"
00006 
00007 namespace MFUtil
00008 {
00012   class OstreamManager
00013   {
00014   public:
00015 
00019     virtual ~OstreamManager();
00020 
00025     OstreamManager( const std::string& p_filename );
00026 
00030     OstreamManager( std::ostream& p_ostream ) : m_filename(""), m_use_ofstream(false)
00031     {
00032      m_ostream_p = &p_ostream;
00033     }
00034 
00038     std::ostream& getStream( void ){ return *m_ostream_p; }
00039 
00040   private:
00041 
00042     std::ostream* m_ostream_p;
00043     std::string m_filename;
00044     bool m_use_ofstream;
00045   };
00046 }
00047 #endif
00048 e;
00049     bool m_use_ofstream;
00050   };
00051 }
00052 #endif

Generated on Sat Nov 4 15:58:59 2006 for GLARE by doxygen1.2.18