File indexing completed on 2025-01-18 09:14:22
0001 """Helper object for hepmc3 input control"""
0002
0003 from DDSim.Helper.Input import Input
0004
0005
0006 class HepMC3(Input):
0007 """Configuration for the hepmc3 InputFiles"""
0008
0009 def __init__(self):
0010 super(HepMC3, self).__init__()
0011 self._parameters["Flow1"] = "flow1"
0012 self._parameters["Flow2"] = "flow2"
0013
0014 self._useHepMC3 = ("@DD4HEP_USE_HEPMC3@" != "OFF")
0015 self._closeProperties()
0016
0017 @property
0018 def useHepMC3(self):
0019 """Set to false if the input should be opened with the hepmc2 ascii reader.
0020
0021 If ``True`` a '.hepmc' file will be opened with the HEPMC3 Reader Factory.
0022
0023 Defaults to true if DD4hep was build with HEPMC3 support.
0024 """
0025 return self._useHepMC3
0026
0027 @useHepMC3.setter
0028 def useHepMC3(self, val):
0029 self._useHepMC3 = self.makeBool(val)
0030
0031 @property
0032 def Flow1(self):
0033 """Set the name of the attribute contraining color flow information index 0."""
0034 return self._parameters["Flow1"]
0035
0036 @Flow1.setter
0037 def Flow1(self, val):
0038 self._parameters["Flow1"] = val
0039
0040 @property
0041 def Flow2(self):
0042 """Set the name of the attribute contraining color flow information index 1."""
0043 return self._parameters["Flow2"]
0044
0045 @Flow2.setter
0046 def Flow2(self, val):
0047 self._parameters["Flow2"] = val