Public Member Functions | List of all members
ecl::ClearScreen Class Reference

Manipulator that clears a terminal screen the c++ (hard) way. More...

#include <clear_screen.hpp>

Inheritance diagram for ecl::ClearScreen:
Inheritance graph
[legend]

Public Member Functions

template<typename ODevice >
void action (interfaces::OutputTextStream< ODevice, true > &ostream)
 Clears a terminal screen the c++ (hard) way. More...
 
virtual ~ClearScreen ()
 
- Public Member Functions inherited from ecl::Manipulator< ClearScreen >
void insert (interfaces::OutputTextStream< ODevice, true > &ostream)
 The static crtp virtual parent call. More...
 
virtual ~Manipulator ()
 

Detailed Description

Manipulator that clears a terminal screen the c++ (hard) way.

Function object manipulator that clears an output terminal screen the hard (c++) way by sending 80 new lines to it.

The library instantiates a variable of this class under the name 'clrscr', so you need only refer to ecl::streams::clrscr to directly use it with your streams.

See also
Manipulator.

Definition at line 48 of file clear_screen.hpp.

Constructor & Destructor Documentation

virtual ecl::ClearScreen::~ClearScreen ( )
inlinevirtual

Definition at line 69 of file clear_screen.hpp.

Member Function Documentation

template<typename ODevice >
void ecl::ClearScreen::action ( interfaces::OutputTextStream< ODevice, true > &  ostream)
inline

Clears a terminal screen the c++ (hard) way.

Not very fast on most systems - hammers the terminal with alot of newlines. In windows this causes a problem since terminal screens are so slow and on screens with large resolutions, the 80 lines is not enough. Might actually implement system specific code for this at some time in the future.

Template Parameters
OutputStream: the output stream type.
Parameters
ostream: the stream to use for manipulation.

Definition at line 64 of file clear_screen.hpp.


The documentation for this class was generated from the following file:


xbot_driver
Author(s): Roc, wangpeng@droid.ac.cn
autogenerated on Sat Oct 10 2020 03:27:38