CGEM BOSS 6.6.5.g
BESIII Offline Software System
Loading...
Searching...
No Matches
AsciiData.cc
Go to the documentation of this file.
1
2#include "AsciiData.hh"
3
4//std::string Tagged::s_saved_tag;
5
6std::istream& operator>>(std::istream& is, FRMTVERSION& x)
7{
8 x.check_start_tag(is,"VERSION");
9 if(!x.initialized()) return is;
10 is >> x.major;
11 is >> x.minor;
12 x.check_end_tag(is, "VERSION");
13 return is;
14}
15
16std::ostream& operator<<(std::ostream& os, const FRMTVERSION& x)
17{
18 os << std::endl << "{ VERSION" << std::endl;
19 if(x.initialized()) {
20 os << " " << x.major;
21 os << " " << x.minor;
22 }
23 os << std::endl << "} VERSION" << std::endl;
24 return os;
25}
26
27std::istream& operator>>(std::istream& is, EVHEAD& x)
28{
29 x.check_start_tag(is,"EVHEAD");
30 if(!x.initialized()) return is;
31 is >> x.runNo;
32 is >> x.eventNo;
33 x.check_end_tag(is, "EVHEAD");
34 return is;
35}
36
37std::ostream& operator<<(std::ostream &os,const EVHEAD& x)
38{
39 os << std::endl << "{ EVHEAD" << std::endl;
40 if(x.initialized()) {
41 os << " " << x.runNo;
42 os << " " << x.eventNo;
43 }
44 os << std::endl << "} EVHEAD" << std::endl;
45 return os;
46}
47
48std::istream& operator>>(std::istream& is, DECAYMODE& x)
49{
50 x.check_start_tag(is,"DECAYMODE");
51 if(!x.initialized()) return is;
52 is >> x.size;
53 for (int index=0; index<x.size; index++) {
54 is >> x.data[index];
55 }
56 x.check_end_tag(is, "DECAYMODE");
57 return is;
58}
59
60std::ostream& operator<<(std::ostream &os,const DECAYMODE& x)
61{
62 os << std::endl << "{ DECAYMODE" << std::endl;
63 if(x.initialized()) {
64 os << " " << x.size;
65 for (int index=0; index<x.size; index++) {
66 os << " " << x.data[index];
67 }
68 }
69 os << std::endl << "} DECAYMODE" << std::endl;
70 return os;
71}
72
73std::istream& operator>>(std::istream& is, TrackTruthType& x)
74{
75 is >> x.trackIndex;
76 is >> x.PDGCode;
77 is >> x.PDGCharge;
78 is >> x.v0Index;
79 is >> x.v1Index;
80 is >> x.px;
81 is >> x.py;
82 is >> x.pz;
83 is >> x.E;
84 is >> x.minDaughterIndex;
85 is >> x.maxDaughterIndex;
86 return is;
87}
88
89std::ostream& operator<<(std::ostream &os,const TrackTruthType& x)
90{
91 os << " " << x.trackIndex;
92 os << " " << x.PDGCode;
93 os << " " << x.PDGCharge;
94 os << " " << x.v0Index;
95 os << " " << x.v1Index;
96 os << " " << x.px;
97 os << " " << x.py;
98 os << " " << x.pz;
99 os << " " << x.E;
100 os << " " << x.minDaughterIndex;
101 os << " " << x.maxDaughterIndex;
102 os << std::endl;
103 return os;
104}
105
106std::istream& operator>>(std::istream& is, TRACKTRUTH& x)
107{
108 x.check_start_tag(is,"TRACKTRUTH");
109 if(!x.initialized()) return is;
110 is >> x.nTruth;
111 x.truthCol.resize(x.nTruth);
112 {for(int i = 0; i < x.nTruth; i++) {
113 is >> x.truthCol[i];
114 }}
115 x.check_end_tag(is, "TRACKTRUTH");
116 return is;
117}
118
119std::ostream& operator<<(std::ostream &os,const TRACKTRUTH& x)
120{
121 os << std::endl << "{ TRACKTRUTH" << std::endl;
122 if(x.initialized()) {
123 os << " " << x.nTruth;
124 {for(int i = 0; i < x.nTruth; i++) {
125 os << " " << x.truthCol[i];
126 }}
127 }
128 os << std::endl << "} TRACKTRUTH" << std::endl;
129 return os;
130}
131
132std::istream& operator>>(std::istream& is, VertexTruthType& x)
133{
134 is >> x.vertexIndex;
135 is >> x.parentTrackIndex;
136 is >> x.posX;
137 is >> x.posY;
138 is >> x.posZ;
139 is >> x.time;
140 return is;
141}
142
143std::ostream& operator<<(std::ostream &os,const VertexTruthType& x)
144{
145 os << " " << x.vertexIndex;
146 os << " " << x.parentTrackIndex;
147 os << " " << x.posX;
148 os << " " << x.posY;
149 os << " " << x.posZ;
150 os << " " << x.time;
151 os << std::endl;
152 return os;
153}
154
155std::istream& operator>>(std::istream& is, VERTEXTRUTH& x)
156{
157 x.check_start_tag(is,"VERTEXTRUTH");
158 if(!x.initialized()) return is;
159 is >> x.nTruth;
160 x.truthCol.resize(x.nTruth);
161 {for(int i = 0; i < x.nTruth; i++) {
162 is >> x.truthCol[i];
163 }}
164 x.check_end_tag(is, "VERTEXTRUTH");
165 return is;
166}
167
168std::ostream& operator<<(std::ostream &os,const VERTEXTRUTH& x)
169{
170 os << std::endl << "{ VERTEXTRUTH" << std::endl;
171 if(x.initialized()) {
172 os << " " << x.nTruth;
173 {for(int i = 0; i < x.nTruth; i++) {
174 os << " " << x.truthCol[i];
175 }}
176 }
177 os << std::endl << "} VERTEXTRUTH" << std::endl;
178 return os;
179}
180
181
182std::istream& operator>>(std::istream& is, MdcTruthType& x)
183{
184 is >> x.trackIndex;
185 is >> x.layerNo;
186 is >> x.cellNo;
187 is >> x.edep;
188 is >> x.driftD;
189 is >> x.posX;
190 is >> x.posY;
191 is >> x.posZ;
192 is >> x.posFlag;
193 return is;
194}
195
196std::ostream& operator<<(std::ostream &os,const MdcTruthType& x)
197{
198 os << " " << x.trackIndex;
199 os << " " << x.layerNo;
200 os << " " << x.cellNo;
201 os << " " << x.edep;
202 os << " " << x.driftD;
203 os << " " << x.posX;
204 os << " " << x.posY;
205 os << " " << x.posZ;
206 os << " " << x.posFlag;
207 os << std::endl;
208 return os;
209}
210
211std::istream& operator>>(std::istream& is, MDCTRUTH& x)
212{
213 x.check_start_tag(is,"MDCTRUTH");
214 if(!x.initialized()) return is;
215 is >> x.nTruth;
216 x.truthCol.resize(x.nTruth);
217 {for(int i = 0; i < x.nTruth; i++) {
218 is >> x.truthCol[i];
219 }}
220 x.check_end_tag(is, "MDCTRUTH");
221 return is;
222}
223
224std::ostream& operator<<(std::ostream &os,const MDCTRUTH& x)
225{
226 os << std::endl << "{ MDCTRUTH" << std::endl;
227 if(x.initialized()) {
228 os << " " << x.nTruth;
229 {for(int i = 0; i < x.nTruth; i++) {
230 os << " " << x.truthCol[i];
231 }}
232 }
233 os << std::endl << "} MDCTRUTH" << std::endl;
234 return os;
235}
236
237std::istream& operator>>(std::istream& is, CgemTruthType& x)
238{
239 is >> x.m_ID_track;
240 is >> x.m_ID_layer;
241 is >> x.m_pdg_code;
242 is >> x.m_global_time;
243 is >> x.m_E_deposit;
244 is >> x.m_L_step;
245 is >> x.m_XYZ_pre_x;
246 is >> x.m_XYZ_pre_y;
247 is >> x.m_XYZ_pre_z;
248 is >> x.m_XYZ_post_x;
249 is >> x.m_XYZ_post_y;
250 is >> x.m_XYZ_post_z;
251 is >> x.m_P_pre_x;
252 is >> x.m_P_pre_y;
253 is >> x.m_P_pre_z;
254 is >> x.m_P_post_x;
255 is >> x.m_P_post_y;
256 is >> x.m_P_post_z;
257//*************************
258 is >> x.m_Cu_pre_x;
259 is >> x.m_Cu_pre_y;
260 is >> x.m_Cu_pre_z;
261 is >> x.m_Cu_post_x;
262 is >> x.m_Cu_post_y;
263 is >> x.m_Cu_post_z;
264 is >> x.m_P_Cu_pre_x;
265 is >> x.m_P_Cu_pre_y;
266 is >> x.m_P_Cu_pre_z;
267 is >> x.m_P_Cu_post_x;
268 is >> x.m_P_Cu_post_y;
269 is >> x.m_P_Cu_post_z;
270//******************************
271 return is;
272}
273
274std::ostream& operator<<(std::ostream &os,const CgemTruthType& x)
275{
276 os << " " << x.m_ID_track;
277 os << " " << x.m_ID_layer;
278 os << " " << x.m_pdg_code;
279 os << " " << x.m_global_time;
280 os << " " << x.m_E_deposit;
281 os << " " << x.m_L_step;
282 os << " " << x.m_XYZ_pre_x;
283 os << " " << x.m_XYZ_pre_y;
284 os << " " << x.m_XYZ_pre_z;
285 os << " " << x.m_XYZ_post_x;
286 os << " " << x.m_XYZ_post_y;
287 os << " " << x.m_XYZ_post_z;
288 os << " " << x.m_P_pre_x;
289 os << " " << x.m_P_pre_y;
290 os << " " << x.m_P_pre_z;
291 os << " " << x.m_P_post_x;
292 os << " " << x.m_P_post_y;
293 os << " " << x.m_P_post_z;
294 os << " " << x.m_Cu_pre_x;
295 os << " " << x.m_Cu_pre_y;
296 os << " " << x.m_Cu_pre_z;
297 os << " " << x.m_Cu_post_x;
298 os << " " << x.m_Cu_post_y;
299 os << " " << x.m_Cu_post_z;
300 os << " " << x.m_P_Cu_pre_x;
301 os << " " << x.m_P_Cu_pre_y;
302 os << " " << x.m_P_Cu_pre_z;
303 os << " " << x.m_P_Cu_post_x;
304 os << " " << x.m_P_Cu_post_y;
305 os << " " << x.m_P_Cu_post_z;
306 os << std::endl;
307 return os;
308}
309
310std::istream& operator>>(std::istream& is, CGEMTRUTH& x)
311{
312 x.check_start_tag(is,"CGEMTRUTH");
313 if(!x.initialized()) return is;
314 is >> x.nTruth;
315 x.truthCol.resize(x.nTruth);
316 {for(int i = 0; i < x.nTruth; i++) {
317 is >> x.truthCol[i];
318 }}
319 x.check_end_tag(is, "CGEMTRUTH");
320 return is;
321}
322
323std::ostream& operator<<(std::ostream &os,const CGEMTRUTH& x)
324{
325 os << std::endl << "{ CGEMTRUTH" << std::endl;
326 if(x.initialized()) {
327 os << " " << x.nTruth;
328 {for(int i = 0; i < x.nTruth; i++) {
329 os << " " << x.truthCol[i];
330 }}
331 }
332 os << std::endl << "} CGEMTRUTH" << std::endl;
333 return os;
334}
335
336std::istream& operator>>(std::istream& is, TofTruthType& x)
337{
338 is >> x.trackIndex;
339 is >> x.partId;
340 is >> x.scinNb;
341 is >> x.posX;
342 is >> x.posY;
343 is >> x.posZ;
344 is >> x.px;
345 is >> x.py;
346 is >> x.pz;
347 is >> x.trackL;
348 is >> x.time;
349 return is;
350}
351
352std::ostream& operator<<(std::ostream &os,const TofTruthType& x)
353{
354 os << " " << x.trackIndex;
355 os << " " << x.partId;
356 os << " " << x.scinNb;
357 os << " " << x.posX;
358 os << " " << x.posY;
359 os << " " << x.posZ;
360 os << " " << x.px;
361 os << " " << x.py;
362 os << " " << x.pz;
363 os << " " << x.trackL;
364 os << " " << x.time;
365 os << std::endl;
366 return os;
367}
368
369std::istream& operator>>(std::istream& is, TOFTRUTH& x)
370{
371 x.check_start_tag(is,"TOFTRUTH");
372 if(!x.initialized()) return is;
373 is >> x.nTruth;
374 x.truthCol.resize(x.nTruth);
375 {for(int i = 0; i < x.nTruth; i++) {
376 is >> x.truthCol[i];
377 }}
378 x.check_end_tag(is, "TOFTRUTH");
379 return is;
380}
381
382std::ostream& operator<<(std::ostream &os,const TOFTRUTH& x)
383{
384 os << std::endl << "{ TOFTRUTH" << std::endl;
385 if(x.initialized()) {
386 os << " " << x.nTruth;
387 {for(int i = 0; i < x.nTruth; i++) {
388 os << " " << x.truthCol[i];
389 }}
390 }
391 os << std::endl << "} TOFTRUTH" << std::endl;
392 return os;
393}
394
395std::istream& operator>>(std::istream& is, EmcTruthType& x)
396{
397 is >> x.trackIndex;
398 is >> x.partId;
399 is >> x.numTheta;
400 is >> x.numPhi;
401 is >> x.posX;
402 is >> x.posY;
403 is >> x.posZ;
404 is >> x.px;
405 is >> x.py;
406 is >> x.pz;
407 is >> x.totalEdep;
408 return is;
409}
410
411std::ostream& operator<<(std::ostream &os,const EmcTruthType& x)
412{
413 os << " " << x.trackIndex;
414 os << " " << x.partId;
415 os << " " << x.numTheta;
416 os << " " << x.numPhi;
417 os << " " << x.posX;
418 os << " " << x.posY;
419 os << " " << x.posZ;
420 os << " " << x.px;
421 os << " " << x.py;
422 os << " " << x.pz;
423 os << " " << x.totalEdep;
424 os << std::endl;
425 return os;
426
427}
428
429std::istream& operator>>(std::istream& is, EMCTRUTH& x)
430{
431 x.check_start_tag(is,"EMCTRUTH");
432 if(!x.initialized()) return is;
433 is >> x.nTruth;
434 x.truthCol.resize(x.nTruth);
435 {for(int i = 0; i < x.nTruth; i++) {
436 is >> x.truthCol[i];
437 }}
438 x.check_end_tag(is, "EMCTRUTH");
439 return is;
440}
441
442std::ostream& operator<<(std::ostream &os,const EMCTRUTH& x)
443{
444 os << std::endl << "{ EMCTRUTH" << std::endl;
445 if(x.initialized()) {
446 os << " " << x.nTruth;
447 {for(int i = 0; i < x.nTruth; i++) {
448 os << " " << x.truthCol[i];
449 }}
450 }
451 os << std::endl << "} EMCTRUTH" << std::endl;
452 return os;
453}
454
455std::istream& operator>>(std::istream& is, MucTruthType& x)
456{
457 is >> x.trackIndex;
458 is >> x.partId;
459 is >> x.segId;
460 is >> x.gapId;
461 is >> x.stripId;
462 is >> x.posX;
463 is >> x.posY;
464 is >> x.posZ;
465 is >> x.px;
466 is >> x.py;
467 is >> x.pz;
468 return is;
469}
470
471std::ostream& operator<<(std::ostream &os,const MucTruthType& x)
472{
473 os << " " << x.trackIndex;
474 os << " " << x.partId;
475 os << " " << x.segId;
476 os << " " << x.gapId;
477 os << " " << x.stripId;
478 os << " " << x.posX;
479 os << " " << x.posY;
480 os << " " << x.posZ;
481 os << " " << x.px;
482 os << " " << x.py;
483 os << " " << x.pz;
484 os << std::endl;
485 return os;
486}
487
488std::istream& operator>>(std::istream& is, MUCTRUTH& x)
489{
490 x.check_start_tag(is,"MUCTRUTH");
491 if(!x.initialized()) return is;
492 is >> x.nTruth;
493 x.truthCol.resize(x.nTruth);
494 {for(int i = 0; i < x.nTruth; i++) {
495 is >> x.truthCol[i];
496 }}
497 x.check_end_tag(is, "MUCTRUTH");
498 return is;
499}
500
501std::ostream& operator<<(std::ostream &os,const MUCTRUTH& x)
502{
503 os << std::endl << "{ MUCTRUTH" << std::endl;
504 if(x.initialized()) {
505 os << " " << x.nTruth;
506 {for(int i = 0; i < x.nTruth; i++) {
507 os << " " << x.truthCol[i];
508 }}
509 }
510 os << std::endl << "} MUCTRUTH" << std::endl;
511 return os;
512}
513
514std::istream& operator>>(std::istream& is, MdcDigiType& x)
515{
516 is >> x.trackIndex;
517 is >> x.layerNo;
518 is >> x.cellNo;
519 is >> x.energyDeposit;
520 is >> x.driftTime;
521 return is;
522}
523
524std::ostream& operator<<(std::ostream &os,const MdcDigiType& x)
525{
526 os << " " << x.trackIndex;
527 os << " " << x.layerNo;
528 os << " " << x.cellNo;
529 os << " " << x.energyDeposit;
530 os << " " << x.driftTime;
531 os << std::endl;
532 return os;
533}
534
535std::istream& operator>>(std::istream& is, MDCDIGI& x)
536{
537 x.check_start_tag(is,"MDCDIGI");
538 if(!x.initialized()) return is;
539 is >> x.nDigi;
540 x.digiCol.resize(x.nDigi);
541 {for(int i = 0; i < x.nDigi; i++) {
542 is >> x.digiCol[i];
543 }}
544 x.check_end_tag(is, "MDCDIGI");
545 return is;
546}
547
548std::ostream& operator<<(std::ostream &os,const MDCDIGI& x)
549{
550 os << std::endl << "{ MDCDIGI" << std::endl;
551 if(x.initialized()) {
552 os << " " << x.nDigi;
553 {for(int i = 0; i < x.nDigi; i++) {
554 os << " " << x.digiCol[i];
555 }}
556 }
557 os << std::endl << "} MDCDIGI" << std::endl;
558 return os;
559}
560
561std::istream& operator>>(std::istream& is, MdcHitType& x)
562{
563 is >> x.trackIndex;
564 is >> x.layerNo;
565 is >> x.cellNo;
566 is >> x.posX;
567 is >> x.posY;
568 is >> x.posZ;
569 is >> x.energyDeposit;
570 is >> x.driftDistance;
571 is >> x.globalT;
572 is >> x.theta;
573 is >> x.enterAngle;
574 is >> x.posFlag;
575 return is;
576}
577
578std::ostream& operator<<(std::ostream &os,const MdcHitType& x)
579{
580 os << " " << x.trackIndex;
581 os << " " << x.layerNo;
582 os << " " << x.cellNo;
583 os << " " << x.posX;
584 os << " " << x.posY;
585 os << " " << x.posZ;
586 os << " " << x.energyDeposit;
587 os << " " << x.driftDistance;
588 os << " " << x.globalT;
589 os << " " << x.theta;
590 os << " " << x.enterAngle;
591 os << " " << x.posFlag;
592 os << std::endl;
593 return os;
594}
595
596std::istream& operator>>(std::istream& is, MDCHIT& x)
597{
598 x.check_start_tag(is,"MDCHIT");
599 if(!x.initialized()) return is;
600 is >> x.nHit;
601 x.hitCol.resize(x.nHit);
602 {for(int i = 0; i < x.nHit; i++) {
603 is >> x.hitCol[i];
604 }}
605 x.check_end_tag(is, "MDCHIT");
606 return is;
607}
608
609std::ostream& operator<<(std::ostream &os,const MDCHIT& x)
610{
611 os << std::endl << "{ MDCHIT" << std::endl;
612 if(x.initialized()) {
613 os << " " << x.nHit;
614 {for(int i = 0; i < x.nHit; i++) {
615 os << " " << x.hitCol[i];
616 }}
617 }
618 os << std::endl << "} MDCHIT" << std::endl;
619 return os;
620}
621
622std::istream& operator>>(std::istream& is, CgemDigiType& x)
623{
624 is >> x.m_ID_track;
625 is >> x.m_ID_layer;
626 is >> x.m_ID_sheet;
627 is >> x.m_F_XV;
628 is >> x.m_ID_strip;
629 is >> x.m_E_deposit;
630 is >> x.m_global_time;
631 return is;
632}
633
634std::ostream& operator<<(std::ostream &os,const CgemDigiType& x)
635{
636 os << " " << x.m_ID_track;
637 os << " " << x.m_ID_layer;
638 os << " " << x.m_ID_sheet;
639 os << " " << x.m_F_XV;
640 os << " " << x.m_ID_strip;
641 os << " " << x.m_E_deposit;
642 os << " " << x.m_global_time;
643 os << std::endl;
644 return os;
645}
646
647std::istream& operator>>(std::istream& is, CGEMDIGI& x)
648{
649 x.check_start_tag(is,"CGEMDIGI");
650 if(!x.initialized()) return is;
651 is >> x.nDigi;
652 x.digiCol.resize(x.nDigi);
653 {for(int i = 0; i < x.nDigi; i++) {
654 is >> x.digiCol[i];
655 }}
656 x.check_end_tag(is, "CGEMDIGI");
657 return is;
658}
659
660std::ostream& operator<<(std::ostream &os,const CGEMDIGI& x)
661{
662 os << std::endl << "{ CGEMDIGI" << std::endl;
663 if(x.initialized()) {
664 os << " " << x.nDigi;
665 {for(int i = 0; i < x.nDigi; i++) {
666 os << " " << x.digiCol[i];
667 }}
668 }
669 os << std::endl << "} CGEMDIGI" << std::endl;
670 return os;
671}
672
673std::istream& operator>>(std::istream& is, CgemHitType& x)
674{
675 is >> x.m_ID_track;
676 is >> x.m_ID_layer;
677 is >> x.m_pdg_code;
678 is >> x.m_global_time;
679 is >> x.m_E_deposit;
680 is >> x.m_L_step;
681 is >> x.m_XYZ_pre_x;
682 is >> x.m_XYZ_pre_y;
683 is >> x.m_XYZ_pre_z;
684 is >> x.m_XYZ_post_x;
685 is >> x.m_XYZ_post_y;
686 is >> x.m_XYZ_post_z;
687 is >> x.m_P_pre_x;
688 is >> x.m_P_pre_y;
689 is >> x.m_P_pre_z;
690 is >> x.m_P_post_x;
691 is >> x.m_P_post_y;
692 is >> x.m_P_post_z;
693//***********************************
694 is >> x.m_Cu_pre_x;
695 is >> x.m_Cu_pre_y;
696 is >> x.m_Cu_pre_z;
697 is >> x.m_Cu_post_x;
698 is >> x.m_Cu_post_y;
699 is >> x.m_Cu_post_z;
700 is >> x.m_P_Cu_pre_x;
701 is >> x.m_P_Cu_pre_y;
702 is >> x.m_P_Cu_pre_z;
703 is >> x.m_P_Cu_post_x;
704 is >> x.m_P_Cu_post_y;
705 is >> x.m_P_Cu_post_z;
706//****************************
707 return is;
708}
709
710std::ostream& operator<<(std::ostream &os,const CgemHitType& x)
711{
712 os << " " << x.m_ID_track;
713 os << " " << x.m_ID_layer;
714 os << " " << x.m_pdg_code;
715 os << " " << x.m_global_time;
716 os << " " << x.m_E_deposit;
717 os << " " << x.m_L_step;
718 os << " " << x.m_XYZ_pre_x;
719 os << " " << x.m_XYZ_pre_y;
720 os << " " << x.m_XYZ_pre_z;
721 os << " " << x.m_XYZ_post_x;
722 os << " " << x.m_XYZ_post_y;
723 os << " " << x.m_XYZ_post_z;
724 os << " " << x.m_P_pre_x;
725 os << " " << x.m_P_pre_y;
726 os << " " << x.m_P_pre_z;
727 os << " " << x.m_P_post_x;
728 os << " " << x.m_P_post_y;
729 os << " " << x.m_P_post_z;
730//******************************************
731 os << " " << x.m_Cu_pre_x;
732 os << " " << x.m_Cu_pre_y;
733 os << " " << x.m_Cu_pre_z;
734 os << " " << x.m_Cu_post_x;
735 os << " " << x.m_Cu_post_y;
736 os << " " << x.m_Cu_post_z;
737 os << " " << x.m_P_Cu_pre_x;
738 os << " " << x.m_P_Cu_pre_y;
739 os << " " << x.m_P_Cu_pre_z;
740 os << " " << x.m_P_Cu_post_x;
741 os << " " << x.m_P_Cu_post_y;
742 os << " " << x.m_P_Cu_post_z;
743//***************************************
744 os << std::endl;
745 return os;
746}
747
748std::istream& operator>>(std::istream& is, CGEMHIT& x)
749{
750 x.check_start_tag(is,"CGEMHIT");
751 if(!x.initialized()) return is;
752 is >> x.nHit;
753 x.hitCol.resize(x.nHit);
754 {for(int i = 0; i < x.nHit; i++) {
755 is >> x.hitCol[i];
756 }}
757 x.check_end_tag(is, "CGEMHIT");
758 return is;
759}
760
761std::ostream& operator<<(std::ostream &os,const CGEMHIT& x)
762{
763 os << std::endl << "{ CGEMHIT" << std::endl;
764 if(x.initialized()) {
765 os << " " << x.nHit;
766 {for(int i = 0; i < x.nHit; i++) {
767 os << " " << x.hitCol[i];
768 }}
769 }
770 os << std::endl << "} CGEMHIT" << std::endl;
771 return os;
772}
773
774std::istream& operator>>(std::istream& is, TofDigiType& x)
775{
776 is >> x.trackIndex;
777 is >> x.partId;
778 is >> x.scinNb;
779 is >> x.forwADC;
780 is >> x.forwTDC;
781 is >> x.backADC;
782 is >> x.backTDC;
783 return is;
784}
785
786std::ostream& operator<<(std::ostream &os,const TofDigiType& x)
787{
788 os << " " << x.trackIndex;
789 os << " " << x.partId;
790 os << " " << x.scinNb;
791 os << " " << x.forwADC;
792 os << " " << x.forwTDC;
793 os << " " << x.backADC;
794 os << " " << x.backTDC;
795 os << std::endl;
796 return os;
797}
798
799
800std::istream& operator>>(std::istream& is, TOFDIGI& x)
801{
802 x.check_start_tag(is,"TOFDIGI");
803 if(!x.initialized()) return is;
804 is >> x.nDigi;
805 x.digiCol.resize(x.nDigi);
806 {for(int i = 0; i < x.nDigi; i++) {
807 is >> x.digiCol[i];
808 }}
809 x.check_end_tag(is, "TOFDIGI");
810 return is;
811}
812
813std::ostream& operator<<(std::ostream &os,const TOFDIGI& x)
814{
815 os << std::endl << "{ TOFDIGI" << std::endl;
816 if(x.initialized()) {
817 os << " " << x.nDigi;
818 {for(int i = 0; i < x.nDigi; i++) {
819 os << " " << x.digiCol[i];
820 }}
821 }
822 os << std::endl << "} TOFDIGI" << std::endl;
823 return os;
824}
825
826std::istream& operator>>(std::istream& is, TofHitType& x)
827{
828 return is;
829}
830
831std::ostream& operator<<(std::ostream &os,const TofHitType& x)
832{
833 os << std::endl;
834 return os;
835}
836
837
838std::istream& operator>>(std::istream& is, TOFHIT& x)
839{
840 x.check_start_tag(is,"TOFHIT");
841 if(!x.initialized()) return is;
842 is >> x.nHit;
843 x.hitCol.resize(x.nHit);
844 {for(int i = 0; i < x.nHit; i++) {
845 is >> x.hitCol[i];
846 }}
847 x.check_end_tag(is, "TOFHIT");
848 return is;
849}
850
851std::ostream& operator<<(std::ostream &os,const TOFHIT& x)
852{
853 os << std::endl << "{ TOFHIT" << std::endl;
854 if(x.initialized()) {
855 os << " " << x.nHit;
856 {for(int i = 0; i < x.nHit; i++) {
857 os << " " << x.hitCol[i];
858 }}
859 }
860 os << std::endl << "} TOFHIT" << std::endl;
861 return os;
862}
863
864std::istream& operator>>(std::istream& is, EmcDigiType& x)
865{
866 is >> x.trackIndex;
867 is >> x.partId;
868 is >> x.numTheta;
869 is >> x.numPhi;
870 is >> x.energyDeposit;
871 is >> x.hitTime;
872 return is;
873}
874
875std::ostream& operator<<(std::ostream &os,const EmcDigiType& x)
876{
877 os << " " << x.trackIndex;
878 os << " " << x.partId;
879 os << " " << x.numTheta;
880 os << " " << x.numPhi;
881 os << " " << x.energyDeposit;
882 os << " " << x.hitTime;
883 os << std::endl;
884 return os;
885}
886
887std::istream& operator>>(std::istream& is, EMCDIGI& x)
888{
889 x.check_start_tag(is,"EMCDIGI");
890 if(!x.initialized()) return is;
891 is >> x.nDigi;
892 x.digiCol.resize(x.nDigi);
893 {for(int i = 0; i < x.nDigi; i++) {
894 is >> x.digiCol[i];
895 }}
896 x.check_end_tag(is, "EMCDIGI");
897 return is;
898}
899
900std::ostream& operator<<(std::ostream &os,const EMCDIGI& x)
901{
902 os << std::endl << "{ EMCDIGI" << std::endl;
903 if(x.initialized()) {
904 os << " " << x.nDigi;
905 {for(int i = 0; i < x.nDigi; i++) {
906 os << " " << x.digiCol[i];
907 }}
908 }
909 os << std::endl << "} EMCDIGI" << std::endl;
910 return os;
911}
912
913std::istream& operator>>(std::istream& is, EmcHitType& x)
914{
915 return is;
916}
917
918std::ostream& operator<<(std::ostream &os,const EmcHitType& x)
919{
920 os << std::endl;
921 return os;
922}
923
924
925std::istream& operator>>(std::istream& is, EMCHIT& x)
926{
927 x.check_start_tag(is,"EMCHIT");
928 if(!x.initialized()) return is;
929 is >> x.nHit;
930 x.hitCol.resize(x.nHit);
931 {for(int i = 0; i < x.nHit; i++) {
932 is >> x.hitCol[i];
933 }}
934 x.check_end_tag(is, "EMCHIT");
935 return is;
936}
937
938std::ostream& operator<<(std::ostream &os,const EMCHIT& x)
939{
940 os << std::endl << "{ EMCHIT" << std::endl;
941 if(x.initialized()) {
942 os << " " << x.nHit;
943 {for(int i = 0; i < x.nHit; i++) {
944 os << " " << x.hitCol[i];
945 }}
946 }
947 os << std::endl << "} EMCHIT" << std::endl;
948 return os;
949}
950
951std::istream& operator>>(std::istream& is, MucDigiType& x)
952{
953 is >> x.trackIndex;
954 is >> x.partNo;
955 is >> x.segNo;
956 is >> x.gapNo;
957 is >> x.stripNo;
958 return is;
959}
960
961std::ostream& operator<<(std::ostream &os,const MucDigiType& x)
962{
963 os << " " << x.trackIndex;
964 os << " " << x.partNo;
965 os << " " << x.segNo;
966 os << " " << x.gapNo;
967 os << " " << x.stripNo;
968 os << std::endl;
969 return os;
970}
971
972
973std::istream& operator>>(std::istream& is, MUCDIGI& x)
974{
975 x.check_start_tag(is,"MUCDIGI");
976 if(!x.initialized()) return is;
977 is >> x.nDigi;
978 x.digiCol.resize(x.nDigi);
979 {for(int i = 0; i < x.nDigi; i++) {
980 is >> x.digiCol[i];
981 }}
982 x.check_end_tag(is, "MUCDIGI");
983 return is;
984}
985
986std::ostream& operator<<(std::ostream &os,const MUCDIGI& x)
987{
988 os << std::endl << "{ MUCDIGI" << std::endl;
989 if(x.initialized()) {
990 os << " " << x.nDigi;
991 {for(int i = 0; i < x.nDigi; i++) {
992 os << " " << x.digiCol[i];
993 }}
994 }
995 os << std::endl << "} MUCDIGI" << std::endl;
996 return os;
997}
998
999std::istream& operator>>(std::istream& is, MucHitType& x)
1000{
1001 return is;
1002}
1003
1004std::ostream& operator<<(std::ostream &os,const MucHitType& x)
1005{
1006 os << std::endl;
1007 return os;
1008}
1009
1010
1011std::istream& operator>>(std::istream& is, MUCHIT& x)
1012{
1013 x.check_start_tag(is,"MUCHIT");
1014 if(!x.initialized()) return is;
1015 is >> x.nHit;
1016 x.hitCol.resize(x.nHit);
1017 {for(int i = 0; i < x.nHit; i++) {
1018 is >> x.hitCol[i];
1019 }}
1020 x.check_end_tag(is, "MUCHIT");
1021 return is;
1022}
1023
1024std::ostream& operator<<(std::ostream &os,const MUCHIT& x)
1025{
1026 os << std::endl << "{ MUCHIT" << std::endl;
1027 if(x.initialized()) {
1028 os << " " << x.nHit;
1029 {for(int i = 0; i < x.nHit; i++) {
1030 os << " " << x.hitCol[i];
1031 }}
1032 }
1033 os << std::endl << "} MUCHIT" << std::endl;
1034 return os;
1035}
1036
1037std::istream& operator>>(std::istream& is, EVENT& x)
1038{
1039 x.check_start_tag(is,"EVENT");
1040 if(!x.initialized()) return is;
1041
1042 try {
1043 is >> x.header;
1044 } catch(AsciiDumpException& ) {
1045 std::cerr << "Got AsciiDumpException eror while reading header block !!!" << std::endl;
1046 }
1047
1048 try {
1049 is >> x.decayMode;
1050 } catch(AsciiDumpException& ) {
1051 std::cerr << "Got AsciiDumpException eror while reading decay mode block !!!" << std::endl;
1052 }
1053
1054 try {
1055 is >> x.trackTruth;
1056 } catch(AsciiDumpException& ) {
1057 std::cerr << "Got AsciiDumpException eror while reading track truth block !!!" << std::endl;
1058 }
1059
1060 try {
1061 is >> x.vertexTruth;
1062 } catch (AsciiDumpException& ) {
1063 std::cerr << "Got AsciiDumpException eror while reading vertex truth block !!!" << std::endl;
1064 }
1065
1066 try {
1067 is >> x.mdcTruth;
1068 } catch (AsciiDumpException& ) {
1069 std::cerr << "Got AsciiDumpException eror while reading mdc truth block !!!" << std::endl;
1070 }
1071
1072 try {
1073 is >> x.mdcDigi;
1074 } catch (AsciiDumpException& ) {
1075 std::cerr << "Got AsciiDumpException eror while reading mdc digi block !!!" << std::endl;
1076 }
1077
1078 try {
1079 is >> x.cgemTruth;
1080 } catch (AsciiDumpException& ) {
1081 std::cerr << "Got AsciiDumpException eror while reading cgem truth block !!!" << std::endl;
1082 }
1083
1084 try {
1085 is >> x.cgemDigi;
1086 } catch (AsciiDumpException& ) {
1087 std::cerr << "Got AsciiDumpException eror while reading cgem digi block !!!" << std::endl;
1088 }
1089
1090 try {
1091 is >> x.tofTruth;
1092 } catch (AsciiDumpException& ) {
1093 std::cerr << "Got AsciiDumpException eror while reading tof truth block !!!" << std::endl;
1094 }
1095
1096 try {
1097 is >> x.tofDigi;
1098 } catch (AsciiDumpException& ) {
1099 std::cerr << "Got AsciiDumpException eror while reading tof digi block !!!" << std::endl;
1100 }
1101
1102 try {
1103 is >> x.emcTruth;
1104 } catch (AsciiDumpException& ) {
1105 std::cerr << "Got AsciiDumpException eror while reading emc truth block !!!" << std::endl;
1106 }
1107
1108 try {
1109 is >> x.emcDigi;
1110 } catch (AsciiDumpException& ) {
1111 std::cerr << "Got AsciiDumpException eror while reading emc digi block !!!" << std::endl;
1112 }
1113
1114 try {
1115 is >> x.mucTruth;
1116 } catch (AsciiDumpException& ) {
1117 std::cerr << "Got AsciiDumpException eror while reading muc truth block !!!" << std::endl;
1118 }
1119
1120 try {
1121 is >> x.mucDigi;
1122 } catch (AsciiDumpException& ) {
1123 std::cerr << "Got AsciiDumpException eror while reading muc digi block !!!" << std::endl;
1124 }
1125 x.check_end_tag(is, "EVENT");
1126 return is;
1127}
1128
1129std::ostream& operator<<(std::ostream &os,const EVENT& x)
1130{
1131 os << std::endl << "{ EVENT" << std::endl;
1132 if(x.initialized()) {
1133 os << " " << x.header;
1134 os << " " << x.decayMode;
1135 os << " " << x.trackTruth;
1136 os << " " << x.vertexTruth;
1137 os << " " << x.mdcTruth;
1138 os << " " << x.mdcDigi;
1139 os << " " << x.cgemTruth;
1140 os << " " << x.cgemDigi;
1141 os << " " << x.tofTruth;
1142 os << " " << x.tofDigi;
1143 os << " " << x.emcTruth;
1144 os << " " << x.emcDigi;
1145 os << " " << x.mucTruth;
1146 os << " " << x.mucDigi;
1147 }
1148 os << std::endl << "} EVENT" << std::endl;
1149 return os;
1150}
1151
1152std::istream& operator>>(std::istream& is, HitEVENT& x)
1153{
1154 x.check_start_tag(is,"HITEVENT");
1155 if(!x.initialized()) return is;
1156
1157 try {
1158 is >> x.header;
1159 } catch(AsciiDumpException& ) {
1160 std::cerr << "Got AsciiDumpException eror while reading header block !!!" << std::endl;
1161 }
1162
1163 try {
1164 is >> x.decayMode;
1165 } catch(AsciiDumpException& ) {
1166 std::cerr << "Got AsciiDumpException eror while reading decay mode block !!!" << std::endl;
1167 }
1168
1169 try {
1170 is >> x.trackTruth;
1171 } catch(AsciiDumpException& ) {
1172 std::cerr << "Got AsciiDumpException eror while reading track truth block !!!" << std::endl;
1173 }
1174
1175 try {
1176 is >> x.vertexTruth;
1177 } catch (AsciiDumpException& ) {
1178 std::cerr << "Got AsciiDumpException eror while reading vertex truth block !!!" << std::endl;
1179 }
1180
1181 try {
1182 is >> x.mdcTruth;
1183 } catch (AsciiDumpException& ) {
1184 std::cerr << "Got AsciiDumpException eror while reading mdc truth block !!!" << std::endl;
1185 }
1186
1187 try {
1188 is >> x.mdcHit;
1189 } catch (AsciiDumpException& ) {
1190 std::cerr << "Got AsciiDumpException eror while reading mdc hit block !!!" << std::endl;
1191 }
1192
1193 try {
1194 is >> x.cgemTruth;
1195 } catch (AsciiDumpException& ) {
1196 std::cerr << "Got AsciiDumpException eror while reading cgem truth block !!!" << std::endl;
1197 }
1198
1199 try {
1200 is >> x.cgemHit;
1201 } catch (AsciiDumpException& ) {
1202 std::cerr << "Got AsciiDumpException eror while reading cgem hit block !!!" << std::endl;
1203 }
1204
1205 try {
1206 is >> x.tofTruth;
1207 } catch (AsciiDumpException& ) {
1208 std::cerr << "Got AsciiDumpException eror while reading tof truth block !!!" << std::endl;
1209 }
1210
1211 try {
1212 is >> x.tofHit;
1213 } catch (AsciiDumpException& ) {
1214 std::cerr << "Got AsciiDumpException eror while reading tof hiti block !!!" << std::endl;
1215 }
1216
1217 try {
1218 is >> x.emcTruth;
1219 } catch (AsciiDumpException& ) {
1220 std::cerr << "Got AsciiDumpException eror while reading emc truth block !!!" << std::endl;
1221 }
1222
1223 try {
1224 is >> x.emcHit;
1225 } catch (AsciiDumpException& ) {
1226 std::cerr << "Got AsciiDumpException eror while reading emc hit block !!!" << std::endl;
1227 }
1228
1229 try {
1230 is >> x.mucTruth;
1231 } catch (AsciiDumpException& ) {
1232 std::cerr << "Got AsciiDumpException eror while reading muc truth block !!!" << std::endl;
1233 }
1234
1235 try {
1236 is >> x.mucHit;
1237 } catch (AsciiDumpException& ) {
1238 std::cerr << "Got AsciiDumpException eror while reading muc hit block !!!" << std::endl;
1239 }
1240 x.check_end_tag(is, "HITEVENT");
1241 return is;
1242}
1243
1244std::ostream& operator<<(std::ostream &os,const HitEVENT& x)
1245{
1246 os << std::endl << "{ HITEVENT" << std::endl;
1247 if(x.initialized()) {
1248 os << " " << x.header;
1249 os << " " << x.decayMode;
1250 os << " " << x.trackTruth;
1251 os << " " << x.vertexTruth;
1252 os << " " << x.mdcTruth;
1253 os << " " << x.mdcHit;
1254 os << " " << x.cgemTruth;
1255 os << " " << x.cgemHit;
1256 os << " " << x.tofTruth;
1257 os << " " << x.tofHit;
1258 os << " " << x.emcTruth;
1259 os << " " << x.emcHit;
1260 os << " " << x.mucTruth;
1261 os << " " << x.mucHit;
1262 }
1263 os << std::endl << "} HITEVENT" << std::endl;
1264 return os;
1265}
1266
std::istream & operator>>(std::istream &is, FRMTVERSION &x)
Definition: AsciiData.cc:6
std::ostream & operator<<(std::ostream &os, const FRMTVERSION &x)
Definition: AsciiData.cc:16
Double_t x[10]