Scopira 20080306

scopira::tool::iflow_i Class Reference

#include <flow.h>

Inheritance diagram for scopira::tool::iflow_i:
scopira::tool::flow_i scopira::tool::object scopira::tool::bufferflow scopira::tool::bufferiflow scopira::tool::cacheiflow scopira::tool::commentiflow scopira::tool::fileflow scopira::tool::hexiflow scopira::tool::itflow_i scopira::tool::netflow scopira::tool::nullflow scopira::tool::stringflow scopira::tool::stringiflow scopira::tool::unixflow

List of all members.

Public Member Functions

virtual size_t read (byte_t *_buf, size_t _maxsize)=0
virtual size_t read_byte (byte_t &out)
template<class TT >
size_t read_array (TT *_buf, size_t _numelem)
size_t read_void (void *_buf, size_t _maxsize)

Detailed Description

A raw input stream of bytes

Author:
Aleksander Demko

Member Function Documentation

virtual size_t scopira::tool::iflow_i::read ( byte_t _buf,
size_t  _maxsize 
) [pure virtual]
template<class TT >
size_t scopira::tool::iflow_i::read_array ( TT *  _buf,
size_t  _numelem 
) [inline]

Nice wrapper around the raw read() method. Lets you read raw arrays of a particular type. POD types only. Returns the number of elelments actually read.

Author:
Aleksander Demko

References read().

Referenced by scopira::basekit::nslice< T, DIM >::load(), scopira::basekit::narray< T, DIM >::load(), and scopira::basekit::directio_slice< T, DIM >::load_slice().

virtual size_t scopira::tool::iflow_i::read_byte ( byte_t out) [inline, virtual]

Reads one byte

Parameters:
outwhere to write the byte
Returns:
1 if a byte was read, 0 if not
Author:
Aleksander Demko

Reimplemented in scopira::tool::cacheiflow, scopira::tool::hexiflow, and scopira::tool::commentiflow.

References read().

size_t scopira::tool::iflow_i::read_void ( void *  _buf,
size_t  _maxsize 
) [inline]

Reads a raw block of bytes, using a void*

Parameters:
_bufthe buffer to write out to
_maxsizethe maximume number of bytes to read into the buffer
Returns:
the number of bytes actually read
Author:
Aleksander Demko

References read().


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