A unary functor which forwards to s11nlite::save(node_type|SerializableT,ostream). More...
#include <s11nlite.hpp>
Public Types | |
typedef ::s11nlite::node_type | node_type |
Public Member Functions | |
save_stream_unary_f (std::ostream &os) | |
Specifies that operator() should send output to the given stream. | |
bool | operator() (node_type const &src) const |
Returns s11nlite:;save( src, this->stream ). | |
template<typename SerT > | |
bool | operator() (SerT const &src) const |
Returns s11nlite:;save( src, this->stream ). | |
Public Attributes | |
std::ostream & | stream |
A unary functor which forwards to s11nlite::save(node_type|SerializableT,ostream).
Note that while this type conforms to two s11n-standard tags (its parent classes), it is not *really* intended to be used as a normal part of a serialization algorithm. That said, that approach may indeed turn out to have some interesting uses. It certainly has some pitfalls, in any case, so don't blythely do it.
Added in version 1.1.3.
Definition at line 509 of file s11nlite.hpp.
Definition at line 512 of file s11nlite.hpp.
s11nlite::save_stream_unary_f::save_stream_unary_f | ( | std::ostream & | os | ) | [inline, explicit] |
Specifies that operator() should send output to the given stream.
Definition at line 518 of file s11nlite.hpp.
bool s11nlite::save_stream_unary_f::operator() | ( | SerT const & | src | ) | const [inline] |
Returns s11nlite:;save( src, this->stream ).
Definition at line 533 of file s11nlite.hpp.
References s11nlite::save(), and stream.
bool s11nlite::save_stream_unary_f::operator() | ( | node_type const & | src | ) | const [inline] |
Returns s11nlite:;save( src, this->stream ).
Definition at line 524 of file s11nlite.hpp.
References s11nlite::save(), and stream.
std::ostream& s11nlite::save_stream_unary_f::stream |
Definition at line 513 of file s11nlite.hpp.
Referenced by operator()().