3#include "Framework/Exception/Exception.h"
4#include "G4LogicalVolume.hh"
5#include "G4LogicalVolumeStore.hh"
11namespace volumechecks {
25inline bool isInEcal(G4LogicalVolume* vol,
const std::string& vol_to_bias) {
26 const G4String& volume_name = vol->GetName();
27 return ((volume_name.contains(
"Si") || volume_name.contains(
"W") ||
28 volume_name.contains(
"PCB") || volume_name.contains(
"strongback") ||
29 volume_name.contains(
"Glue") || volume_name.contains(
"CFMix") ||
30 volume_name.contains(
"Al") || volume_name.contains(
"C")) &&
31 volume_name.contains(
"volume")) ||
32 (volume_name.contains(
"nohole_motherboard"));
43inline bool isInHcal(G4LogicalVolume* vol,
const std::string& vol_to_bias) {
44 const G4String& volume_name = vol->GetName();
45 return ((volume_name.contains(
"abso") || volume_name.contains(
"ScintBox") ||
46 volume_name.contains(
"scint")) &&
47 volume_name.contains(
"hcal") && volume_name.contains(
"olume"));
61inline bool isInEcalOld(G4LogicalVolume* vol,
const std::string& vol_to_bias) {
62 const G4String& volume_name = vol->GetName();
63 return ((volume_name.contains(
"Si") || volume_name.contains(
"W")) &&
64 volume_name.contains(
"volume"));
75inline bool isInTargetRegion(G4LogicalVolume* vol,
76 const std::string& vol_to_bias) {
77 auto region = vol->GetRegion();
78 return (region and region->GetName().contains(
"target"));
91inline bool isInTargetOnly(G4LogicalVolume* vol,
92 const std::string& vol_to_bias) {
93 return vol->GetName().contains(
"target");
108inline bool nameContains(G4LogicalVolume* vol,
const std::string& vol_to_bias) {
109 return vol->GetName().contains(vol_to_bias);
This namespace is meant to contain all the standard user actions that allow a Geant4 user to interfac...
Dynamically loadable photonuclear models either from SimCore or external libraries implementing this ...