#include "DataFormats/Scalers/interface/LumiScalers.h"
#include "DataFormats/Scalers/interface/ScalersRaw.h"
#include <cstdio>
#include <ostream>
Go to the source code of this file.
Functions | |
std::ostream & | operator<< (std::ostream &s, const LumiScalers &c) |
Pretty-print operator for LumiScalers. |
std::ostream& operator<< | ( | std::ostream & | s, |
const LumiScalers & | c | ||
) |
Pretty-print operator for LumiScalers.
Definition at line 112 of file LumiScalers.cc.
References LumiScalers::bunchNumber(), LumiScalers::collectionTime(), LumiScalers::deadTimeNormalization(), LumiScalers::eventID(), i, LumiScalers::instantETLumi(), LumiScalers::instantETLumiErr(), LumiScalers::instantETLumiQlty(), LumiScalers::instantLumi(), LumiScalers::instantLumiErr(), LumiScalers::instantLumiQlty(), LumiScalers::instantOccLumi(), LumiScalers::instantOccLumiErr(), LumiScalers::instantOccLumiQlty(), geometryCSVtoXML::line, LumiScalers::liveLumiETFill(), LumiScalers::liveLumiETRun(), LumiScalers::liveLumiFill(), LumiScalers::liveLumiOccFill(), LumiScalers::liveLumiOccRun(), LumiScalers::liveLumiRun(), LumiScalers::lumiFill(), LumiScalers::lumiNoise(), LumiScalers::lumiOccFill(), LumiScalers::lumiOccRun(), LumiScalers::lumiRun(), LumiScalers::normalization(), LumiScalers::numOrbits(), asciidump::s, LumiScalers::sectionNumber(), LumiScalers::sourceID(), LumiScalers::startOrbit(), LumiScalers::trigType(), and LumiScalers::version().
{ char zeit[128]; char line[128]; struct tm * hora; s << "LumiScalers Version: " << c.version() << " SourceID: "<< c.sourceID() << std::endl; timespec ts = c.collectionTime(); hora = gmtime(&ts.tv_sec); strftime(zeit, sizeof(zeit), "%Y.%m.%d %H:%M:%S", hora); sprintf(line, " CollectionTime: %s.%9.9d", zeit, (int)ts.tv_nsec); s << line << std::endl; sprintf(line, " TrigType: %d EventID: %d BunchNumber: %d", c.trigType(), c.eventID(), c.bunchNumber()); s << line << std::endl; sprintf(line," SectionNumber: %10d StartOrbit: %10d NumOrbits: %10d", c.sectionNumber(), c.startOrbit(), c.numOrbits()); s << line << std::endl; sprintf(line," Normalization: %e DeadTimeNormalization: %e", c.normalization(), c.deadTimeNormalization()); s << line << std::endl; // Integrated Luminosity sprintf(line," LumiFill: %e LumiRun: %e", c.lumiFill(), c.lumiRun()); s << line << std::endl; sprintf(line," LiveLumiFill: %e LiveLumiRun: %e", c.liveLumiFill(), c.liveLumiRun()); s << line << std::endl; sprintf(line," LumiETFill: %e LumiETRun: %e", c.lumiFill(), c.lumiRun()); s << line << std::endl; sprintf(line," LiveLumiETFill: %e LiveLumETiRun: %e", c.liveLumiETFill(), c.liveLumiETRun()); s << line << std::endl; int length = c.instantOccLumi().size(); for (int i=0; i<length; i++) { sprintf(line, " LumiOccFill[%d]: %e LumiOccRun[%d]: %e", i, c.lumiOccFill()[i], i, c.lumiOccRun()[i]); s << line << std::endl; sprintf(line, " LiveLumiOccFill[%d]: %e LiveLumiOccRun[%d]:v %e", i, c.liveLumiOccFill()[i], i, c.liveLumiOccRun()[i]); s << line << std::endl; } // Instantaneous Luminosity sprintf(line," InstantLumi: %e Err: %e Qlty: %d", c.instantLumi(), c.instantLumiErr(), c.instantLumiQlty()); s << line << std::endl; sprintf(line," InstantETLumi: %e Err: %e Qlty: %d", c.instantETLumi(), c.instantETLumiErr(), c.instantETLumiQlty()); s << line << std::endl; for (int i=0; i<length; i++) { sprintf(line," InstantOccLumi[%d]: %e Err: %e Qlty: %d", i, c.instantOccLumi()[i], c.instantOccLumiErr()[i], c.instantOccLumiQlty()[i]); s << line << std::endl; sprintf(line," LumiNoise[%d]: %e", i, c.lumiNoise()[i]); s << line << std::endl; } return s; }