| The Gaudi Framework v27r1

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

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | List of all members
StreamBuffer::DataIO Class Reference

A small base class to handle generic data streaming. More...

`#include <GaudiKernel/StreamBuffer.h>`

Inheritance diagram for StreamBuffer::DataIO:
[legend]

## Public Member Functions
| DataIO ()=default
| Standard constructor. More...
virtual | ~DataIO ()=default
| Standard destructor. More...
void | badStreamMode ()
| Throw Exception. More...
virtual void | serialize (StreamBuffer &stream)
| Serialization method: loads/dumps streambuffer content. More...
virtual void | load (StreamBuffer &)
| Template function to load stream data. More...
virtual void | dump (StreamBuffer &)
| Template function to save stream data. More...

## Detailed Description

A small base class to handle generic data streaming.

Definition at line 44 of file StreamBuffer.h.

## Constructor & Destructor Documentation

StreamBuffer::DataIO::DataIO | ( |  | ) |
| default

Standard constructor.

virtual StreamBuffer::DataIO::~DataIO | ( |  | ) |
| virtual default

Standard destructor.

## Member Function Documentation

void StreamBuffer::DataIO::badStreamMode | ( |  | ) |
| inline

Throw Exception.

Definition at line 51 of file StreamBuffer.h.

51 {
52 throw("Not acceptable stream mode!");
53 }

virtual void StreamBuffer::DataIO::dump | ( | StreamBuffer & |  | ) |
| inline virtual

Template function to save stream data.

Reimplemented in StreamBuffer::Ostream.

Definition at line 68 of file StreamBuffer.h.

68 {
69 badStreamMode();
70 }
StreamBuffer::DataIO::badStreamMode
void badStreamMode()
Throw Exception.
Definition: StreamBuffer.h:51

virtual void StreamBuffer::DataIO::load | ( | StreamBuffer & |  | ) |
| inline virtual

Template function to load stream data.

Reimplemented in StreamBuffer::Istream.

Definition at line 64 of file StreamBuffer.h.

64 {
65 badStreamMode();
66 }
StreamBuffer::DataIO::badStreamMode
void badStreamMode()
Throw Exception.
Definition: StreamBuffer.h:51

virtual void StreamBuffer::DataIO::serialize | ( | StreamBuffer & | stream | ) |
| inline virtual

Serialization method: loads/dumps streambuffer content.

Definition at line 55 of file StreamBuffer.h.

55 {
56 if (stream.isReading())
57 load(stream);
58 else if (stream.isWriting())
59 dump(stream);
60 else
61 badStreamMode();
62 }
StreamBuffer::DataIO::load
virtual void load(StreamBuffer &)
Template function to load stream data.
Definition: StreamBuffer.h:64
StreamBuffer::DataIO::dump
virtual void dump(StreamBuffer &)
Template function to save stream data.
Definition: StreamBuffer.h:68
StreamBuffer::isReading
bool isReading() const
Get stream buffer state.
Definition: StreamBuffer.h:280
StreamBuffer::DataIO::badStreamMode
void badStreamMode()
Throw Exception.
Definition: StreamBuffer.h:51
StreamBuffer::isWriting
bool isWriting() const
Get stream buffer state.
Definition: StreamBuffer.h:285

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

- GaudiKernel/GaudiKernel/StreamBuffer.h