CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
List of all members | Public Types | Public Member Functions | Private Member Functions
LMFClsDat Class Reference

#include <LMFClsDat.h>

Inheritance diagram for LMFClsDat:
LMFColoredTable LMFDat LMFUnique IUniqueDBObject IDBObject

Public Types

typedef oracle::occi::ResultSet ResultSet
 
typedef oracle::occi::Statement Statement
 
- Public Types inherited from LMFUnique
typedef oracle::occi::ResultSet ResultSet
 
typedef oracle::occi::Statement Statement
 

Public Member Functions

float getENorm (EcalLogicID &id)
 
int getFlag (EcalLogicID &id)
 
float getFlagNorm (EcalLogicID &id)
 
int getLMFRefRunIOVID (EcalLogicID &id)
 
float getMean (EcalLogicID &id)
 
int getNevt (EcalLogicID &id)
 
float getNorm (EcalLogicID &id)
 
float getRMS (EcalLogicID &id)
 
std::string getSystem () const
 
std::string getTableName () const
 
bool isValid ()
 
 LMFClsDat ()
 
 LMFClsDat (oracle::occi::Environment *env, oracle::occi::Connection *conn)
 
 LMFClsDat (EcalDBConnection *c)
 
 LMFClsDat (std::string color)
 
 LMFClsDat (int color)
 
 LMFClsDat (oracle::occi::Environment *env, oracle::occi::Connection *conn, std::string color)
 
 LMFClsDat (EcalDBConnection *c, std::string color)
 
 LMFClsDat (oracle::occi::Environment *env, oracle::occi::Connection *conn, int color)
 
 LMFClsDat (EcalDBConnection *c, int color)
 
LMFClsDatsetENorm (EcalLogicID &id, float v)
 
LMFClsDatsetFlag (EcalLogicID &id, int v)
 
LMFClsDatsetFlagNorm (EcalLogicID &id, float v)
 
LMFClsDatsetLMFRefRunIOVID (EcalLogicID &id, int v)
 
LMFClsDatsetMean (EcalLogicID &id, float v)
 
LMFClsDatsetNevt (EcalLogicID &id, int v)
 
LMFClsDatsetNorm (EcalLogicID &id, float v)
 
LMFClsDatsetRMS (EcalLogicID &id, float v)
 
LMFClsDatsetSystem (int system)
 
LMFClsDatsetSystem (std::string system)
 
 ~LMFClsDat ()
 
- Public Member Functions inherited from LMFColoredTable
std::string getColor () const
 
int getVmax (EcalLogicID &id)
 
int getVmin (EcalLogicID &id)
 
 LMFColoredTable ()
 
 LMFColoredTable (EcalDBConnection *c)
 
 LMFColoredTable (oracle::occi::Environment *env, oracle::occi::Connection *conn)
 
LMFColoredTablesetColor (int color)
 
LMFColoredTablesetColor (std::string color)
 
LMFColoredTablesetVersions (EcalLogicID &id, int vmin, int vmax)
 
LMFColoredTablesetVmax (EcalLogicID &id, int v)
 
LMFColoredTablesetVmin (EcalLogicID &id, int v)
 
int writeDB () throw (std::runtime_error)
 
 ~LMFColoredTable ()
 
- Public Member Functions inherited from LMFDat
void dump () const
 
void dump (int n) const
 
virtual void dump (int n, int max) const
 
void fetch () throw (std::runtime_error)
 
void fetch (int logic_id) throw (std::runtime_error)
 
void fetch (int logic_id, const Tm &tm) throw (std::runtime_error)
 
void fetch (int logic_id, const Tm *timestamp, int dir) throw (std::runtime_error)
 
void fetch (const EcalLogicID &id, const Tm &tm) throw (std::runtime_error)
 
void fetch (const EcalLogicID &id, const Tm &tm, int dir) throw (std::runtime_error)
 
void fetch (const EcalLogicID &id) throw (std::runtime_error)
 
std::map< int, std::vector
< float > > 
fetchData () throw (std::runtime_error)
 
virtual std::string foreignKeyName () const
 
std::vector< float > getData (int id)
 
std::vector< float > getData (const EcalLogicID &id)
 
bool getData (int id, std::vector< float > &ret)
 
bool getData (const EcalLogicID &id, std::vector< float > &ret)
 
std::map< int, std::vector
< float > > 
getData ()
 
float getData (int id, unsigned int k)
 
float getData (const EcalLogicID &id, unsigned int k)
 
float getData (const EcalLogicID &id, const std::string &key)
 
float getData (int id, const std::string &key)
 
bool getData (int id, unsigned int k, float &ret)
 
bool getData (const EcalLogicID &id, unsigned int k, float &ret)
 
bool getData (int id, const std::string &key, float &ret)
 
bool getData (const EcalLogicID &id, const std::string &key, float &ret)
 
virtual std::string getIovIdFieldName () const
 
std::list< std::string > getKeyList ()
 
std::map< std::string,
unsigned int > 
getKeys ()
 
LMFRunIOV getLMFRunIOV () const
 
int getLMFRunIOVID ()
 
std::list< int > getLogicIds ()
 
void getNext (LMFDat *dat) throw (std::runtime_error)
 
void getPrevious (LMFDat *dat) throw (std::runtime_error)
 
std::map< unsigned int,
std::string > 
getReverseMap () const
 
Tm getSubrunStart () const
 
 LMFDat ()
 
 LMFDat (EcalDBConnection *c)
 
 LMFDat (oracle::occi::Environment *env, oracle::occi::Connection *conn)
 
std::vector< float > operator[] (int id)
 
LMFDatsetData (int logic_id, const std::vector< float > &data)
 
LMFDatsetData (const EcalLogicID &logic_id, const std::vector< float > &data)
 
LMFDatsetData (const EcalLogicID &logic_id, const std::string &key, float v)
 
LMFDatsetLMFRunIOV (const LMFRunIOV &iov)
 
LMFDatsetMaxDataToDump (int n)
 
void setWhereClause (std::string w)
 
void setWhereClause (std::string w, const std::vector< std::string > &p)
 
int size () const
 
 ~LMFDat ()
 
- Public Member Functions inherited from LMFUnique
void attach (std::string name, LMFUnique *u)
 
void debug ()
 
virtual bool exists ()
 
virtual boost::ptr_list
< LMFUnique
fetchAll () const throw (std::runtime_error)
 
int fetchID () throw (std::runtime_error)
 
std::string getClassName ()
 
std::string getClassName () const
 
int getID () const
 
int getInt (std::string fieldname) const
 
std::string getString (std::string fieldname) const
 
virtual bool isValid () const
 
 LMFUnique ()
 
 LMFUnique (oracle::occi::Environment *env, oracle::occi::Connection *conn)
 
 LMFUnique (EcalDBConnection *c)
 
void nodebug ()
 
virtual bool operator< (const LMFUnique &r)
 
virtual bool operator<= (const LMFUnique &r)
 
std::string sequencePostfix (const Tm &t)
 
void setByID (int id) throw (std::runtime_error)
 
LMFUniquesetInt (std::string key, int value)
 
LMFUniquesetString (std::string key, std::string value)
 
void startProfiling ()
 
void stopProfiling ()
 
virtual ~LMFUnique ()
 
- Public Member Functions inherited from IDBObject
oracle::occi::Connection * getConn () const
 
oracle::occi::Environment * getEnv () const
 
void setConnection (oracle::occi::Environment *env, oracle::occi::Connection *conn)
 
virtual ~IDBObject ()
 

Private Member Functions

void init ()
 

Additional Inherited Members

- Static Public Attributes inherited from IDBObject
static int const ECALDB_NROWS =1024
 
- Protected Member Functions inherited from LMFDat
void adjustParameters (int n, std::string &sql, Statement *stmt)
 
std::string buildInsertSql ()
 
std::string buildSelectSql (int logic_id=0, int direction=0)
 
bool check ()
 
void getKeyTypes () throw (std::runtime_error)
 
void getNeighbour (LMFDat *dat, int which) throw (std::runtime_error)
 
int writeDB () throw (std::runtime_error)
 
- Protected Member Functions inherited from LMFUnique
virtual void setClassName (std::string s)
 
virtual int writeForeignKeys () throw (std::runtime_error)
 
- Protected Member Functions inherited from IDBObject
void checkConnection () const throw (std::runtime_error)
 
- Protected Attributes inherited from LMFColoredTable
int m_color
 
int m_system
 
- Protected Attributes inherited from LMFDat
std::string _where
 
std::vector< std::string > _wherePars
 
std::map< int, std::vector
< float > > 
m_data
 
std::string m_Error
 
std::map< std::string,
unsigned int > 
m_keys
 
int m_max
 
std::string m_tableName
 
std::vector< std::string > m_type
 
- Protected Attributes inherited from LMFUnique
bool _profiling
 
std::string m_className
 
char m_debug
 
std::map< std::string,
LMFUnique * > 
m_foreignKeys
 
std::map< std::string, int > m_intFields
 
std::map< std::string,
std::string > 
m_stringFields
 
- Protected Attributes inherited from IUniqueDBObject
int m_ID
 
- Protected Attributes inherited from IDBObject
oracle::occi::Connection * m_conn
 
oracle::occi::Environment * m_env
 

Detailed Description

LMF_CLS_XXXX_DAT interface ^ | _____ color

Definition at line 18 of file LMFClsDat.h.

Member Typedef Documentation

typedef oracle::occi::ResultSet LMFClsDat::ResultSet

Definition at line 20 of file LMFClsDat.h.

typedef oracle::occi::Statement LMFClsDat::Statement

Definition at line 21 of file LMFClsDat.h.

Constructor & Destructor Documentation

LMFClsDat::LMFClsDat ( )

Definition at line 3 of file LMFClsDat.cc.

References init().

3  : LMFColoredTable() {
4  init();
5 }
void init()
Definition: LMFClsDat.cc:55
LMFClsDat::LMFClsDat ( oracle::occi::Environment *  env,
oracle::occi::Connection *  conn 
)

Definition at line 7 of file LMFClsDat.cc.

References init().

8  :
10  init();
11 }
void init()
Definition: LMFClsDat.cc:55
tuple conn
Definition: results_mgr.py:53
LMFClsDat::LMFClsDat ( EcalDBConnection c)

Definition at line 13 of file LMFClsDat.cc.

References init().

13  : LMFColoredTable(c) {
14  init();
15 }
void init()
Definition: LMFClsDat.cc:55
LMFClsDat::LMFClsDat ( std::string  color)

Definition at line 17 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

17  :
18  LMFColoredTable() {
19  init();
20  setColor(color);
21 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
LMFClsDat::LMFClsDat ( int  color)

Definition at line 23 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

23  :
24  LMFColoredTable() {
25  init();
26  setColor(color);
27 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
LMFClsDat::LMFClsDat ( oracle::occi::Environment *  env,
oracle::occi::Connection *  conn,
std::string  color 
)

Definition at line 29 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

31  :
33  init();
34  setColor(color);
35 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
tuple conn
Definition: results_mgr.py:53
LMFClsDat::LMFClsDat ( EcalDBConnection c,
std::string  color 
)

Definition at line 45 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

45  : LMFColoredTable(c) {
46  init();
47  setColor(color);
48 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
LMFClsDat::LMFClsDat ( oracle::occi::Environment *  env,
oracle::occi::Connection *  conn,
int  color 
)

Definition at line 37 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

39  :
41  init();
42  setColor(color);
43 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
tuple conn
Definition: results_mgr.py:53
LMFClsDat::LMFClsDat ( EcalDBConnection c,
int  color 
)

Definition at line 50 of file LMFClsDat.cc.

References init(), and LMFColoredTable::setColor().

50  : LMFColoredTable(c) {
51  init();
52  setColor(color);
53 }
void init()
Definition: LMFClsDat.cc:55
LMFColoredTable & setColor(int color)
LMFClsDat::~LMFClsDat ( )
inline

Definition at line 35 of file LMFClsDat.h.

35 {}

Member Function Documentation

float LMFClsDat::getENorm ( EcalLogicID id)

Definition at line 135 of file LMFClsDat.cc.

References LMFDat::getData().

135  {
136  return getData(id, "ENORM");
137 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
int LMFClsDat::getFlag ( EcalLogicID id)

Definition at line 147 of file LMFClsDat.cc.

References LMFDat::getData().

147  {
148  return getData(id, "FLAG");
149 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
float LMFClsDat::getFlagNorm ( EcalLogicID id)

Definition at line 151 of file LMFClsDat.cc.

References LMFDat::getData().

151  {
152  return getData(id, "FLAGNORM");
153 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
int LMFClsDat::getLMFRefRunIOVID ( EcalLogicID id)

Definition at line 123 of file LMFClsDat.cc.

References LMFDat::getData().

123  {
124  return getData(id, "LMF_IOV_ID_REF");
125 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
float LMFClsDat::getMean ( EcalLogicID id)

Definition at line 127 of file LMFClsDat.cc.

References LMFDat::getData().

127  {
128  return getData(id, "MEAN");
129 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
int LMFClsDat::getNevt ( EcalLogicID id)

Definition at line 143 of file LMFClsDat.cc.

References LMFDat::getData().

143  {
144  return getData(id, "NEVT");
145 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
float LMFClsDat::getNorm ( EcalLogicID id)

Definition at line 131 of file LMFClsDat.cc.

References LMFDat::getData().

131  {
132  return getData(id, "NORM");
133 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
float LMFClsDat::getRMS ( EcalLogicID id)

Definition at line 139 of file LMFClsDat.cc.

References LMFDat::getData().

139  {
140  return getData(id, "RMS");
141 }
std::map< int, std::vector< float > > getData()
Definition: LMFDat.cc:636
std::string LMFClsDat::getSystem ( ) const
inlinevirtual

Reimplemented from LMFColoredTable.

Definition at line 62 of file LMFClsDat.h.

62 { return ""; }
std::string LMFClsDat::getTableName ( ) const
inlinevirtual

Implements LMFColoredTable.

Definition at line 37 of file LMFClsDat.h.

References LMFColoredTable::getColor().

37  {
38  return "LMF_CLS_" + getColor() + "_DAT";
39  }
std::string getColor() const
void LMFClsDat::init ( void  )
private

Definition at line 55 of file LMFClsDat.cc.

References i, LMFUnique::m_className, LMFColoredTable::m_color, LMFDat::m_keys, LMFColoredTable::m_system, and LMFDat::m_type.

Referenced by LMFClsDat().

55  {
56  m_className = "LMFClsDat";
57  m_keys["LMF_IOV_ID_REF"] = 0;
58  m_keys["MEAN"] = 1;
59  m_keys["NORM"] = 2;
60  m_keys["RMS"] = 3;
61  m_keys["NEVT"] = 4;
62  m_keys["ENORM"] = 5;
63  m_keys["FLAG"] = 6;
64  m_keys["FLAGNORM"] = 7;
65  m_keys["VMIN"] = 8;
66  m_keys["VMAX"] = 9;
67  for (unsigned int i = 0; i < m_keys.size(); i++) {
68  m_type.push_back("NUMBER");
69  }
70  m_system = 0;
71  m_color = 0;
72 }
std::string m_className
Definition: LMFUnique.h:99
int i
Definition: DBlmapReader.cc:9
std::vector< std::string > m_type
Definition: LMFDat.h:150
std::map< std::string, unsigned int > m_keys
Definition: LMFDat.h:155
bool LMFClsDat::isValid ( void  )
virtual

Reimplemented from LMFDat.

Definition at line 74 of file LMFClsDat.cc.

References LMFColoredTable::getColor(), LMFDat::m_Error, and run_regression::ret.

Referenced by core.AutoHandle.AutoHandle::ReallyLoad().

74  {
75  bool ret = true;
76  if ((getColor() != "BLUE") && (getColor() != "IR")) {
77  m_Error += " Color not properly set [" + getColor() + "]";
78  ret = false;
79  }
80  return ret;
81 }
std::string getColor() const
std::string m_Error
Definition: LMFDat.h:157
LMFClsDat & LMFClsDat::setENorm ( EcalLogicID id,
float  v 
)

Definition at line 98 of file LMFClsDat.cc.

References LMFDat::setData().

98  {
99  LMFDat::setData(id, "ENORM", v);
100  return *this;
101 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setFlag ( EcalLogicID id,
int  v 
)

Definition at line 113 of file LMFClsDat.cc.

References LMFDat::setData().

113  {
114  LMFDat::setData(id, "FLAG", v);
115  return *this;
116 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setFlagNorm ( EcalLogicID id,
float  v 
)

Definition at line 118 of file LMFClsDat.cc.

References LMFDat::setData().

118  {
119  LMFDat::setData(id, "FLAGNORM", v);
120  return *this;
121 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setLMFRefRunIOVID ( EcalLogicID id,
int  v 
)

Definition at line 83 of file LMFClsDat.cc.

References LMFDat::setData().

83  {
84  LMFDat::setData(id, "LMF_IOV_ID_REF", v);
85  return *this;
86 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setMean ( EcalLogicID id,
float  v 
)

Definition at line 88 of file LMFClsDat.cc.

References LMFDat::setData().

88  {
89  LMFDat::setData(id, "MEAN", v);
90  return *this;
91 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setNevt ( EcalLogicID id,
int  v 
)

Definition at line 108 of file LMFClsDat.cc.

References LMFDat::setData().

108  {
109  LMFDat::setData(id, "NEVT", v);
110  return *this;
111 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setNorm ( EcalLogicID id,
float  v 
)

Definition at line 93 of file LMFClsDat.cc.

References LMFDat::setData().

93  {
94  LMFDat::setData(id, "NORM", v);
95  return *this;
96 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat & LMFClsDat::setRMS ( EcalLogicID id,
float  v 
)

Definition at line 103 of file LMFClsDat.cc.

References LMFDat::setData().

103  {
104  LMFDat::setData(id, "RMS", v);
105  return *this;
106 }
LMFDat & setData(int logic_id, const std::vector< float > &data)
Definition: LMFDat.h:55
LMFClsDat& LMFClsDat::setSystem ( int  system)
inlinevirtual

Reimplemented from LMFColoredTable.

Definition at line 41 of file LMFClsDat.h.

41 { return *this; }
LMFClsDat& LMFClsDat::setSystem ( std::string  system)
inlinevirtual

Reimplemented from LMFColoredTable.

Definition at line 42 of file LMFClsDat.h.

42 { return *this; }