BOSS 7.0.3
BESIII Offline Software System
Loading...
Searching...
No Matches
InstallArea/include/ers/ers/HumanStream.h
Go to the documentation of this file.
1/*
2 * HumanStream.h
3 * ers
4 *
5 * Created by Matthias Wiesmann on 01.11.04.
6 * Copyright 2004 CERN. All rights reserved.
7 *
8 */
9
10
11#include <ostream>
12#include <sstream>
13
14#include "ers/Stream.h"
15
16namespace ers {
17
18/** This class streams an issue into an human readable string.
19 * It is uses by the issue class to display itself.
20 * This stream can be specified for other uses, but the user is then responsible
21 * for reading data from the stream and clearing it.
22 * \author Matthias Wiesmann
23 * \version 1.0
24 * \brief Single line, human readable format stream.
25 */
26
27class HumanStream : public Stream {
28protected:
29 std::ostringstream m_out_stream ;
30public:
31 static std::string to_string(const Issue *issue) throw() ;
32 static const char* const KEY ;
34 HumanStream(const HumanStream &other);
36 std::string to_string() ;
37 void clear() ;
38 virtual void send(const Issue *ptr);
39 virtual void print_to(std::ostream& stream) const ;
40
41} ; // human_stream
42
43} // namespace ers
44
Single line, human readable format stream.
std::string to_string()
HumanStream(const HumanStream &other)
virtual void print_to(std::ostream &stream) const
virtual void send(const Issue *ptr)
Sends an issue into the stream.
static std::string to_string(const Issue *issue)