ATLAS Offline Software
Loading...
Searching...
No Matches
VolumeTreeNavigator.h File Reference
#include <string>
#include <vector>
#include <stdarg.h>
#include "AthenaBaseComps/AthMessaging.h"
#include "VolumeTreeNavigator.icc"
Include dependency graph for VolumeTreeNavigator.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  VolumeTreeNavigator

Typedefs

typedef std::pair< G4VPhysicalVolume *, int > VolID
typedef std::vector< VolIDVolTree
typedef VolTree::iterator VolNav

Functions

template<class T>
std::string stringify (T obj)
template<class T>
std::string cleanstr (T obj)

Typedef Documentation

◆ VolID

typedef std::pair<G4VPhysicalVolume*,int> VolID

Definition at line 35 of file VolumeTreeNavigator.h.

◆ VolNav

typedef VolTree::iterator VolNav

Definition at line 37 of file VolumeTreeNavigator.h.

◆ VolTree

typedef std::vector<VolID> VolTree

Definition at line 36 of file VolumeTreeNavigator.h.

Function Documentation

◆ cleanstr()

template<class T>
std::string cleanstr ( T obj)
inline

Definition at line 81 of file VolumeTreeNavigator.h.

82{
83 std::string s = stringify(std::move(obj));
84 std::string::size_type col = s.find_first_of(":");
85 while (col != std::string::npos) {
86 (s.substr(col,2) == "::") ? s.replace(col,2,"_") : s.replace(col,1,"-");
87 col = s.find_first_of(":");
88 }
89 std::string::size_type sp = s.find_first_of(" ");
90 while (sp != std::string::npos) {
91 s.erase(sp,1);
92 sp = s.find_first_of(" ");
93 }
94 return s;
95}
static Double_t sp
std::string stringify(T obj)

◆ stringify()

template<class T>
std::string stringify ( T obj)
inline

Definition at line 73 of file VolumeTreeNavigator.h.

74{
75 std::ostringstream ss;
76 ss << obj;
77 return ss.str();
78}
static Double_t ss