14 using namespace genie;
33 std::string inter_str = interaction.
AsString();
34 RgKey key =
"XSecAlg@Interaction=" + inter_str;
36 std::map<std::string, const XSecAlgorithmI*>::const_iterator
39 std::map<std::string, const XSecAlgorithmI*>::const_iterator
43 if ( citer == cend ) {
48 if ( temp_reg.
Exists(key) ) {
74 else return citer->second;
82 if ( !alg_to_use )
return 0.;
100 if ( !alg_to_use )
return 0.;
101 else return alg_to_use->
Integral( interaction );
109 if ( !alg_to_use )
return false;
135 if ( temp_reg.
Exists(
"DefaultXSecAlg") ) {
137 this->
SubAlg(
"DefaultXSecAlg") );
Cross Section Calculation Interface.
double XSec(const Interaction *i, KinePhaseSpace_t k) const
Compute the cross section for the input interaction.
virtual ~HybridXSecAlgorithm()
enum genie::EKinePhaseSpace KinePhaseSpace_t
string AsString(void) const
virtual const Registry & GetConfig(void) const
Summary information for an interaction.
bool ValidProcess(const Interaction *i) const
Can this cross section algorithm handle the input process?
virtual void Configure(const Registry &config)
const XSecAlgorithmI * ChooseXSecAlg(const Interaction &interaction) const
void Configure(const Registry &config)
virtual bool ValidProcess(const Interaction *i) const =0
Can this cross section algorithm handle the input process?
virtual double XSec(const Interaction *i, KinePhaseSpace_t k=kPSfE) const =0
Compute the cross section for the input interaction.
A registry. Provides the container for algorithm configuration parameters.
std::map< string, const XSecAlgorithmI * > fXSecAlgMap
bool Exists(RgKey key) const
item with input key exists?
const XSecAlgorithmI * fDefaultXSecAlg
Optional XSecAlgorithmI to use by default.
void LoadConfig(void)
Load algorithm configuration.
double Integral(const Interaction *i) const
virtual double Integral(const Interaction *i) const =0
const UInt_t kISkipProcessChk
if set, skip process validity checks
const Algorithm * SubAlg(const RgKey ®istry_key) const