#include <TRecurseGeoManager.hxx>
Definition at line 8 of file TRecurseGeoManager.hxx.
TRecurseGeoManager::TRecurseGeoManager |
( |
| ) |
|
|
inline |
virtual TRecurseGeoManager::~TRecurseGeoManager |
( |
| ) |
|
|
inlinevirtual |
virtual bool TRecurseGeoManager::Action |
( |
int |
depth | ) |
|
|
inlinevirtual |
An action to override. Return false if the recursion should be stopped. The action should act on the current node, and NOT change the geometry. The input argument (depth) is the current depth in the geometry (zero is the node where the recursion started).
Definition at line 38 of file TRecurseGeoManager.hxx.
39 TGeoNode* node = gGeoManager->GetCurrentNode();
40 TGeoExtension* extension;
41 extension = node->GetUserExtension();
43 std::cout <<
"Have node user extension " << node->GetName()
47 extension = node->GetFWExtension();
49 std::cout <<
"Have node FW extension " << node->GetName()
53 TGeoVolume*
volume = node->GetVolume();
54 extension = volume->GetUserExtension();
56 std::cout <<
"Have volume user extension " << volume->GetName()
60 extension = volume->GetFWExtension();
62 std::cout <<
"Have volume FW extension " << volume->GetName()
static const std::string volume[nvol]
QTextStream & endl(QTextStream &s)
bool TRecurseGeoManager::Apply |
( |
int |
depth = 0 | ) |
|
|
inline |
Apply the action recursively to every node starting with the current node (depth first).
Definition at line 15 of file TRecurseGeoManager.hxx.
16 TGeoNode * node = gGeoManager->GetCurrentNode();
22 for (
int i=0; i< node->GetNdaughters(); ++i) {
23 gGeoManager->CdDown(i);
24 if (!
Apply(depth+1)) {
virtual bool Action(int depth)
The documentation for this class was generated from the following file: