NSCL DDAS 12.2-009
Support for XIA DDAS at FRIB
Public Member Functions | List of all members
StreamDataSource Class Reference

A class taking the input stream as a data source. Most commonly used to construct a data source from an NSCLDAQ event file on disk. More...

#include <StreamDataSource.h>

Inheritance diagram for StreamDataSource:
Inheritance graph
[legend]
Collaboration diagram for StreamDataSource:
Collaboration graph
[legend]

Public Member Functions

 StreamDataSource (ufmt::RingItemFactoryBase *pFactory, std::istream &str)
 Constructor. More...
 
virtual ~StreamDataSource ()
 Destructor. More...
 
virtual ufmt::CRingItem * getItem ()
 Get a ring item from the soruce. Implementation of the mandatory interface from the base class. More...
 
- Public Member Functions inherited from DataSource
 DataSource (ufmt::RingItemFactoryBase *pFactory)
 Constructor. More...
 
virtual ~DataSource ()=default
 Destructor. More...
 
virtual ufmt::CRingItem * getItem ()=0
 Pure-virtual method to access a ring item from the data source. Must be implemented in derived classes. More...
 
void setFactory (ufmt::RingItemFactoryBase *pFactory)
 Set a new factory. More...
 

Additional Inherited Members

- Protected Attributes inherited from DataSource
ufmt::RingItemFactoryBase * m_pFactory
 Ptr to our ring item factory. More...
 

Detailed Description

A class taking the input stream as a data source. Most commonly used to construct a data source from an NSCLDAQ event file on disk.

Constructor & Destructor Documentation

◆ StreamDataSource()

StreamDataSource::StreamDataSource ( ufmt::RingItemFactoryBase *  pFactory,
std::istream &  str 
)

Constructor.

Parameters
pFactoryPointer to the ring item factory.
strReferences the stream from which to get ring items.

◆ ~StreamDataSource()

StreamDataSource::~StreamDataSource ( )
virtual

Destructor.

Member Function Documentation

◆ getItem()

CRingItem * StreamDataSource::getItem ( )
virtual

Get a ring item from the soruce. Implementation of the mandatory interface from the base class.

Returns
Pointer to the next ring item from the stream.
Return values
nullptrIf none.

Implements DataSource.


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