SctData::IO::RawScanResultStreamer_v3 Class Reference

This class is an ISSerializer for reading/writing RawScanResults to/from IS. More...

#include <RawScanResultStreamer_v3.h>

Inheritance diagram for SctData::IO::RawScanResultStreamer_v3:

Inheritance graph
[legend]
Collaboration diagram for SctData::IO::RawScanResultStreamer_v3:

Collaboration graph
[legend]

Public Member Functions

virtual void write (OStream &out, const Streamable &ob, const IOManager &manager) const
 Publishes ob to out.
virtual shared_ptr< Streamableread (IStream &in, const IOManager &manager) const
 Create a new Streamable object of the appropriate type from IS.
virtual void read (IStream &in, Streamable &ob, const IOManager &manager) const
 Refreshes ob from in.
virtual unsigned getVersion () const throw ()

Private Member Functions

void readData (IStream &in, RawScanResult &raw) const
 Based on the data type, passes control onto the appropriate function for reading out the data.
void readSliceData (unsigned int size, unsigned short width, IStream &in, RawScanResult &raw) const
 Reads in data in Slice format from IS.
void readRootData (unsigned int size, unsigned short width, IStream &in, RawScanResult &raw) const
 Reads in data in ROOT format from IS.
void readRawData (unsigned int size, unsigned short width, IStream &in, RawScanResult &raw) const
 Reads in data in Raw format from IS.
void setHistSize (RawScanResult &raw, unsigned nbinsx, short unsigned ilink) const
 RawScanResultStreamer_v3 () throw ()
 Constructor is private.

Static Private Member Functions

static void createOccupancyHistogram (const RawScanResultIOHelper &helper, const RawScanResult &raw, unsigned ichip)
 creates an occupancy histogram with correct name etc for module in the right place on the RawData
static unsigned getOccWordPosition (unsigned ichip, unsigned ibin, unsigned ipt)
 position of occupancy histogram data for slice format...

Private Attributes

RawScanResultIOHelper helper
 The IOHelper.

Static Private Attributes

static unsigned s_version
static bool inMap
 The static dummy variable for the IOManager map.

Detailed Description

This class is an ISSerializer for reading/writing RawScanResults to/from IS.

Definition at line 19 of file RawScanResultStreamer_v3.h.


Constructor & Destructor Documentation

SctData::IO::RawScanResultStreamer_v3::RawScanResultStreamer_v3  )  throw () [private]
 

Constructor is private.

Definition at line 27 of file RawScanResultStreamer_v3.cpp.


Member Function Documentation

void SctData::IO::RawScanResultStreamer_v3::createOccupancyHistogram const RawScanResultIOHelper helper,
const RawScanResult raw,
unsigned  ichip
[static, private]
 

creates an occupancy histogram with correct name etc for module in the right place on the RawData

Definition at line 335 of file RawScanResultStreamer_v3.cpp.

References SctData::ScanResult::getHeader(), and SctData::ResultHeader::getModuleName().

Here is the call graph for this function:

unsigned SctData::IO::RawScanResultStreamer_v3::getOccWordPosition unsigned  ichip,
unsigned  ibin,
unsigned  ipt
[static, private]
 

position of occupancy histogram data for slice format...

Definition at line 375 of file RawScanResultStreamer_v3.cpp.

void SctData::IO::RawScanResultStreamer_v3::read IStream in,
Streamable ob,
const IOManager manager
const [virtual]
 

Refreshes ob from in.

Parameters:
in The IStream
ob The Streamable object to be refreshed.
manager the IOManager to use
Exceptions:
IoException if something bad happens

Implements Sct::Streamer.

Definition at line 68 of file RawScanResultStreamer_v3.cpp.

References helper, SctData::ob, readData(), Sct::IOManager::readImpl(), and SctData::RawScanResultIOHelper::set().

Here is the call graph for this function:

shared_ptr< Streamable > SctData::IO::RawScanResultStreamer_v3::read IStream in,
const IOManager manager
const [virtual]
 

Create a new Streamable object of the appropriate type from IS.

Parameters:
in The IStream.
manager the IOManager to use
Returns:
a new Streamable object
Exceptions:
IoException if something bad happens

Implements Sct::Streamer.

Definition at line 31 of file RawScanResultStreamer_v3.cpp.

References SctData::RawScanResultIOHelper::create(), and helper.

Here is the call graph for this function:

void SctData::IO::RawScanResultStreamer_v3::readData IStream in,
RawScanResult raw
const [private]
 

Based on the data type, passes control onto the appropriate function for reading out the data.

AJB 02/05/2003

Definition at line 102 of file RawScanResultStreamer_v3.cpp.

References helper, readRawData(), readRootData(), readSliceData(), and SctData::RawScanResultIOHelper::setDataType().

Referenced by read().

Here is the call graph for this function:

void SctData::IO::RawScanResultStreamer_v3::readRawData unsigned int  size,
unsigned short  width,
IStream in,
RawScanResult raw
const [private]
 

Reads in data in Raw format from IS.

Definition at line 181 of file RawScanResultStreamer_v3.cpp.

References SctData::ScanPoints::getNPoints(), SctData::ScanResult::getPoints(), and setHistSize().

Referenced by readData().

Here is the call graph for this function:

void SctData::IO::RawScanResultStreamer_v3::readRootData unsigned int  size,
unsigned short  width,
IStream in,
RawScanResult raw
const [private]
 

Reads in data in ROOT format from IS.

I.e. same data format as is published by this.

Definition at line 126 of file RawScanResultStreamer_v3.cpp.

References Sct::IStream::get(), SctData::ScanPoints::getNPoints(), SctData::ScanResult::getPoints(), SctData::RawScanResultIOHelper::getScanData(), helper, SctData::RawScanResultIOHelper::setDataType(), and setHistSize().

Referenced by readData().

Here is the call graph for this function:

void SctData::IO::RawScanResultStreamer_v3::readSliceData unsigned int  size,
unsigned short  width,
IStream in,
RawScanResult raw
const [private]
 

Reads in data in Slice format from IS.

Definition at line 242 of file RawScanResultStreamer_v3.cpp.

References SctData::ScanPoints::ascending(), Sct::IStream::get(), SctData::ScanPoints::getNPoints(), SctData::ScanResult::getPoints(), SctData::RawScanResultIOHelper::getScanData(), helper, Sct::nChannelLink, and setHistSize().

Referenced by readData().

Here is the call graph for this function:

void SctData::IO::RawScanResultStreamer_v3::write OStream out,
const Streamable ob,
const IOManager manager
const [virtual]
 

Publishes ob to out.

Parameters:
out The OStream.
ob The Streamable object to stream.
manager the IOManager to use
Exceptions:
IoException if something bad happens

Implements Sct::Streamer.

Definition at line 37 of file RawScanResultStreamer_v3.cpp.

References SctData::RawScanResult::getDataType(), SctData::RawScanResultIOHelper::getOccupancyPerEvent(), SctData::RawScanResultIOHelper::getScanData(), helper, SctData::RawScanResult::nOccupancyPerEvent(), SctData::ob, Sct::OStream::put(), SctData::RawScanResultIOHelper::set(), and Sct::IOManager::writeImpl().

Here is the call graph for this function:


Field Documentation

RawScanResultIOHelper SctData::IO::RawScanResultStreamer_v3::helper [mutable, private]
 

The IOHelper.

Definition at line 60 of file RawScanResultStreamer_v3.h.

Referenced by read(), readData(), readRootData(), readSliceData(), setHistSize(), and write().

bool SctData::IO::RawScanResultStreamer_v3::inMap [static, private]
 

The static dummy variable for the IOManager map.

Definition at line 63 of file RawScanResultStreamer_v3.h.


The documentation for this class was generated from the following files:
Generated on Mon Feb 6 14:08:41 2006 for SCT DAQ/DCS Software - C++ by  doxygen 1.4.6