Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of boost. Click here for the latest Boost documentation.
PrevUpHomeNext

Class template basic_ibufferstream

boost::interprocess::basic_ibufferstream

Synopsis

// In header: <boost/interprocess/interprocess_fwd.hpp>

template<typename CharT, typename CharTraits = std::char_traits<CharT> > 
class basic_ibufferstream : public std::basic_istream< CharT, CharTraits > {
public:
  // construct/copy/destruct
  basic_ibufferstream(std::ios_base::openmode = std::ios_base::in);
  basic_ibufferstream(const CharT *, std::size_t, 
                      std::ios_base::openmode = std::ios_base::in);
  ~basic_ibufferstream();

  // public member functions
  basic_bufferbuf< CharT, CharTraits > * rdbuf() const;
  std::pair< const CharT *, std::size_t > buffer() const;
  void buffer(const CharT *, std::size_t);
};

Description

A basic_istream class that uses a fixed size character buffer as its formatting buffer.

basic_ibufferstream public construct/copy/destruct

  1. basic_ibufferstream(std::ios_base::openmode mode = std::ios_base::in);

    Constructor. Does not throw.

  2. basic_ibufferstream(const CharT * buf, std::size_t length, 
                        std::ios_base::openmode mode = std::ios_base::in);

    Constructor. Assigns formatting buffer. Does not throw.

  3. ~basic_ibufferstream();

basic_ibufferstream public member functions

  1. basic_bufferbuf< CharT, CharTraits > * rdbuf() const;

    Returns the address of the stored stream buffer.

  2. std::pair< const CharT *, std::size_t > buffer() const;

    Returns the pointer and size of the internal buffer. Does not throw.

  3. void buffer(const CharT * buf, std::size_t length);

    Sets the underlying buffer to a new value. Resets stream position. Does not throw.


PrevUpHomeNext