I would like to use ROOT reflection technique to store geometry in Geant4. Everything works fine until I intend to store sensitive detectors. I get the following message:
Error in TStreamerInfo::Build: G4HitsCollection, unknown type: void* theCollection
It looks ROOT does not know void* type. Is there a solution for this?
it is not possible to stream a void* because behind it any type can be hidden. What is the actual type behind this type erasure? What is the class instance you are trying to persistify?
I am not such a coding guru so I am not sure how to figure out what type is hidden behind void*. I have bumped into void* theCollection in a standard Geant4 file (G4HitsCollection) while I was trying to store sensitive detector information. Here is the link to G4HitsCollection on Geant4 page.
the problem here is to try and persistify something which is opaque to ROOT (and to anything: void* can be anything, by definition). The link is not particularly useful since the issue here is really the void*.
Is this class made to be persistent? Can you reach out to G4 developers?