staticlib_io  1.2.11
 All Classes Namespaces Files Functions Variables
Public Member Functions | List of all members
staticlib::io::memory_sink Class Reference

Sink implementation that writes into fixed-size memory area. More...

#include <staticlib/io/memory_sink.hpp>

Public Member Functions

 memory_sink (span< char > dest)
 Constructor.
 memory_sink (const memory_sink &other)
 Copy constructor.
memory_sink & operator= (const memory_sink &other)
 Copy assignment operator.
 memory_sink (memory_sink &&other) STATICLIB_NOEXCEPT
 Move constructor.
memory_sink & operator= (memory_sink &&other) STATICLIB_NOEXCEPT
 Move assignment operator.
std::streamsize write (span< const char > span)
 Write implementation.
std::streamsize flush ()
 No-op flush implementation.

Detailed Description

Sink implementation that writes into fixed-size memory area.

Exception is thrown on overwrite.

Constructor & Destructor Documentation

staticlib::io::memory_sink::memory_sink ( span< char >  dest)
inline

Constructor.

staticlib::io::memory_sink::memory_sink ( const memory_sink &  other)
inline

Copy constructor.

Parameters
otherinstance
staticlib::io::memory_sink::memory_sink ( memory_sink &&  other)
inline

Move constructor.

Parameters
otherother instance

Member Function Documentation

std::streamsize staticlib::io::memory_sink::flush ( )
inline

No-op flush implementation.

Returns
0
memory_sink& staticlib::io::memory_sink::operator= ( const memory_sink &  other)
inline

Copy assignment operator.

Parameters
otherinstance
Returns
this instance
memory_sink& staticlib::io::memory_sink::operator= ( memory_sink &&  other)
inline

Move assignment operator.

Parameters
otherother instance
Returns
this instance
std::streamsize staticlib::io::memory_sink::write ( span< const char >  span)
inline

Write implementation.

Parameters
spanbuffer span
Returns
specified length

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