Go to the source code of this file.
◆ operator<<()
Definition at line 1295 of file G4SmartVoxelHeader.cc.
1296{
1299 std::size_t collectNodeNo = 0;
1300 std::size_t collectHeadNo = 0;
1301 std::size_t i, j;
1302 G4bool haveHeaders =
false;
1303
1304 for (i=0; i<h.
fslices.size(); ++i)
1305 {
1306 os << "Slice #" << i << " = ";
1308 {
1309 if (h.
fslices[i]!=collectNode)
1310 {
1311 os << "{";
1312 for (std::size_t k=0; k<h.
fslices[i]->GetNode()->GetNoContained(); ++k)
1313 {
1314 os <<
" " << h.
fslices[i]->GetNode()->GetVolume((
G4int)k);
1315 }
1318 collectNodeNo = i;
1319 }
1320 else
1321 {
1322 os <<
"As slice #" << collectNodeNo <<
G4endl;
1323 }
1324 }
1325 else
1326 {
1327 haveHeaders=true;
1328 if (h.
fslices[i] != collectHead)
1329 {
1330 os <<
"Header" <<
G4endl;
1332 collectHeadNo = i;
1333 }
1334 else
1335 {
1336 os <<
"As slice #" << collectHeadNo <<
G4endl;
1337 }
1338 }
1339 }
1340
1341 if (haveHeaders)
1342 {
1343 collectHead=nullptr;
1344 for (j=0; j<h.
fslices.size(); ++j)
1345 {
1347 {
1348 os << "Header at Slice #" << j << " = ";
1349 if (h.
fslices[j] != collectHead)
1350 {
1352 << (*(h.
fslices[j]->GetHeader()));
1354 collectHeadNo = j;
1355 }
1356 else
1357 {
1358 os <<
"As slice #" << collectHeadNo <<
G4endl;
1359 }
1360 }
1361 }
1362 }
1363 return os;
1364}