A library for working with phylogenetic and population genetic data.
v0.27.0
InputBuffer Class Reference

#include <genesis/utils/io/input_buffer.hpp>

Detailed Description

Definition at line 49 of file input_buffer.hpp.

Public Member Functions

 InputBuffer ()
 
 InputBuffer (self_type &&other)
 
 InputBuffer (self_type const &)=delete
 
 InputBuffer (std::shared_ptr< BaseInputSource > input_source)
 
 ~InputBuffer ()
 
 operator bool () const
 
self_typeoperator= (self_type &&other)
 
self_typeoperator= (self_type const &)=delete
 
char peek (size_t ahead=1)
 
size_t read (char *target, size_t size)
 

Public Types

using self_type = InputBuffer
 
using value_type = char
 

Static Public Attributes

static const size_t BlockLength = 1 << 22
 Block length for internal buffering. More...
 

Constructor & Destructor Documentation

◆ InputBuffer() [1/4]

InputBuffer ( )
inline

Definition at line 71 of file input_buffer.hpp.

◆ InputBuffer() [2/4]

InputBuffer ( std::shared_ptr< BaseInputSource input_source)
inlineexplicit

Definition at line 78 of file input_buffer.hpp.

◆ ~InputBuffer()

~InputBuffer ( )
inline

Definition at line 83 of file input_buffer.hpp.

◆ InputBuffer() [3/4]

InputBuffer ( self_type const &  )
delete

◆ InputBuffer() [4/4]

InputBuffer ( self_type &&  other)
inline

Definition at line 91 of file input_buffer.hpp.

Member Function Documentation

◆ operator bool()

operator bool ( ) const
inline

Definition at line 130 of file input_buffer.hpp.

◆ operator=() [1/2]

self_type& operator= ( self_type &&  other)
inline

Definition at line 99 of file input_buffer.hpp.

◆ operator=() [2/2]

self_type& operator= ( self_type const &  )
delete

◆ peek()

char peek ( size_t  ahead = 1)
inline

Definition at line 135 of file input_buffer.hpp.

◆ read()

size_t read ( char *  target,
size_t  size 
)
inline

Definition at line 165 of file input_buffer.hpp.

Member Typedef Documentation

◆ self_type

Definition at line 64 of file input_buffer.hpp.

◆ value_type

using value_type = char

Definition at line 65 of file input_buffer.hpp.

Member Data Documentation

◆ BlockLength

const size_t BlockLength = 1 << 22
static

Block length for internal buffering.

The buffer uses three blocks of this size (4MB each).

Definition at line 62 of file input_buffer.hpp.


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