Pixie16 Analysis Software Suite
Analysis code for processing of .ldf files
BarBuilder Class Reference

Class that builds bars out of a list of ends. More...

#include <BarBuilder.hpp>

Collaboration diagram for BarBuilder:

Public Member Functions

 BarBuilder ()
 
 BarBuilder (const std::vector< ChanEvent * > &vec)
 
virtual ~BarBuilder ()
 
BarMap GetBarMap (void)
 
void BuildBars (void)
 
void SetChannelList (const std::vector< ChanEvent * > &a)
 

Private Member Functions

unsigned int CalcBarNumber (const unsigned int &loc)
 
void ClearMaps (void)
 
void FillMaps (void)
 

Private Attributes

BarMap bars_
 Map containing all of the built bars.
 
TimingMap lefts_
 Map containing the left sides of bars.
 
TimingMap rights_
 Map containing the right sides of bars.
 
std::vector< ChanEvent * > list_
 Vector of events to build bars out of.
 

Detailed Description

Class that builds bars out of a list of ends.

Constructor & Destructor Documentation

BarBuilder::BarBuilder ( )
inline

Default constructor

BarBuilder::BarBuilder ( const std::vector< ChanEvent * > &  vec)

Constructor taking the map of channels to build bars with

Parameters
[in]vec: Reference to the vector to build channels with
virtual BarBuilder::~BarBuilder ( )
inlinevirtual

Default destructor

Member Function Documentation

void BarBuilder::BuildBars ( void  )

Builds the VANDLE bars from the individual channel maps

unsigned int BarBuilder::CalcBarNumber ( const unsigned int &  loc)
private

The bar number calculated from the location. We assume here that the bars are located in adjacent slots so that they are always paired in a {0,1} {2,3} {4,5} ... {n,n+1} manner. This is especially true if using a VANDLE firmware.

Parameters
[in]loc: the location of the current event
Returns
The calculated bar number
void BarBuilder::ClearMaps ( void  )
private

Clears out the data maps from any previously built bars and ends

void BarBuilder::FillMaps ( void  )
private

Fills the ends of the detector into two separate maps. Things labeled {left, up} are filled into one map, and things labeled {right, down} are filled into another map. Currently these are the only four recognized end types that one may have, this can be expanded later if others should arise.

BarMap BarBuilder::GetBarMap ( void  )
inline

Gets the built bar map. If you have used the default constructor you must call the BuildBars method first .

Returns
A BarMap of the bars built with the given event
void BarBuilder::SetChannelList ( const std::vector< ChanEvent * > &  a)
inline

Sets the channel list to build bars out of. This list must contain both ends of the detector.

Parameters
[in]a: The channel list to build bars out of.

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