FloatParamIndex

IntParamIndex

LHCInfoPerLS

TimeParamIndex

Macros

Line Code
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74
#ifndef CondFormats_RunInfo_LHCInfoPerLS_H
#define CondFormats_RunInfo_LHCInfoPerLS_H

#include "CondFormats/Serialization/interface/Serializable.h"
#include "CondFormats/RunInfo/interface/LHCInfoVectorizedFields.h"

#include "CondCore/CondDB/interface/Types.h"

#include <bitset>
#include <iostream>
#include <string>
#include <sstream>
#include <vector>

class LHCInfoPerLS : public LHCInfoVectorizedFields {
public:
  enum IntParamIndex { LHC_FILL = 0, LUMI_SECTION, ISIZE };
  enum FloatParamIndex { CROSSING_ANGLE_X = 0, CROSSING_ANGLE_Y, BETA_STAR_X, BETA_STAR_Y, FSIZE };
  enum TimeParamIndex { RUN_NUMBER = 0, TSIZE };

  LHCInfoPerLS();

  //getters
  unsigned short const fillNumber() const;

  unsigned int const& lumiSection() const;

  float const crossingAngleX() const;

  float const crossingAngleY() const;

  float const betaStarX() const;

  float const betaStarY() const;

  cond::Time_t runNumber() const;

  //setters
  void setFillNumber(unsigned short const& lhcFill);

  void setLumiSection(unsigned int const& lumiSection);

  void setCrossingAngleX(float const& angle);

  void setCrossingAngleY(float const& angle);

  void setBetaStarX(float const& betaStar);

  void setBetaStarY(float const& betaStar);

  void setRunNumber(cond::Time_t const& runNumber);

  //sets all values in one go
  void setInfo(unsigned short const& lhcFill,
               unsigned int const& lumiSection,
               float const& angleX,
               float const& angleY,
               float const& betaX,
               float const& betaY,
               cond::Time_t const& runNumber);

  bool equals(const LHCInfoPerLS& rhs) const;

  bool empty() const;

  //dumping values on output stream
  void print(std::stringstream& ss) const;

  COND_SERIALIZABLE;
};

std::ostream& operator<<(std::ostream&, LHCInfoPerLS lhcInfo);

#endif  // CondFormats_RunInfo_LHCInfoPerLS_H