#include <DetectorDescription/Core/interface/DDAlgo.h>
Public Member Functions | |
int | copyno () const |
DDAlgo (const DDName &name) | |
DDAlgo () | |
int | end () const |
bool | go () const |
int | incr () const |
std::string | label () const |
void | next () |
const parE_type & | parE () const |
const parS_type & | parS () const |
DDRotationMatrix | rotation () |
void | setParameters (int start, int end, int incr, const parS_type &, const parE_type &) |
int | start () const |
DDTranslation | translation () |
Static Public Member Functions | |
static void | clear () |
Private Member Functions | |
DDAlgo (const DDName &, AlgoPos *) | |
Friends | |
DDAlgo | DDalgo (const DDName &, AlgoPos *) |
std::ostream & | operator<< (std::ostream &, const DDAlgo &) |
Definition at line 21 of file DDAlgo.h.
DDAlgo::DDAlgo | ( | ) |
Definition at line 27 of file DDAlgo.cc.
Referenced by DDalgo().
00027 : DDBase<DDName,AlgoPos*>() 00028 { }
DDAlgo::DDAlgo | ( | const DDName & | name | ) |
Definition at line 31 of file DDAlgo.cc.
References DDI::Singleton< I >::instance(), and DDBase< DDName, AlgoPos * >::prep_.
00031 : DDBase<DDName,AlgoPos*>() 00032 { 00033 prep_ = StoreT::instance().create(name); 00034 }
Definition at line 37 of file DDAlgo.cc.
References DDI::Singleton< I >::instance(), and DDBase< DDName, AlgoPos * >::prep_.
00037 : DDBase<DDName,AlgoPos*>() 00038 00039 { 00040 prep_ = StoreT::instance().create(name,a); 00041 }
Reimplemented from DDBase< DDName, AlgoPos * >.
Definition at line 123 of file DDAlgo.cc.
References DDI::Singleton< I >::instance().
00124 { 00125 StoreT::instance().clear(); 00126 }
int DDAlgo::copyno | ( | ) | const |
copy-number calculation
Definition at line 90 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by label().
00091 { 00092 return rep().copyno(); 00093 }
int DDAlgo::end | ( | ) | const |
the 'end' parameter
Definition at line 57 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
00058 { 00059 return rep().end(); 00060 }
bool DDAlgo::go | ( | ) | const |
continue calling the algorithm unless go() returns false
Definition at line 111 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by DDalgoPosPart().
00112 { 00113 return rep().go(); 00114 }
int DDAlgo::incr | ( | ) | const |
the 'incr' parameter
Definition at line 62 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
00063 { 00064 return rep().incr(); 00065 }
std::string DDAlgo::label | ( | ) | const |
copy-number delivered as std::string
Definition at line 97 of file DDAlgo.cc.
References copyno().
Referenced by DDalgoPosPart().
00098 { 00099 char buffer [50]; 00100 /*int n =*/ sprintf(buffer,"%d",copyno()); 00101 return std::string(buffer); 00102 }
void DDAlgo::next | ( | ) |
prepare the algorithm for its next iteration or set its state to 'terminate' in case all iterations have already been done
Definition at line 105 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by DDalgoPosPart().
00106 { 00107 rep().next(); 00108 }
const parE_type & DDAlgo::parE | ( | ) | const |
double valued user parameter, values already evaluated from expressions
Definition at line 72 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
00073 { 00074 return rep().parE(); 00075 }
const parS_type & DDAlgo::parS | ( | ) | const |
std::string valued user parameter
Definition at line 67 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
00068 { 00069 return rep().parS(); 00070 }
DDRotationMatrix DDAlgo::rotation | ( | void | ) |
rotation calculations
Definition at line 84 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by DDalgoPosPart().
00085 { 00086 return rep().rotation(); 00087 }
void DDAlgo::setParameters | ( | int | start, | |
int | end, | |||
int | incr, | |||
const parS_type & | ps, | |||
const parE_type & | pe | |||
) |
sets user defined parameters
Definition at line 45 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by DDLAlgoPosPart::processElement().
int DDAlgo::start | ( | ) | const |
the 'start' parameter
Definition at line 52 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
00053 { 00054 return rep().start(); 00055 }
DDTranslation DDAlgo::translation | ( | void | ) |
translation calculations
Definition at line 78 of file DDAlgo.cc.
References DDBase< DDName, AlgoPos * >::rep().
Referenced by DDalgoPosPart().
00079 { 00080 return rep().translation(); 00081 }
std::ostream& operator<< | ( | std::ostream & | os, | |
const DDAlgo & | algo | |||
) | [friend] |
Definition at line 7 of file DDAlgo.cc.
00008 { 00009 DDBase<DDName,AlgoPos*>::def_type defined(algo.isDefined()); 00010 if (defined.first) { 00011 os << *(defined.first) << " "; 00012 if (defined.second) { 00013 algo.rep().stream(os); 00014 } 00015 else { 00016 os << "* algorithm not defined * "; 00017 } 00018 } 00019 else { 00020 os << "* algorithm not declared * "; 00021 } 00022 return os; 00023 00024 }