CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
DDAlgorithmHandler.cc
Go to the documentation of this file.
2 
3 #include <utility>
4 
9 
10 class DDCompactView;
11 
13  : algo_(0)
14 {
15 }
16 
18 {
19  if (algo_) {
20  delete algo_;
21  }
22 }
23 
24 void
26  const DDLogicalPart & parent,
27  const DDNumericArguments & nArgs,
28  const DDVectorArguments & vArgs,
29  const DDMapArguments & mArgs,
30  const DDStringArguments & sArgs,
31  const DDStringVectorArguments & svArgs )
32 {
33  std::pair<std::string,std::string> algoNmNs = DDSplit(algoName);
34  algoname_ = algoName;
36  algo_->setParent(parent);
37  algo_->initialize(nArgs,vArgs,mArgs,sArgs, svArgs);
38 }
39 
40 void
42 {
43  algo_->execute( cpv );
44 }
void execute(DDCompactView &)
executes the wrapped algorithm algo_; some pre- and post-processing (exception handling) ...
algo_(conf.existsAs< bool >("Correct")?conf.getParameter< bool >("Correct"):true, conf.getParameter< double >("e9e25Cut"), conf.getParameter< double >("intercept2DCut"), conf.existsAs< bool >("intercept2DSlope")?conf.getParameter< double >("intercept2DSlope"):defaultSlope2D_, conf.getParameter< std::vector< double > >("e1e9Cut"), conf.getParameter< std::vector< double > >("eCOREe9Cut"), conf.getParameter< std::vector< double > >("eSeLCut"), hfvars_)
DDAlgorithmHandler()
creates an DDAlgorithm wrapper
type of data representation of DDCompactView
Definition: DDCompactView.h:90
void initialize(const std::string &algoName, const DDLogicalPart &parent, const DDNumericArguments &nArgs, const DDVectorArguments &vArgs, const DDMapArguments &mArgs, const DDStringArguments &sArgs, const DDStringVectorArguments &svArgs)
initializes the wrapped algorithm algo_ and does some pre- and post-processing
std::string algoname_
name of the algorithm object
A DDLogicalPart aggregates information concerning material, solid and sensitveness ...
Definition: DDLogicalPart.h:92
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = &#39;:&#39;
Definition: DDSplit.cc:4
DDAlgorithm * algo_
the wrapped algorithm object
T get(const Candidate &c)
Definition: component.h:55