CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Functions | Variables
LaserSorter.cc File Reference
#include "CalibCalorimetry/EcalLaserSorting/interface/LaserSorter.h"
#include "CalibCalorimetry/EcalLaserSorting/src/Majority.h"
#include <iostream>
#include <iomanip>
#include <algorithm>
#include <sys/stat.h>
#include <sys/types.h>
#include <unistd.h>
#include <errno.h>
#include "FWCore/ParameterSet/interface/ParameterSet.h"
#include "FWCore/Framework/interface/Event.h"
#include "FWCore/Framework/interface/EventSetup.h"
#include "FWCore/MessageLogger/interface/MessageLogger.h"
#include "DataFormats/Provenance/interface/EventID.h"
#include "DataFormats/FEDRawData/interface/FEDRawData.h"
#include "DataFormats/FEDRawData/interface/FEDNumbering.h"
#include "DataFormats/FEDRawData/interface/FEDRawDataCollection.h"
#include "DataFormats/Provenance/interface/LuminosityBlockID.h"
#include "DataFormats/Provenance/interface/Timestamp.h"

Go to the source code of this file.

Functions

static std::string now ()
 

Variables

static const char *const colorNames []
 
static const char *const detailedTrigNames []
 
static const int laserTrigger = 4
 
static const int ledTrigger = 5
 
static const int pedTrigger = 7
 
static const int tpTrigger = 6
 

Function Documentation

static std::string now ( )
static

Definition at line 71 of file LaserSorter.cc.

Referenced by LaserSorter::analyze(), LaserSorter::closeOldStreams(), LaserSorter::closeOutStream(), LaserSorter::createOutStream(), LaserSorter::getDetailedTriggerType(), LaserSorter::getStream(), LaserSorter::LaserSorter(), LaserSorter::readIndexTable(), LaserSorter::streamFileName(), LaserSorter::writeEventHeader(), and LaserSorter::writeFedBlock().

71  {
72  struct timeval t;
73  gettimeofday(&t, 0);
74 
75  char buf[256];
76  strftime(buf, sizeof(buf), "%F %R %S s", localtime(&t.tv_sec));
77  buf[sizeof(buf)-1] = 0;
78 
79  stringstream buf2;
80  buf2 << buf << " " << ((t.tv_usec+500)/1000) << " ms";
81 
82  return buf2.str();
83 }

Variable Documentation

const char* const colorNames[]
static
Initial value:
= {
"Blue",
"Green",
"Red",
"IR"
}

Definition at line 61 of file LaserSorter.cc.

Referenced by LaserSorter::analyze(), and LaserSorter::writeEventHeader().

const char* const detailedTrigNames[]
static
Initial value:
= {
"Inv0",
"Inv1",
"Inv2",
"Inv3",
"Las",
"Led",
"TP",
"Ped"
}

Definition at line 50 of file LaserSorter.cc.

Referenced by LaserSorter::analyze(), and LaserSorter::writeEventHeader().

const int laserTrigger = 4
static

Definition at line 43 of file LaserSorter.cc.

const int ledTrigger = 5
static

Definition at line 44 of file LaserSorter.cc.

const int pedTrigger = 7
static

Definition at line 46 of file LaserSorter.cc.

const int tpTrigger = 6
static

Definition at line 45 of file LaserSorter.cc.