retdec
Public Member Functions | Private Member Functions | Private Attributes | List of all members
retdec::fileformat::byte_array_buffer Class Reference

#include <byte_array_buffer.h>

Inheritance diagram for retdec::fileformat::byte_array_buffer:
Inheritance graph
[legend]
Collaboration diagram for retdec::fileformat::byte_array_buffer:
Collaboration graph
[legend]

Public Member Functions

 byte_array_buffer (const std::uint8_t *begin, const std::uint8_t *end)
 
 byte_array_buffer (const std::uint8_t *data, const std::size_t size)
 

Private Member Functions

int_type underflow ()
 
int_type uflow ()
 
int_type pbackfail (int_type ch)
 
std::streamsize showmanyc ()
 
std::streampos seekoff (std::streamoff off, std::ios_base::seekdir way, std::ios_base::openmode which=std::ios_base::in|std::ios_base::out)
 
std::streampos seekpos (std::streampos sp, std::ios_base::openmode which=std::ios_base::in|std::ios_base::out)
 
 byte_array_buffer (const byte_array_buffer &)
 
byte_array_bufferoperator= (const byte_array_buffer &)
 

Private Attributes

const std::uint8_t *const begin_ = nullptr
 
const std::uint8_t *const end_ = nullptr
 
const std::uint8_t * current_ = nullptr
 

Detailed Description

Example 2 from: "A beginner's guide to writing a custom stream buffer (std::streambuf)" Links: http://www.voidcn.com/article/p-vjnlygmc-gy.html https://stackoverflow.com/a/31597630

Constructor & Destructor Documentation

◆ byte_array_buffer() [1/3]

retdec::fileformat::byte_array_buffer::byte_array_buffer ( const std::uint8_t *  begin,
const std::uint8_t *  end 
)

◆ byte_array_buffer() [2/3]

retdec::fileformat::byte_array_buffer::byte_array_buffer ( const std::uint8_t *  data,
const std::size_t  size 
)

◆ byte_array_buffer() [3/3]

retdec::fileformat::byte_array_buffer::byte_array_buffer ( const byte_array_buffer )
private

Member Function Documentation

◆ operator=()

byte_array_buffer& retdec::fileformat::byte_array_buffer::operator= ( const byte_array_buffer )
private

◆ pbackfail()

byte_array_buffer::int_type retdec::fileformat::byte_array_buffer::pbackfail ( int_type  ch)
private

◆ seekoff()

std::streampos retdec::fileformat::byte_array_buffer::seekoff ( std::streamoff  off,
std::ios_base::seekdir  way,
std::ios_base::openmode  which = std::ios_base::in | std::ios_base::out 
)
private

◆ seekpos()

std::streampos retdec::fileformat::byte_array_buffer::seekpos ( std::streampos  sp,
std::ios_base::openmode  which = std::ios_base::in | std::ios_base::out 
)
private

◆ showmanyc()

std::streamsize retdec::fileformat::byte_array_buffer::showmanyc ( )
private

◆ uflow()

byte_array_buffer::int_type retdec::fileformat::byte_array_buffer::uflow ( )
private

◆ underflow()

byte_array_buffer::int_type retdec::fileformat::byte_array_buffer::underflow ( )
private

Member Data Documentation

◆ begin_

const std::uint8_t* const retdec::fileformat::byte_array_buffer::begin_ = nullptr
private

◆ current_

const std::uint8_t* retdec::fileformat::byte_array_buffer::current_ = nullptr
private

◆ end_

const std::uint8_t* const retdec::fileformat::byte_array_buffer::end_ = nullptr
private

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