16 if(channel ==
nullptr) {
23 if(detClass ==
nullptr) {
28 GetDetector(detClass,
true)->AddFragment(frag, channel);
55 if(det->IsA() == cls) {
60 if(make_if_not_found) {
61 std::shared_ptr<TDetector> output(
static_cast<TDetector*
>(cls->New()));
69std::ostringstream TUnpackedEvent::Print()
71 std::ostringstream str;
72 str <<
fDetectors.size() <<
" detector types:" << std::endl;
74 str <<
"detector type " << det->ClassName() << std::endl;
75 for(
int i = 0; i < det->GetMultiplicity(); ++i) {
76 auto hit = det->GetHit(i);
77 str << hit <<
" " <<
hex(hit->GetAddress(), 4) <<
" " << std::setw(16) << hit->GetTimeStamp() <<
" " << std::setw(16) <<
static_cast<int>(hit->Charge()) <<
" " << std::setw(16) << hit->GetEnergy() << std::endl;
std::string hex(T val, int width=-1)
static TChannel * GetChannel(unsigned int temp_address, bool warn=false)
TClass * GetClassType() const
static TSortingDiagnostics * Get(bool verbose=false)
void MissingChannel(const UInt_t &address)
void AddDetectorClass(TChannel *)
std::vector< std::shared_ptr< TDetector > > fDetectors
std::shared_ptr< T > GetDetector(bool make_if_not_found=false)
void AddRawData(const std::shared_ptr< const TFragment > &frag)
std::vector< std::shared_ptr< const TFragment > > fFragments