McStas Readout Master 0.3.3
Loading...
Searching...
No Matches
Reader Class Reference

Typed accessor for one collector group inside a validated collector file. More...

#include <reader.h>

Public Member Functions

RL_API Reader (std::shared_ptr< HighFive::File > file, const std::string &collector_name)
 
RL_API const std::string & collector_name () const
 
RL_API DetectorType detector_type () const
 The detector named by the group's attribute, or Reserved for user-described groups.
 
RL_API ReadoutType readout_type () const
 The readout type implied by the stored compound datatype.
 
RL_API std::optional< ReadoutType > sendable_readout_type () const
 The registry readout type whose compound datatype exactly matches the stored records, or nullopt when the group stores user-described records that no EFU accepts.
 
RL_API const std::optional< std::string > & type_description () const
 The original type-description string for user-described groups, if recorded.
 
RL_API size_t size () const
 
RL_API size_t points () const
 
RL_API HighFive::DataType datatype () const
 
RL_API size_t record_size () const
 
RL_API double point_weight (const size_t point) const
 The accumulated rate-weight of one point, in stored (ncount-scaled) units: divide by point_normalization() to recover the physical rate.
 
RL_API uint64_t point_normalization (const size_t point) const
 The accumulated simulated-ray count of one point; grows when files are appended, so stored-weight / normalization stays the physical rate contribution of a record.
 
RL_API std::vector< uint8_t > get_raw (const size_t index, const size_t count) const
 Raw access to stored records for user-described groups: count records starting at index, each record_size() bytes in the stored layout.
 
RL_API std::optional< std::string > efu_address () const
 Returns the EFU IP address embedded in the file, if any.
 
RL_API std::optional< uint16_t > efu_port () const
 Returns the EFU UDP port embedded in the file, if any.
 
RL_API size_t point_offset (const size_t point) const
 
RL_API size_t point_size (const size_t point) const
 
RL_API auto get_CAEN (const size_t index, const size_t count) const
 
RL_API auto get_TTLMonitor (const size_t index, const size_t count) const
 
RL_API auto get_VMM3 (const size_t index, const size_t count) const
 
RL_API auto get_CDT (const size_t index, const size_t count) const
 
RL_API auto get_BM0 (const size_t index, const size_t count) const
 
RL_API auto get_BM2 (const size_t index, const size_t count) const
 
RL_API auto get_BMI (const size_t index, const size_t count) const
 
RL_API auto get_point_CAEN (const size_t point) const
 
RL_API auto get_point_TTLMonitor (const size_t point) const
 
RL_API auto get_point_VMM3 (const size_t point) const
 
RL_API auto get_point_CDT (const size_t point) const
 
RL_API auto get_point_BM0 (const size_t point) const
 
RL_API auto get_point_BM2 (const size_t point) const
 
RL_API auto get_point_BMI (const size_t point) const
 

Detailed Description

Typed accessor for one collector group inside a validated collector file.

Reader exposes point-aware access to stored records (readouts) and cue-based slicing through the cues dataset. EFU sendability is inferred from exact HDF5 compound datatype comparison against the canonical readout registry.

Definition at line 50 of file reader.h.

Constructor & Destructor Documentation

◆ Reader()

RL_API Reader::Reader ( std::shared_ptr< HighFive::File >  file,
const std::string &  collector_name 
)
inlineexplicit

Definition at line 76 of file reader.h.

Member Function Documentation

◆ collector_name()

RL_API const std::string & Reader::collector_name ( ) const
inline

Definition at line 146 of file reader.h.

◆ datatype()

RL_API HighFive::DataType Reader::datatype ( ) const
inline

Definition at line 161 of file reader.h.

◆ detector_type()

RL_API DetectorType Reader::detector_type ( ) const
inline

The detector named by the group's attribute, or Reserved for user-described groups.

Definition at line 148 of file reader.h.

◆ efu_address()

RL_API std::optional< std::string > Reader::efu_address ( ) const
inline

Returns the EFU IP address embedded in the file, if any.

Definition at line 193 of file reader.h.

◆ efu_port()

RL_API std::optional< uint16_t > Reader::efu_port ( ) const
inline

Returns the EFU UDP port embedded in the file, if any.

Definition at line 195 of file reader.h.

◆ get_BM0()

RL_API auto Reader::get_BM0 ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 237 of file reader.h.

◆ get_BM2()

RL_API auto Reader::get_BM2 ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 245 of file reader.h.

◆ get_BMI()

RL_API auto Reader::get_BMI ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 253 of file reader.h.

◆ get_CAEN()

RL_API auto Reader::get_CAEN ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 205 of file reader.h.

◆ get_CDT()

RL_API auto Reader::get_CDT ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 229 of file reader.h.

◆ get_point_BM0()

RL_API auto Reader::get_point_BM0 ( const size_t  point) const
inline

Definition at line 278 of file reader.h.

◆ get_point_BM2()

RL_API auto Reader::get_point_BM2 ( const size_t  point) const
inline

Definition at line 282 of file reader.h.

◆ get_point_BMI()

RL_API auto Reader::get_point_BMI ( const size_t  point) const
inline

Definition at line 286 of file reader.h.

◆ get_point_CAEN()

RL_API auto Reader::get_point_CAEN ( const size_t  point) const
inline

Definition at line 262 of file reader.h.

◆ get_point_CDT()

RL_API auto Reader::get_point_CDT ( const size_t  point) const
inline

Definition at line 274 of file reader.h.

◆ get_point_TTLMonitor()

RL_API auto Reader::get_point_TTLMonitor ( const size_t  point) const
inline

Definition at line 266 of file reader.h.

◆ get_point_VMM3()

RL_API auto Reader::get_point_VMM3 ( const size_t  point) const
inline

Definition at line 270 of file reader.h.

◆ get_raw()

RL_API std::vector< uint8_t > Reader::get_raw ( const size_t  index,
const size_t  count 
) const
inline

Raw access to stored records for user-described groups: count records starting at index, each record_size() bytes in the stored layout.

Definition at line 184 of file reader.h.

◆ get_TTLMonitor()

RL_API auto Reader::get_TTLMonitor ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 213 of file reader.h.

◆ get_VMM3()

RL_API auto Reader::get_VMM3 ( const size_t  index,
const size_t  count 
) const
inline

Definition at line 221 of file reader.h.

◆ point_normalization()

RL_API uint64_t Reader::point_normalization ( const size_t  point) const
inline

The accumulated simulated-ray count of one point; grows when files are appended, so stored-weight / normalization stays the physical rate contribution of a record.

Definition at line 175 of file reader.h.

◆ point_offset()

RL_API size_t Reader::point_offset ( const size_t  point) const
inline

Definition at line 197 of file reader.h.

◆ point_size()

RL_API size_t Reader::point_size ( const size_t  point) const
inline

Definition at line 200 of file reader.h.

◆ point_weight()

RL_API double Reader::point_weight ( const size_t  point) const
inline

The accumulated rate-weight of one point, in stored (ncount-scaled) units: divide by point_normalization() to recover the physical rate.

Definition at line 166 of file reader.h.

◆ points()

RL_API size_t Reader::points ( ) const
inline

Definition at line 160 of file reader.h.

◆ readout_type()

RL_API ReadoutType Reader::readout_type ( ) const
inline

The readout type implied by the stored compound datatype.

Definition at line 150 of file reader.h.

◆ record_size()

RL_API size_t Reader::record_size ( ) const
inline

Definition at line 162 of file reader.h.

◆ sendable_readout_type()

RL_API std::optional< ReadoutType > Reader::sendable_readout_type ( ) const
inline

The registry readout type whose compound datatype exactly matches the stored records, or nullopt when the group stores user-described records that no EFU accepts.

Definition at line 156 of file reader.h.

◆ size()

RL_API size_t Reader::size ( ) const
inline

Definition at line 159 of file reader.h.

◆ type_description()

RL_API const std::optional< std::string > & Reader::type_description ( ) const
inline

The original type-description string for user-described groups, if recorded.

Definition at line 158 of file reader.h.


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