10#include <arich/modules/arichRelate/ARICHRelateModule.h>
13#include <framework/datastore/DataStore.h>
16#include <framework/gearbox/Const.h>
17#include <framework/logging/Logger.h>
19#include <mdst/dataobjects/Track.h>
20#include <tracking/dataobjects/ExtHit.h>
21#include <mdst/dataobjects/MCParticle.h>
22#include <arich/dataobjects/ARICHAeroHit.h>
43 setDescription(
"Creates relations between ARICHAeroHits and ExtHits. Allows to store simulation output without MCParticles");
63 B2DEBUG(50,
"No. of hits " << nHits);
68 B2DEBUG(50,
"No MCParticle for AeroHit!");
77 if (!fitResult)
continue;
81 for (
const ExtHit& extHit : extHits) {
82 if (abs(extHit.getPdgCode()) !=
Const::pion.getPDGCode() or
83 extHit.getDetectorID() != arich or
84 extHit.getCopyID() != 6789 or
85 extHit.getStatus() != EXT_EXIT)
continue;
86 extHit.addRelationTo(&aeroHit);
Datastore class that holds information on track parameters at the entrance in aerogel.
StoreArray< ARICHAeroHit > m_aeroHits
Required array of input ARICHAeroHits.
StoreArray< Track > m_mdstTracks
Required array of input Tracks.
StoreArray< ExtHit > m_extHits
Required array of input ExtHits.
StoreArray< MCParticle > m_mcParticles
Required array of input MCParticles.
EDetector
Enum for identifying the detector components (detector and subdetector).
static const ChargedStable pion
charged pion particle
static T * getRelated(const TObject *object, const std::string &name="", const std::string &namedRelation="")
Get the object to or from which another object has a relation.
static RelationVector< T > getRelationsWithObj(const TObject *object, const std::string &name="", const std::string &namedRelation="")
Get the relations between an object and other objects in a store array.
Store one Ext hit as a ROOT object.
A Class to store the Monte Carlo particle information.
void setDescription(const std::string &description)
Sets the description of the module.
void setPropertyFlags(unsigned int propertyFlags)
Sets the flags for the module properties.
@ c_ParallelProcessingCertified
This module can be run in parallel processing mode safely (All I/O must be done through the data stor...
Class for type safe access to objects that are referred to in relations.
Values of the result of a track fit with a given particle hypothesis.
Class that bundles various TrackFitResults.
virtual void initialize() override
Initialize the Module.
virtual void event() override
Event processor.
ARICHRelateModule()
Constructor.
#define REG_MODULE(moduleName)
Register the given module (without 'Module' suffix) with the framework.
Abstract base class for different kinds of events.