Message: Referencing/passing sensitive detector to analysis manager Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Referencing/passing sensitive detector to analysis manager 

Forum: Event and Track Management
Date: 30 Aug, 2012
From: Bethany <Bethany>

Hello, I'm not quite sure which forum section is best to put this in, so this is my best guess.

Here is the issue that I'm having. I have a stepping action file in my simulation which has information I need to use to know when to call a function in my sensitive detector file. I can access my analysis manager file and its functions by doing analysisManager.functionname(parameters) because the analysis manager is passed to the stepping action and sensitive detector files. What I need to do is to pass the sensitive detector to either the stepping action or analysis manager file, so that I can call a function from sensitive detector from one of those two places. Those files are called at the frequency I need this function from sensitive detector to be called, but since the sensitive detector file is only called from time to time, I need to call this function within it from one of these two other places.

I have tried to do this by passing the sensitive detector to either the stepping action or analysis manager files as the analysis manager is passed to the stepping action and analysis manager files. It's possible I'm missing something, otherwise I wonder whether there is some other reason why this won't work? Is the analysis manager somehow special that it can be passed and the others can't?

What I have done is to add the sensitive detector into (for example) the stepping action declaration, both in the .cc and .hh files. I also declared the sensitive detector itself in the .hh file in the public section. Then I went to mysim.cc and changed the declaration there also. I think this is all I did although it's been a long day and my brain is getting fuzzy.

The errors I get when things don't work are largely complaints about missing semicolons, improper matching of arguments and types, and (strangely) seeming to say that string is not a valid type.

I can give more detail if that would be helpful, it's possible I left out something relevant.

If you have any ideas of what might be causing my difficulties please let me know!

Thank you!

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

1 Idea: Re: Referencing/passing sensitive detector to analysis manager   (Zach Hartwig - 30 Aug, 2012)
(_ None: Re: Referencing/passing sensitive detector to analysis manager   (Bethany - 31 Aug, 2012)
(_ Idea: Re: Referencing/passing sensitive detector to analysis manager   (Zach Hartwig - 31 Aug, 2012)
 Add Message Add Message
to: "Referencing/passing sensitive detector to analysis manager"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]