What you want to do is very interesting. However, I don’t think it will be possible in a simple way
To generate the ephemeris in mean and osculating elements, what you can do is running a DSST propagation in mean elements with a fixed step handler that will perform the mean to osculating transformation at each step while preserving the mean DSST propagation. Therefore, I think you could be able to write two different ephemeris using the same orbit propagation.
For event detection, because the propagation type is configured at DSST propagator initialization, I don’t think it is possible to have both event detectors based on mean elements and osculating elements. What you try is performing the orbit propagation in osculating elements and for the event detectors based on mean elements, converting the input osculating state in the
g function, convert it in mean elements, and call a custom
gMean function inside the event detector.
It is a “DIY” solution, not really interesting and it will probably increase considerably the calculation time.