The Gaudi Framework  v29r0 (ff2e7097)
StreamLogger.cpp
Go to the documentation of this file.
1 #include "StreamLogger.h"
2 #include <fstream>
3 
5  : m_name{"file:" + file}, m_oost{new std::ofstream( file )}, m_ost{m_oost.get()}
6 {
7  if ( !m_oost ) throw std::invalid_argument( "can't open file" );
8 }
9 
11  : m_name{"MsgStream"}, m_msgStr{new MsgStream( svc, "IssueLogger" )}, m_level{lev}
12 {
13 }
14 
16  : m_name{&ost == &std::cerr ? "STDERR" : &ost == &std::cout ? "STDOUT" : "unknown ostream"}, m_ost{&ost}
17 {
18 }
Definition of the MsgStream class used to transmit messages.
Definition: MsgStream.h:24
std::unique_ptr< MsgStream > m_msgStr
Definition: StreamLogger.h:27
StreamLogger(const std::string &file)
Definition: StreamLogger.cpp:4
std::string m_name
Definition: StreamLogger.h:24
STL class.
STL class.
The IMessage is the interface implemented by the message service.
Definition: IMessageSvc.h:38
T get(T...args)
std::unique_ptr< std::ostream > m_oost
Definition: StreamLogger.h:25
STL class.
MSG::Level m_level
Definition: StreamLogger.h:28
std::ostream * m_ost
Definition: StreamLogger.h:26