#include #include #include "Stntuple/obj/TXftBlock.hh" ClassImp(TXftBlock) //______________________________________________________________________________ void TXftBlock::Streamer(TBuffer &R__b) { // Stream an object of class TXftBlock. if (R__b.IsReading()) { Version_t R__v = R__b.ReadVersion(); if (R__v) { } R__b >> fNxftHits; if (fNxftHits > 0) { fXftHitList->Streamer(R__b); } R__b >> fNxftPixels; if (fNxftPixels > 0) { fXftPixelList->Streamer(R__b); } R__b >> fNxftTracks; if (fNxftTracks > 0) { fXftTrackList->Streamer(R__b); } } else { //----------------------------------------------------------------------------- // output section //----------------------------------------------------------------------------- R__b.WriteVersion(TXftBlock::IsA()); R__b << fNxftHits; if (fNxftHits > 0) { fXftHitList->Streamer(R__b); } R__b << fNxftPixels; if (fNxftPixels > 0) { fXftPixelList->Streamer(R__b); } R__b << fNxftTracks; if (fNxftTracks > 0) { fXftTrackList->Streamer(R__b); } } } //_____________________________________________________________________________ TXftBlock::TXftBlock() { fNxftHits = 0; fXftHitList = new TClonesArray("TXftHit",200); fXftHitList->BypassStreamer(kFALSE); fNxftPixels = 0; fXftPixelList = new TClonesArray("TXftPixel",200); fXftPixelList->BypassStreamer(kFALSE); fNxftTracks = 0; fXftTrackList = new TClonesArray("TXftTrack",100); fXftTrackList->BypassStreamer(kFALSE); fStoreHits = 0; fStorePixels = 1; fStoreTracks = 1; } //_____________________________________________________________________________ TXftBlock::~TXftBlock() { fXftHitList->Delete(); delete fXftHitList; fXftPixelList->Delete(); delete fXftPixelList; fXftTrackList->Delete(); delete fXftTrackList; } //_____________________________________________________________________________ void TXftBlock::Clear(Option_t* opt) { fNxftHits = 0; fXftHitList->Clear(opt); fNxftPixels = 0; fXftPixelList->Clear(opt); fNxftTracks = 0; fXftTrackList->Clear(opt); } //------------------------------------------------------------------------------ void TXftBlock::Print(Option_t* opt) const { printf(" ******************** TXftBlock::Print N(xft hits) = %5i\n",fNxftHits); printf(" i Prompt Delayed Sl AbsCell LocalCell Crate Board Chip \n"); TXftBlock* block = (TXftBlock*) this; for (int i=0; iXftHit(i); printf("%5i %5i %5i %5i %5i %5i %5i %5i %5i \n", i, h->hPrompt, h->hDelayed, h->hSl, h->hAbsCell, h->hLocalCell, h->hCrate, h->hBoard, h->hChip ); // } } printf(" ******************** TXftBlock::Print N(xft pixels) = %5i\n",fNxftPixels); printf(" i Sl AbsPix Crate Board Chip LocPix LocCell \n"); for (int i=0; iXftPixel(i); printf("%5i %5i %5i %5i %5i %5i %5i %5i \n", i, p->pSl, p->pAbsPix, p->pCrate, p->pBoard, p->pChip, p->pLocalPix, p->pLocalCell ); // } } printf(" ******************** TXftBlock::Print N(xft trackss) = %5i\n",fNxftTracks); printf(" i Prompt Delayed Sl AbsCell LocalCell Crate Board Chip \n"); for (int i=0; iXftTrack(i); printf("%5i %5i %5i %5i %5i %5i %5i %5i %9.3f %9.3f \n", i, t->ptBin, t->miniPhi, t->shortBit, t->isolationBit, t->linkerCrate, t->linkerBoard, t->linkerChip, t->absPhi, t->ptVal ); // } } }