| # Gaudi Framework, version v20r2
Generated: 18 Jul 2008

- Main Page
- Namespaces
- Classes
- Files
- Directories
- Related Pages

- Search for |

- Alphabetical List
- Class List
- Class Hierarchy
- Class Members

# StreamBuffer::Istream Class Reference

`#include <StreamBuffer.h>`

Inheritance diagram for StreamBuffer::Istream:

[legend]
Collaboration diagram for StreamBuffer::Istream:

[legend]
List of all members.

## Detailed Description

Reader for standard input streams.

Definition at line 71 of file StreamBuffer.h.

## Public Member Functions
| Istream (std::istream &str)
| Constructor.
virtual | ~Istream ()
| Destructor.
virtual void | load (StreamBuffer &stream)
| Data load method.
## Private Attributes
std::istream * | m_stream
| Reference to input stream.

## Constructor & Destructor Documentation

StreamBuffer::Istream::Istream | ( | std::istream & | str | ) | `[inline]`

Constructor.

Definition at line 76 of file StreamBuffer.h.

    00076                              : m_stream(&str)   {
    00077     }

virtual StreamBuffer::Istream::~Istream | ( |  | ) | `[inline, virtual]`

Destructor.

Definition at line 79 of file StreamBuffer.h.

    00079                         {
    00080     }

## Member Function Documentation

virtual void StreamBuffer::Istream::load | ( | StreamBuffer & | stream | ) | `[inline, virtual]`

Data load method.

Reimplemented from StreamBuffer::DataIO.

Definition at line 82 of file StreamBuffer.h.

References StreamBuffer::data(), StreamBuffer::erase(), m_stream, std::basic_istream< _CharT, _Traits >::read(), and StreamBuffer::reserve().

    00082                                               {
    00083       // Generic implementation for istreams:
    00084       int  len;
    00085       (*m_stream) >> len;
    00086       stream.erase();
    00087       stream.reserve(len);
    00088       m_stream->read(stream.data(),len);
    00089     }

## Member Data Documentation

std::istream* StreamBuffer::Istream::m_stream`[private]`

Reference to input stream.

Definition at line 73 of file StreamBuffer.h.

Referenced by load().

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

- /afs/cern.ch/sw/Gaudi/releases/GAUDI/GAUDI_v20r2/GaudiKernel/v25r2/GaudiKernel/StreamBuffer.h