staticlib_io  1.2.11
 All Classes Namespaces Files Functions Variables
Public Member Functions | List of all members
staticlib::io::shared_source< Source > Class Template Reference

Source wrapper that holds a "std::shared_ptr" to the underlying source. More...

#include <staticlib/io/shared_source.hpp>

Public Member Functions

 shared_source (std::shared_ptr< Source > src)
 Constructor.
 shared_source (const shared_source &other)
 Copy constructor.
shared_source & operator= (const shared_source &other)
 Copy assignment operator.
 shared_source (shared_source &&other) STATICLIB_NOEXCEPT
 Move constructor.
shared_source & operator= (shared_source &&other) STATICLIB_NOEXCEPT
 Move assignment operator.
std::streamsize read (span< char > span)
 Read implementation delegated to the underlying source.
Source & get_source ()
 Underlying source accessor.

Detailed Description

template<typename Source>
class staticlib::io::shared_source< Source >

Source wrapper that holds a "std::shared_ptr" to the underlying source.

Constructor & Destructor Documentation

template<typename Source >
staticlib::io::shared_source< Source >::shared_source ( std::shared_ptr< Source >  src)
inline

Constructor.

Parameters
srcinput source
template<typename Source >
staticlib::io::shared_source< Source >::shared_source ( const shared_source< Source > &  other)
inline

Copy constructor.

Parameters
otherinstance
template<typename Source >
staticlib::io::shared_source< Source >::shared_source ( shared_source< Source > &&  other)
inline

Move constructor.

Parameters
otherother instance

Member Function Documentation

template<typename Source >
Source& staticlib::io::shared_source< Source >::get_source ( )
inline

Underlying source accessor.

Returns
underlying source reference
template<typename Source >
shared_source& staticlib::io::shared_source< Source >::operator= ( const shared_source< Source > &  other)
inline

Copy assignment operator.

Parameters
otherinstance
Returns
this instance
template<typename Source >
shared_source& staticlib::io::shared_source< Source >::operator= ( shared_source< Source > &&  other)
inline

Move assignment operator.

Parameters
otherother instance
Returns
this instance
template<typename Source >
std::streamsize staticlib::io::shared_source< Source >::read ( span< char >  span)
inline

Read implementation delegated to the underlying source.

Parameters
spanbuffer span
Returns
number of bytes processed

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