#include <iostream.h>

Public Member Functions | |
| scoped_estream_redirect (std::ostream &costream=std::cerr, const object &pyostream=module_::import("sys").attr("stderr")) | |
Public Member Functions inherited from scoped_ostream_redirect | |
| scoped_ostream_redirect & | operator= (const scoped_ostream_redirect &)=delete |
| scoped_ostream_redirect & | operator= (scoped_ostream_redirect &&)=delete |
| scoped_ostream_redirect (const scoped_ostream_redirect &)=delete | |
| scoped_ostream_redirect (scoped_ostream_redirect &&other)=default | |
| scoped_ostream_redirect (std::ostream &costream=std::cout, const object &pyostream=module_::import("sys").attr("stdout")) | |
| ~scoped_ostream_redirect () | |
Additional Inherited Members | |
Protected Attributes inherited from scoped_ostream_redirect | |
| detail::pythonbuf | buffer |
| std::ostream & | costream |
| std::streambuf * | old |
\rst Like scoped_ostream_redirect, but redirects cerr by default. This class is provided primary to make py::call_guard easier to make.
.. code-block:: cpp
m.def("noisy_func", &noisy_func, py::call_guard<scoped_ostream_redirect, scoped_estream_redirect>());
\endrst
Definition at line 192 of file iostream.h.
|
inlineexplicit |
Definition at line 194 of file iostream.h.