6 #include "DD4hep/DetFactoryHelper.h" 17 double cellDx =
args.value<
double>(
"CellDx");
18 double cellDy =
args.value<
double>(
"CellDy");
19 double cellDz =
args.value<
double>(
"CellDz");
20 double startY =
args.value<
double>(
"StartY");
21 std::vector<std::string> childName =
args.value<std::vector<std::string> >(
"Child");
22 std::vector<int>
number =
args.value<std::vector<int> >(
"Number");
23 std::vector<int>
size =
args.value<std::vector<int> >(
"Size");
24 std::vector<int>
type =
args.value<std::vector<int> >(
"Type");
26 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalForwardAlgo: Cell material " << cellMat <<
"\tCell Size " 29 << childName[0] <<
", " << childName[1]
30 <<
"\n Cell positioning done for " <<
number.size() <<
" times";
31 for (
unsigned int i = 0;
i <
number.size(); ++
i)
33 <<
" first child index " <<
type[
i];
34 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalForwardAlgo debug: Parent " <<
args.parentName() <<
" NameSpace " << ns.
name();
42 for (
unsigned int i = 0;
i <
number.size();
i++) {
48 dd4hep::Solid solid = dd4hep::Box(ns.
prepend(
name),
dx, cellDy, cellDz);
50 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalForwardAlgo: " << solid.name() <<
" Box made of " << cellMat <<
" of Size " 58 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalForwardAlgo: " << solid.name() <<
" number " << box <<
" positioned in " 60 <<
", 0.0) with no rotation";
63 double xpos = -
dx + cellDx;
69 edm::LogVerbatim(
"HCalGeom") <<
"DDHCalForwardAlgo: " << childName[indx] <<
" number " << (
k + 1)
71 <<
", 0,0, 0.0) with no rotation";
78 edm::LogVerbatim(
"HCalGeom") <<
"<<== End of DDHCalForwardAlgo construction";
Log< level::Info, true > LogVerbatim
constexpr NumType convert2mm(NumType length)
std::string to_string(const V &value)
dd4hep::Material material(const std::string &name) const
#define DECLARE_DDCMS_DETELEMENT(name, func)
static constexpr long s_executed
std::string_view name() const
static long algorithm(dd4hep::Detector &, cms::DDParsingContext &ctxt, xml_h e)
std::pair< std::string, std::string > DDSplit(const std::string &n)
split into (name,namespace), separator = ':'
dd4hep::Volume volume(const std::string &name, bool exc=true) const
std::string prepend(const std::string &) const