removed getStream() (useless)

This commit is contained in:
James Turk 2005-02-05 03:01:03 +00:00
parent c91537f01d
commit 92af63f151
2 changed files with 8 additions and 22 deletions

View File

@ -5,10 +5,13 @@
// James Turk (jpt2433@rit.edu) // James Turk (jpt2433@rit.edu)
// //
// Version: // Version:
// $Id: LogSink.h,v 1.3 2005/02/04 08:11:54 cozman Exp $ // $Id: LogSink.h,v 1.4 2005/02/05 03:01:03 cozman Exp $
// //
// Revisions: // Revisions:
// $Log: LogSink.h,v $ // $Log: LogSink.h,v $
// Revision 1.4 2005/02/05 03:01:03 cozman
// removed getStream() (useless)
//
// Revision 1.3 2005/02/04 08:11:54 cozman // Revision 1.3 2005/02/04 08:11:54 cozman
// switched Log to shared_ptrs and added extra flushes // switched Log to shared_ptrs and added extra flushes
// //
@ -102,8 +105,6 @@ public:
// Name of the LogSink. // Name of the LogSink.
std::string getName() const; std::string getName() const;
virtual std::ostream& getStream()=0;
private: private:
std::string name_; std::string name_;
@ -132,7 +133,6 @@ public:
virtual ~ConsoleSink(); virtual ~ConsoleSink();
virtual void writeMessage(LogLevel level, std::string msg); virtual void writeMessage(LogLevel level, std::string msg);
virtual std::ostream& getStream();
}; };
// Class: TextSink // Class: TextSink
@ -150,7 +150,6 @@ public:
virtual ~TextSink(); virtual ~TextSink();
virtual void writeMessage(LogLevel level, std::string msg); virtual void writeMessage(LogLevel level, std::string msg);
virtual std::ostream& getStream();
private: private:
std::ofstream out_; std::ofstream out_;
}; };
@ -170,7 +169,6 @@ public:
virtual ~HTMLSink(); virtual ~HTMLSink();
virtual void writeMessage(LogLevel level, std::string msg); virtual void writeMessage(LogLevel level, std::string msg);
virtual std::ostream& getStream();
private: private:
std::ofstream out_; std::ofstream out_;
}; };

View File

@ -5,10 +5,13 @@
// James Turk (jpt2433@rit.edu) // James Turk (jpt2433@rit.edu)
// //
// Version: // Version:
// $Id: LogSink.cpp,v 1.3 2005/02/04 08:11:54 cozman Exp $ // $Id: LogSink.cpp,v 1.4 2005/02/05 03:01:04 cozman Exp $
// //
// Revisions: // Revisions:
// $Log: LogSink.cpp,v $ // $Log: LogSink.cpp,v $
// Revision 1.4 2005/02/05 03:01:04 cozman
// removed getStream() (useless)
//
// Revision 1.3 2005/02/04 08:11:54 cozman // Revision 1.3 2005/02/04 08:11:54 cozman
// switched Log to shared_ptrs and added extra flushes // switched Log to shared_ptrs and added extra flushes
// //
@ -65,11 +68,6 @@ void ConsoleSink::writeMessage(LogLevel level, std::string msg)
std::cerr << pre[static_cast<int>(level)] << msg << std::endl; std::cerr << pre[static_cast<int>(level)] << msg << std::endl;
} }
std::ostream& ConsoleSink::getStream()
{
return std::cerr;
}
//TextSink //TextSink
TextSink::TextSink(std::string name) : TextSink::TextSink(std::string name) :
@ -94,11 +92,6 @@ void TextSink::writeMessage(LogLevel level, std::string msg)
out_ << pre[static_cast<int>(level)] << msg << std::endl; out_ << pre[static_cast<int>(level)] << msg << std::endl;
} }
std::ostream& TextSink::getStream()
{
return out_;
}
//HTMLSink //HTMLSink
HTMLSink::HTMLSink(std::string name) : HTMLSink::HTMLSink(std::string name) :
@ -138,9 +131,4 @@ void HTMLSink::writeMessage(LogLevel level, std::string msg)
<< pre[static_cast<int>(level)] << msg << "</p>" << std::endl; << pre[static_cast<int>(level)] << msg << "</p>" << std::endl;
} }
std::ostream& HTMLSink::getStream()
{
return out_;
}
} }