CMS 3D CMS Logo

Public Member Functions | Private Member Functions | Friends

LMFCorrCoefDatComponent Class Reference

#include <LMFCorrCoefDatComponent.h>

Inheritance diagram for LMFCorrCoefDatComponent:
LMFDat LMFUnique IUniqueDBObject IDBObject

List of all members.

Public Member Functions

std::string foreignKeyName () const
int getFlag (const EcalLogicID &id)
std::string getIovIdFieldName () const
LMFLmrSubIOV getLMFLmrSubIOV () const
int getLMFLmrSubIOVID () const
std::vector< float > getParameterErrors (int id)
std::vector< float > getParameterErrors (const EcalLogicID &id)
std::vector< float > getParameters (int id)
std::vector< float > getParameters (const EcalLogicID &id)
int getSeqID (const EcalLogicID &id)
int getSeqID (int id)
LMFSeqDat getSequence (const EcalLogicID &id)
std::string getTableName () const
 LMFCorrCoefDatComponent (EcalDBConnection *c)
 LMFCorrCoefDatComponent ()
 LMFCorrCoefDatComponent (oracle::occi::Environment *env, oracle::occi::Connection *conn)
LMFCorrCoefDatComponentsetFlag (const EcalLogicID &id, int flag)
LMFCorrCoefDatComponentsetLMFLmrSubIOV (const LMFLmrSubIOV &iov)
LMFCorrCoefDatComponentsetP123 (const EcalLogicID &id, float p1, float p2, float p3)
LMFCorrCoefDatComponentsetP123 (const EcalLogicID &id, float p1, float p2, float p3, float p1e, float p2e, float p3e)
LMFCorrCoefDatComponentsetP123Errors (const EcalLogicID &id, float p1e, float p2e, float p3e)
LMFCorrCoefDatComponentsetSequence (const EcalLogicID &id, const LMFSeqDat &seq)
LMFCorrCoefDatComponentsetSequence (const EcalLogicID &id, int seq_id)
int writeDB () throw (std::runtime_error)
 ~LMFCorrCoefDatComponent ()

Private Member Functions

void init ()

Friends

class EcalCondDBInterface

Detailed Description

Definition at line 21 of file LMFCorrCoefDatComponent.h.


Constructor & Destructor Documentation

LMFCorrCoefDatComponent::LMFCorrCoefDatComponent ( )

Definition at line 4 of file LMFCorrCoefDatComponent.cc.

References init().

                                                 : LMFDat() {
  init();
}
LMFCorrCoefDatComponent::LMFCorrCoefDatComponent ( EcalDBConnection c)

Definition at line 8 of file LMFCorrCoefDatComponent.cc.

References init().

                                                                    : LMFDat(c) {
  init();
}
LMFCorrCoefDatComponent::LMFCorrCoefDatComponent ( oracle::occi::Environment *  env,
oracle::occi::Connection *  conn 
)

Definition at line 12 of file LMFCorrCoefDatComponent.cc.

References init().

                                                          : 
  LMFDat(env, conn) {
  init();
}
LMFCorrCoefDatComponent::~LMFCorrCoefDatComponent ( ) [inline]

Definition at line 29 of file LMFCorrCoefDatComponent.h.

{};

Member Function Documentation

std::string LMFCorrCoefDatComponent::foreignKeyName ( ) const [virtual]

Reimplemented from LMFDat.

Definition at line 33 of file LMFCorrCoefDatComponent.cc.

Referenced by getLMFLmrSubIOV(), getLMFLmrSubIOVID(), and setLMFLmrSubIOV().

                                                        {
  return "lmfLmrSubIOV";
}
int LMFCorrCoefDatComponent::getFlag ( const EcalLogicID id)

Definition at line 134 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData().

                                                          {
  return getData(id, "FLAG");
}
std::string LMFCorrCoefDatComponent::getIovIdFieldName ( ) const [virtual]

Reimplemented from LMFDat.

Definition at line 41 of file LMFCorrCoefDatComponent.cc.

                                                           {
  return "LMR_SUB_IOV_ID";
}
LMFLmrSubIOV LMFCorrCoefDatComponent::getLMFLmrSubIOV ( ) const
int LMFCorrCoefDatComponent::getLMFLmrSubIOVID ( ) const

Definition at line 98 of file LMFCorrCoefDatComponent.cc.

References foreignKeyName(), and LMFUnique::getInt().

                                                     {
  return getInt(foreignKeyName());
}
std::vector< float > LMFCorrCoefDatComponent::getParameterErrors ( const EcalLogicID id)

Definition at line 118 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData(), and findQualityFiles::v.

                                                                                   {
  std::vector<float> v;
  v.push_back(getData(id, "P1E"));
  v.push_back(getData(id, "P2E"));
  v.push_back(getData(id, "P3E"));
  return v;
}
std::vector< float > LMFCorrCoefDatComponent::getParameterErrors ( int  id)

Definition at line 126 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData(), and findQualityFiles::v.

                                                                    {
  std::vector<float> v;
  v.push_back(getData(id, "P1E"));
  v.push_back(getData(id, "P2E"));
  v.push_back(getData(id, "P3E"));
  return v;
}
std::vector< float > LMFCorrCoefDatComponent::getParameters ( const EcalLogicID id)

Definition at line 102 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData(), and findQualityFiles::v.

                                                                              {
  std::vector<float> v;
  v.push_back(getData(id, "P1"));
  v.push_back(getData(id, "P2"));
  v.push_back(getData(id, "P3"));
  return v;
}
std::vector< float > LMFCorrCoefDatComponent::getParameters ( int  id)

Definition at line 110 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData(), and findQualityFiles::v.

                                                               {
  std::vector<float> v;
  v.push_back(getData(id, "P1"));
  v.push_back(getData(id, "P2"));
  v.push_back(getData(id, "P3"));
  return v;
}
int LMFCorrCoefDatComponent::getSeqID ( int  id)

Definition at line 142 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData().

                                            {
  return getData(id, "SEQ_ID");
}
int LMFCorrCoefDatComponent::getSeqID ( const EcalLogicID id)

Definition at line 138 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData().

                                                           {
  return getData(id, "SEQ_ID");
}
LMFSeqDat LMFCorrCoefDatComponent::getSequence ( const EcalLogicID id)

Definition at line 146 of file LMFCorrCoefDatComponent.cc.

References LMFDat::getData(), IDBObject::m_conn, IDBObject::m_env, and LMFUnique::setByID().

                                                                    {
  int seq_id = getData(id, "SEQ_ID");
  LMFSeqDat seq(m_env, m_conn);
  seq.setByID(seq_id);
  return seq;
}
std::string LMFCorrCoefDatComponent::getTableName ( ) const [virtual]

Reimplemented from LMFDat.

Definition at line 37 of file LMFCorrCoefDatComponent.cc.

                                                      {
  return "LMF_CORR_COEF_DAT";
}
void LMFCorrCoefDatComponent::init ( void  ) [private]

Definition at line 18 of file LMFCorrCoefDatComponent.cc.

References i, LMFUnique::m_className, LMFDat::m_keys, and LMFDat::m_type.

Referenced by LMFCorrCoefDatComponent().

                                   {
  m_className = "LMFCorrCoefDatComponent";
  m_keys["P1"] = 0;
  m_keys["P2"] = 1;
  m_keys["P3"] = 2;
  m_keys["P1E"] = 3;
  m_keys["P2E"] = 4;
  m_keys["P3E"] = 5;
  m_keys["FLAG"] = 6;
  m_keys["SEQ_ID"] = 7;
  for (unsigned int i = 0; i < m_keys.size(); i++) {
    m_type.push_back("NUMBER");
  }
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setFlag ( const EcalLogicID id,
int  flag 
)

Definition at line 75 of file LMFCorrCoefDatComponent.cc.

References LMFDat::setData().

Referenced by LMFCorrCoefDat::setFlag().

                                                                                         {
  LMFDat::setData(id, "FLAG", flag);
  return *this;
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setLMFLmrSubIOV ( const LMFLmrSubIOV iov)
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setP123 ( const EcalLogicID id,
float  p1,
float  p2,
float  p3 
)

Definition at line 51 of file LMFCorrCoefDatComponent.cc.

References LMFDat::setData().

Referenced by LMFCorrCoefDat::setP123(), and setP123().

                                                                      {
  LMFDat::setData(id, "P1", p1);
  LMFDat::setData(id, "P2", p2);
  LMFDat::setData(id, "P3", p3);
  return *this;
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setP123 ( const EcalLogicID id,
float  p1,
float  p2,
float  p3,
float  p1e,
float  p2e,
float  p3e 
)

Definition at line 59 of file LMFCorrCoefDatComponent.cc.

References setP123(), and setP123Errors().

                                                                         {
  setP123(id, p1, p2, p3);
  setP123Errors(id, p1e, p2e, p3e);
  return *this;
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setP123Errors ( const EcalLogicID id,
float  p1e,
float  p2e,
float  p3e 
)

Definition at line 67 of file LMFCorrCoefDatComponent.cc.

References LMFDat::setData().

Referenced by setP123(), and LMFCorrCoefDat::setP123Errors().

                                                                               {
  LMFDat::setData(id, "P1E", p1e);
  LMFDat::setData(id, "P2E", p2e);
  LMFDat::setData(id, "P3E", p3e);
  return *this;
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setSequence ( const EcalLogicID id,
int  seq_id 
)

Definition at line 80 of file LMFCorrCoefDatComponent.cc.

References LMFDat::setData().

Referenced by LMFCorrCoefDat::setSequence().

                                                                          {
  LMFDat::setData(id, "SEQ_ID", seq_id);
  return *this;
}
LMFCorrCoefDatComponent & LMFCorrCoefDatComponent::setSequence ( const EcalLogicID id,
const LMFSeqDat seq 
)

Definition at line 86 of file LMFCorrCoefDatComponent.cc.

References LMFUnique::getID(), and LMFDat::setData().

                                                                                    {
  LMFDat::setData(id, "SEQ_ID", seq.getID());
  return *this;
}
int LMFCorrCoefDatComponent::writeDB ( ) throw (std::runtime_error) [virtual]

Reimplemented from LMFDat.

Definition at line 153 of file LMFCorrCoefDatComponent.cc.

References alignCSCRings::e, IDBObject::m_conn, and run_regression::ret.

                          {
  int ret = 0;
  try {
    ret = LMFDat::writeDB();
  }
  catch (std::runtime_error &e) {
    m_conn->rollback();
    throw(e);
  }
  return ret;
}

Friends And Related Function Documentation

friend class EcalCondDBInterface [friend]

Reimplemented from LMFDat.

Definition at line 23 of file LMFCorrCoefDatComponent.h.