32 #ifndef DicomPhantomZSliceHeader_h
33 #define DicomPhantomZSliceHeader_h 1
122 fMateIDs.push_back(std::vector<G4int>(0)); }
125 fValues.back().push_back(val) :
126 fValues.push_back(std::vector<G4double>(1,val)); }
128 void AddValue(
const std::vector<std::vector<G4double> >& val) {
129 for(
unsigned int i = 0; i < val.size(); ++i) {
fValues.push_back(val.at(i)); }
134 fMateIDs.push_back(std::vector<G4int>(1,val)); }
136 void AddMateID(
const std::vector<std::vector<G4int> >& val) {
137 for(
unsigned int i = 0; i < val.size(); ++i) {
fMateIDs.push_back(val.at(i)); }
153 template <
typename T>
154 inline void print(std::ostream&,
const std::vector<T>&,
const G4String&,
155 G4int breakLine = -1);
191 return (str.find_first_not_of(
"0123456789") == std::string::npos) ?
true :
false;
194 template <
typename T>
197 std::istringstream iss(str);
203 template <
typename T>
207 G4Exception(
"DicomPhantomSliceZHeader::CheckConsistency",
208 "Consistency Mismatch : Keeping previous value if nonzero",
215 template <
typename T>
219 for(
unsigned int i = 0; i < val.size(); ++i) {
222 if(i+1 < val.size()) { out << delim; }
225 ((i != 0 && i%breakLine == 0) ? (out <<
G4endl) : (out << delim)); }
void G4Exception(const char *originOfException, const char *exceptionCode, G4ExceptionSeverity severity, const char *comments)