Definition of the DicomRun class.
More...
#include "G4Run.hh"
#include "G4Event.hh"
#include "G4THitsMap.hh"
#include <vector>
Go to the source code of this file.
|
template<typename T > |
void | Copy (std::vector< T > &main, const std::vector< T > &data) |
|
template<typename T > |
size_t | Copy (std::vector< T * > &main, const std::vector< T * > &data) |
|
template<typename T > |
void | Print (const std::vector< T > &data) |
|
Definition of the DicomRun class.
Definition in file DicomRun.hh.
◆ Copy() [1/2]
template<typename T >
void Copy |
( |
std::vector< T > & |
main, |
|
|
const std::vector< T > & |
data |
|
) |
| |
|
inline |
Definition at line 91 of file DicomRun.hh.
92{
93 for(
size_t i =
main.size(); i < data.size(); ++i) {
94 main.push_back(data.at(i));
95 }
96}
◆ Copy() [2/2]
template<typename T >
size_t Copy |
( |
std::vector< T * > & |
main, |
|
|
const std::vector< T * > & |
data |
|
) |
| |
|
inline |
Definition at line 99 of file DicomRun.hh.
100{
101 size_t size_diff = data.size() -
main.size();
102 for(
size_t i =
main.size(); i < data.size(); ++i) {
103 main.push_back(
new T(*data.at(i)));
104 }
105 return size_diff;
106}
◆ Print()
template<typename T >
void Print |
( |
const std::vector< T > & |
data | ) |
|
|
inline |
Definition at line 109 of file DicomRun.hh.
110{
111 G4cout << G4endl;
112 for(size_t i = 0; i < data.size(); ++i) {
113 G4cout << "\t\t" << i << " \t\t " << data.at(i) << G4endl;
114 }
115 G4cout << G4endl;
116}