File indexing completed on 2025-12-16 10:13:05
0001
0002
0003
0004 #pragma once
0005
0006 #include <algorithms/algorithm.h>
0007 #include <edm4eic/HadronicFinalStateCollection.h>
0008 #include <edm4eic/MCRecoParticleAssociationCollection.h>
0009 #include <edm4eic/ReconstructedParticleCollection.h>
0010 #include <edm4hep/MCParticleCollection.h>
0011 #include <string>
0012 #include <string_view>
0013
0014 #include "algorithms/interfaces/WithPodConfig.h"
0015 #include "services/particle/ParticleSvc.h"
0016
0017 namespace eicrecon {
0018
0019 using HadronicFinalStateAlgorithm = algorithms::Algorithm<
0020 algorithms::Input<edm4hep::MCParticleCollection, edm4eic::ReconstructedParticleCollection,
0021 edm4eic::MCRecoParticleAssociationCollection>,
0022 algorithms::Output<edm4eic::HadronicFinalStateCollection>>;
0023
0024 class HadronicFinalState : public HadronicFinalStateAlgorithm, public WithPodConfig<NoConfig> {
0025
0026 public:
0027 HadronicFinalState(std::string_view name)
0028 : HadronicFinalStateAlgorithm{name,
0029 {"MCParticles", "inputParticles", "inputAssociations"},
0030 {"hadronicFinalState"},
0031 "Calculate summed quantities of the hadronic final state."} {}
0032
0033 void init() final;
0034 void process(const Input&, const Output&) const final;
0035
0036 private:
0037 const algorithms::ParticleSvc& m_particleSvc = algorithms::ParticleSvc::instance();
0038 double m_crossingAngle{-0.025};
0039 };
0040
0041 }