cepgen is hosted by Hepforge, IPPP Durham
CepGen 1.2.5
Central exclusive processes event generator
Loading...
Searching...
No Matches
Handler.cpp
Go to the documentation of this file.
1/*
2 * CepGen: a central exclusive processes event generator
3 * Copyright (C) 2013-2024 Laurent Forthomme
4 *
5 * This program is free software: you can redistribute it and/or modify
6 * it under the terms of the GNU General Public License as published by
7 * the Free Software Foundation, either version 3 of the License, or
8 * any later version.
9 *
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
14 *
15 * You should have received a copy of the GNU General Public License
16 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 */
18
22
23namespace cepgen {
24 namespace card {
26 : NamedModule(params), filename_(steer<std::string>("filename")), rt_params_(new RunParameters) {
27 if (!filename_.empty())
29 }
30
32 rt_params_.reset(const_cast<RunParameters*>(params));
33 return *this;
34 }
35
37 auto desc = ParametersDescription();
38 desc.setDescription("Generic steering cards handler");
39 desc.add<std::string>("filename", "").setDescription("Steering card to parse");
40 return desc;
41 }
42 } // namespace card
43} // namespace cepgen
Base runtime module object.
Definition NamedModule.h:28
A description object for parameters collection.
List of parameters used to start and run the simulation job.
Base steering card module.
Definition Handler.h:31
virtual Handler & setRunParameters(const RunParameters *)
Specify runtime parameters.
Definition Handler.cpp:31
const std::string filename_
Input filename.
Definition Handler.h:49
virtual Handler & parseFile(const std::string &)
Read configuration from steering card.
Definition Handler.h:41
static ParametersDescription description()
Definition Handler.cpp:36
Handler(const ParametersList &)
Build a configuration from an external steering card.
Definition Handler.cpp:25
Common namespace for this Monte Carlo generator.