w11 - cpp 0.794
Backend server for Rlink and w11
Loading...
Searching...
No Matches
RosFill.cpp
Go to the documentation of this file.
1// $Id: RosFill.cpp 1186 2019-07-12 17:49:59Z mueller $
2// SPDX-License-Identifier: GPL-3.0-or-later
3// Copyright 2000-2011 by Walter F.J. Mueller <W.F.J.Mueller@gsi.de>
4//
5// Revision History:
6// Date Rev Version Comment
7// 2011-02-25 364 1.1 Support << also to string
8// 2011-01-30 357 1.0 Adopted from RosFill
9// 2000-02-29 - - Last change on RosFill
10// ---------------------------------------------------------------------------
11
16#include "RosFill.hpp"
17
18using namespace std;
19
51// all method definitions in namespace Retro
52namespace Retro {
53
54//------------------------------------------+-----------------------------------
60std::ostream& operator<<(std::ostream& os, const RosFill& obj)
61{
62 for (int i=0; i<obj.Count(); i++) os.put(obj.Fill());
63 return os;
64}
65
66//------------------------------------------+-----------------------------------
72std::string& operator<<(std::string& os, const RosFill& obj)
73{
74 for (int i=0; i<obj.Count(); i++) os.push_back(obj.Fill());
75 return os;
76}
77
78} // end namespace Retro
I/O appicator to generate fill characters.
Definition: RosFill.hpp:24
std::ostream & operator<<(std::ostream &os, const RosFill &obj)
ostream insertion operator.
Definition: RosFill.cpp:60
std::string & operator<<(std::string &os, const RosFill &obj)
string insertion operator.
Definition: RosFill.cpp:72
int Count() const
Get repeat count.
Definition: RosFill.ipp:35
char Fill() const
Get fill character.
Definition: RosFill.ipp:43
Declaration of class ReventLoop.
Definition: ReventLoop.cpp:47