CMS 3D CMS Logo

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
Namespaces | Classes | Typedefs | Enumerations | Functions | Variables
cond Namespace Reference

Namespaces

 ecalcond
 
 ecalped
 
 idCategories
 
 impl
 
 RelationalAuthenticationService
 
 rpcobgas
 
 rpcobimon
 
 rpcobtemp
 
 rpcobvmon
 
 service
 
 time
 
 XMLAuthenticationService
 

Classes

class  AlignSplitIOV
 
class  Auth
 
struct  AuthorizationData
 
class  BaseKeyed
 
class  BasePayloadProxy
 
class  BaseValueExtractor
 
class  BlobStreamingService
 
class  Cipher
 
struct  ClassID
 
class  ClassInfo
 
class  CondDB
 
class  CondGetter
 
class  CoralServiceFactory
 
class  CoralServiceManager
 
struct  CredentialData
 
class  CredentialStore
 
class  CSScopedSession
 
class  DataProxyWrapperBase
 
class  DbConnection
 
class  DbConnectionConfiguration
 
class  DbOpenTransaction
 
class  DbScopedTransaction
 
class  DbSession
 
class  DbTransaction
 
class  DecodingKey
 
class  EcalDAQTowerStatusHelper
 
class  EcalDCSTowerStatusHelper
 
class  EcalDQMChannelStatusHelper
 
class  EcalDQMTowerStatusHelper
 
class  EcalGainRatiosHelper
 
class  EcalLaserAPDPNRatiosHelper
 
class  EcalPedestalsHelper
 
class  EcalTPGCrystalStatusHelper
 
class  EcalTPGLinearizationConstHelper
 
class  EcalTPGPedestalsHelper
 
class  EmptyIOVSource
 
class  Exception
 
class  ExportIOVUtilities
 
struct  ExtractWhat
 
struct  ExtractWhat< ecalcond::Container >
 
struct  ExtractWhat< EcalDAQTowerStatus >
 
struct  ExtractWhat< EcalDCSTowerStatus >
 
struct  ExtractWhat< EcalDQMChannelStatus >
 
struct  ExtractWhat< EcalDQMTowerStatus >
 
struct  ExtractWhat< EcalPedestals >
 
struct  ExtractWhat< EcalTPGCrystalStatus >
 
struct  ExtractWhat< Pedestals >
 
struct  ExtractWhat< RPCObGas >
 
struct  ExtractWhat< RPCObImon >
 
struct  ExtractWhat< RPCObTemp >
 
struct  ExtractWhat< RPCObVmon >
 
struct  ExtractWhat< SiStripSummary >
 
class  FileReader
 
class  FipProtocolParser
 
class  FrontierProxy
 
class  FWIncantation
 
class  GenericSummary
 
class  HcalGainWidthsDataRepr
 
class  HcalLUTCorrsDataRepr
 
class  HcalLutMetadataDataRepr
 
class  HcalPedestalsDataRepr
 
class  HcalPFCorrsDataRepr
 
class  HcalQIEDataDataRepr
 
class  HcalRespCorrsDataRepr
 
class  HcalTimeCorrsDataRepr
 
class  HcalValidationCorrsDataRepr
 
class  HcalZSThresholdsDataRepr
 
class  IOVDescription
 
class  IOVEditor
 
class  IOVElement
 
class  IOVElementProxy
 
class  IOVImportIterator
 
class  IOVKeysDescription
 
class  IOVNames
 
class  IOVProvenance
 
class  IOVProxy
 
struct  IOVProxyData
 
class  IOVRange
 
class  IOVSchemaUtility
 
class  IOVSequence
 
class  IOVUserMetaData
 
class  IterHelp
 
class  KeyedElement
 
class  KeyGenerator
 
class  KeyList
 
struct  LessFrame
 
class  LogDBEntry
 
class  LogDBNames
 
class  Logger
 
class  MetaData
 
class  MetaDataEntry
 
class  noDataForRequiredTimeException
 
class  nonExistentGlobalTagException
 
class  nonExistentGlobalTagInventoryException
 
class  NullUserLogInfo
 
class  OracleProxy
 
class  PayLoadInspector
 
class  PayloadProxy
 
class  PayloadProxy< cond::KeyList >
 
class  PayloadRef
 
class  PfnEditor
 
class  PoolTokenParser
 
class  PoolTokenWriter
 
struct  PrincipalData
 
class  RDBMS
 
struct  RealTimeType
 
struct  RealTimeType< hash >
 
struct  RealTimeType< lumiid >
 
struct  RealTimeType< runnumber >
 
struct  RealTimeType< timestamp >
 
struct  RealTimeType< userid >
 
class  RefException
 
class  SequenceManager
 
class  SequenceState
 
struct  ServiceCredentials
 
class  SessionImpl
 
struct  SessionMonitor
 The session related book-keeping of monitored events. More...
 
class  SmallWORMDict
 
class  SQLiteProxy
 
class  SQLMonitoringService
 
class  SQLReport
 
class  Summary
 
class  TagCollectionRetriever
 
class  TagInfo
 
class  TagMetadata
 
class  TBufferBlobStreamingService
 
class  TBufferBlobTypeInfo
 
class  TechnologyProxy
 
struct  TimeTypeSpecs
 
struct  TimeTypeTraits
 
class  TransactionException
 
class  UnregisteredRecordException
 
class  UpdateStamp
 
class  UserLogInfo
 
class  Utilities
 
class  UtilitiesError
 
class  ValueExtractor
 
class  ValueExtractor< AlCaRecoTriggerBits >
 
class  ValueExtractor< Alignments >
 
class  ValueExtractor< BeamSpotObjects >
 
class  ValueExtractor< DTCCBConfig >
 
class  ValueExtractor< DTDeadFlag >
 
class  ValueExtractor< DTHVStatus >
 
class  ValueExtractor< DTLVStatus >
 
class  ValueExtractor< DTMtime >
 
class  ValueExtractor< DTPerformance >
 
class  ValueExtractor< DTRangeT0 >
 
class  ValueExtractor< DTReadOutMapping >
 
class  ValueExtractor< DTStatusFlag >
 
class  ValueExtractor< DTT0 >
 
class  ValueExtractor< DTTPGParameters >
 
class  ValueExtractor< DTTtrig >
 
class  ValueExtractor< EcalADCToGeVConstant >
 
class  ValueExtractor< ecalcond::Container >
 
class  ValueExtractor< EcalDAQTowerStatus >
 
class  ValueExtractor< EcalDCSTowerStatus >
 
class  ValueExtractor< EcalDQMChannelStatus >
 
class  ValueExtractor< EcalDQMTowerStatus >
 
class  ValueExtractor< EcalGainRatios >
 
class  ValueExtractor< EcalLaserAPDPNRatios >
 
class  ValueExtractor< EcalMappingElectronics >
 
class  ValueExtractor< EcalPedestals >
 
class  ValueExtractor< EcalTBWeights >
 
class  ValueExtractor< EcalTPGCrystalStatus >
 
class  ValueExtractor< EcalTPGLinearizationConst >
 
class  ValueExtractor< EcalTPGPedestals >
 
class  ValueExtractor< EcalWeightXtalGroups >
 
class  ValueExtractor< FillInfo >
 
class  ValueExtractor< HcalChannelQuality >
 
class  ValueExtractor< HcalGains >
 
class  ValueExtractor< HcalGainWidths >
 
class  ValueExtractor< HcalLUTCorrs >
 
class  ValueExtractor< HcalLutMetadata >
 
class  ValueExtractor< HcalPedestals >
 
class  ValueExtractor< HcalPFCorrs >
 
class  ValueExtractor< HcalQIEData >
 
class  ValueExtractor< HcalRespCorrs >
 
class  ValueExtractor< HcalTimeCorrs >
 
class  ValueExtractor< HcalValidationCorrs >
 
class  ValueExtractor< HcalZSThresholds >
 
class  ValueExtractor< L1TriggerScaler >
 
class  ValueExtractor< Pedestals >
 
class  ValueExtractor< RPCObGas >
 
class  ValueExtractor< RPCObImon >
 
class  ValueExtractor< RPCObPVSSmap >
 
class  ValueExtractor< RPCObTemp >
 
class  ValueExtractor< RPCObVmon >
 
class  ValueExtractor< RunInfo >
 
class  ValueExtractor< RunNumber >
 
class  ValueExtractor< RunSummary >
 
class  ValueExtractor< SiStripApvGain >
 
class  ValueExtractor< SiStripBadStrip >
 
class  ValueExtractor< SiStripBaseDelay >
 
class  ValueExtractor< SiStripConfObject >
 
class  ValueExtractor< SiStripDetVOff >
 
class  ValueExtractor< SiStripFedCabling >
 
class  ValueExtractor< SiStripLatency >
 
class  ValueExtractor< SiStripLorentzAngle >
 
class  ValueExtractor< SiStripNoises >
 
class  ValueExtractor< SiStripPedestals >
 
class  ValueExtractor< SiStripRunSummary >
 
class  ValueExtractor< SiStripSummary >
 
class  ValueExtractor< SiStripThreshold >
 

Typedefs

typedef
edmplugin::PluginFactory
< ora::IBlobStreamingService *() > 
BlobStreamerPluginFactory
 
typedef
edmplugin::PluginFactory
< ClassInfo *() > 
ClassInfoFactory
 
typedef
edmplugin::PluginFactory
< coral::Service *(const
std::string &) > 
CoralServicePluginFactory
 
typedef std::vector
< coral::monitor::Event::Record > 
EventStream
 The raw stream of recorder monitoring events. More...
 
typedef std::set
< cond::TagMetadata
GlobalTag
 
typedef ora::Guid Guid
 
typedef
boost::transform_iterator
< IterHelp,
boost::counting_iterator< int > > 
iov_range_iterator
 
typedef
edmplugin::PluginFactory
< cond::DataProxyWrapperBase *() > 
ProxyFactory
 
typedef std::map< std::string,
SessionMonitor
Repository
 
typedef
edmplugin::PluginFactory
< cond::TechnologyProxy *() > 
TechnologyProxyFactory
 
typedef unsigned long long Time_t
 
typedef unsigned long long uint64_t
 
typedef std::pair< unsigned
int, unsigned int > 
UnpackedTime
 
typedef std::pair< Time_t, Time_tValidityInterval
 

Enumerations

enum  DbAuthenticationSystem { UndefinedAuthentication =0, CondDbKey, CoralXMLFile }
 
enum  DbConfigurationDefaults {
  CoralDefaults, CmsDefaults, ProdDefaults, ToolDefaults,
  WebDefaults
}
 
enum  TimeType {
  runnumber =0, timestamp, lumiid, hash,
  userid
}
 

Functions

std::auto_ptr
< cond::TechnologyProxy
buildTechnologyProxy (const std::string &userconnect, const DbConnection &connection)
 
char const * className (const std::type_info &t)
 
std::string classNameForTypeId (const std::type_info &typeInfo)
 
unsigned int countslash (const std::string &input)
 
void draw (std::vector< TH2F > &graphData, std::string filename)
 
const TimeTypeSpecsfindSpecs (std::string const &name)
 
cond::Time_t fromIOVSyncValue (edm::IOVSyncValue const &time, cond::TimeType timetype)
 
void * genMD5 (void *buffer, unsigned long len, void *code)
 
void genMD5 (const std::string &s, void *code)
 
void genMD5 (const string &s, void *code)
 
std::string getLoginName ()
 
std::string getTotalErrors (const std::vector< EcalChannelStatusCode > &vItems)
 
unsigned long long hash64 (unsigned char *k, unsigned long long length, unsigned long long level)
 
std::string insertIOV (cond::DbSession &dbSess, const boost::shared_ptr< IOVSequence > &data, bool swapOIds=false)
 
const Time_t invalidTime (0)
 
const std::string invalidToken (" ")
 
edm::IOVSyncValue limitedIOVSyncValue (cond::Time_t time, cond::TimeType timetype)
 
edm::IOVSyncValue limitedIOVSyncValue (edm::IOVSyncValue const &time, cond::TimeType timetype)
 
Double_t linearF (Double_t *x, Double_t *par)
 
boost::shared_ptr
< cond::IOVSequence
loadIOV (cond::DbSession &dbSess, const std::string &iovToken)
 
void parseLineForNamedParams (const std::string &line, std::map< std::string, std::string > &params)
 
std::pair< std::string, int > parseToken (const std::string &objectId)
 
const char * pluginCategory ()
 
std::string QIEDataCounter (const int nr, unsigned int &formated_nr, int base=4)
 
char randomChar ()
 
std::string schemaLabel (const std::string &serviceName, const std::string &userName)
 
std::string schemaLabelForCredentialStore (const std::string &connectionString)
 
bool selectAuthorization (coral::ISchema &schema, int principalId, const std::string &role, const std::string &connectionString, AuthorizationData &destination)
 
bool selectConnection (coral::ISchema &schema, const std::string &connectionLabel, CredentialData &destination)
 
bool selectPrincipal (coral::ISchema &schema, const std::string &principal, PrincipalData &destination)
 
void setErr (unsigned int const &statusCode, std::vector< std::pair< std::string, unsigned int > > &vTotalWithErr)
 
std::string StCodeToStr (unsigned int const &statusCode)
 
const std::string tagInventoryTable ("TAGINVENTORY_TABLE")
 
const std::string tagTreeTablePrefix ("TAGTREE_TABLE")
 
void throwException (std::string const &message, std::string const &methodName)
 
const Time_t TIMELIMIT (std::numeric_limits< Time_t >::max())
 
std::string const & timeTypeNames (int)
 
template<class T >
std::string to_string (const T &t)
 
edm::IOVSyncValue toIOVSyncValue (cond::Time_t time, cond::TimeType timetype, bool startOrStop)
 
static void topinit ()
 
unsigned long long toUNIX (int date, int time)
 
void updateIOV (cond::DbSession &dbSess, const boost::shared_ptr< IOVSequence > &data, const std::string &token)
 
std::string userInfo ()
 
std::string writeToken (const std::string &containerName, int oid0, int oid1, const std::string &className)
 
std::string writeTokenContainerFragment (const std::string &containerName, const std::string &className)
 

Variables

static const char * fmt_oid = "[OID=%08X-%08X]"
 
static const char * fmt_tech = "[TECH=%08X]"
 
const std::string tagInventoryTable
 
const std::string tagTreeTablePrefix
 
const unsigned int TIMETYPE_LIST_MAX =5
 
const cond::TimeType timeTypeList [TIMETYPE_LIST_MAX]
 
const TimeTypeSpecs timeTypeSpecs []
 
const cond::TimeType timeTypeValues []
 

Detailed Description

magic: works only if a file local registry exists in the file #define ELEM_CONSTR(xx_) \ cond::ClassInfo::ClassInfo(const std::type_info& t,int) : tinfo(t) {registry = registerMe(t);}

Typedef Documentation

Definition at line 8 of file BlobStreamerPluginFactory.h.

Definition at line 69 of file ClassID.h.

typedef edmplugin::PluginFactory< coral::Service*(const std::string&) > cond::CoralServicePluginFactory

Definition at line 24 of file CoralServiceFactory.h.

typedef std::vector<coral::monitor::Event::Record> cond::EventStream

The raw stream of recorder monitoring events.

Definition at line 24 of file SQLMonitoringService.h.

Definition at line 20 of file CondPyInterface.h.

Definition at line 26 of file Guid.h.

typedef boost::transform_iterator<IterHelp,boost::counting_iterator<int> > cond::iov_range_iterator

Definition at line 109 of file IOVProxy.h.

Definition at line 25 of file ProxyFactory.h.

typedef std::map< std::string, SessionMonitor > cond::Repository

The repository of monitored events for all sessions where event streams are identified by session key

Definition at line 38 of file SQLMonitoringService.h.

Definition at line 10 of file TechnologyProxyFactory.h.

typedef unsigned long long cond::Time_t

Definition at line 16 of file Time.h.

typedef unsigned long long cond::uint64_t

Definition at line 15 of file Time.h.

typedef std::pair<unsigned int, unsigned int> cond::UnpackedTime

Definition at line 17 of file Time.h.

typedef std::pair<Time_t, Time_t> cond::ValidityInterval

Definition at line 19 of file Time.h.

Enumeration Type Documentation

Enumerator
runnumber 
timestamp 
lumiid 
hash 
userid 

Definition at line 21 of file Time.h.

Function Documentation

std::auto_ptr<cond::TechnologyProxy> cond::buildTechnologyProxy ( const std::string &  userconnect,
const DbConnection connection 
)
inline

Definition at line 17 of file DbSession.cc.

References SurfaceDeformationFactory::create(), edm::hlt::Exception, reco::get(), AlCaHLTBitMon_ParallelJobs::p, and pos.

Referenced by cond::DbSession::importMapping(), cond::SessionImpl::open(), and cond::SessionImpl::openReadOnly().

18  {
19  std::string protocol;
20  std::size_t pos=userconnect.find_first_of(':');
21  if( pos!=std::string::npos ){
22  protocol=userconnect.substr(0,pos);
23  std::size_t p=protocol.find_first_of('_');
24  if(p!=std::string::npos){
25  protocol=protocol.substr(0,p);
26  }
27  }else{
28  throw cond::Exception(userconnect +":connection string format error");
29  }
30  std::auto_ptr<cond::TechnologyProxy> ptr(cond::TechnologyProxyFactory::get()->create(protocol));
31  (*ptr).initialize(connection);
32  return ptr;
33  }
SurfaceDeformation * create(int type, const std::vector< double > &params)
T get(const Candidate &c)
Definition: component.h:56
char const * cond::className ( const std::type_info &  t)

Definition at line 8 of file ClassID.cc.

References ntuplemaker::status.

Referenced by cond::service::GetTokenFromPointer< T >::operator()(), cond::ClassInfo::pluginName(), and cond::IOVSequence::swapTokens().

8  {
9  int status=0;
10  return __cxxabiv1::__cxa_demangle(t.name(), 0, 0, &status);
11  }
tuple status
Definition: ntuplemaker.py:245
std::string cond::classNameForTypeId ( const std::type_info &  typeInfo)
inline

Definition at line 38 of file PoolDBOutputService.h.

Referenced by cond::service::GetTokenFromPointer< T >::classNameForPointer(), l1t::WriterProxyT< Record, Type >::save(), and l1t::DataWriter::writeKeyList().

38  {
39  Reflex::Type reflexType = Reflex::Type::ByTypeInfo( typeInfo );
40  //FIXME: should become Reflex::SCOPED?
41  return reflexType.Name();
42  }
unsigned int cond::countslash ( const std::string &  input)

Definition at line 57 of file FrontierProxy.cc.

References prof2calltree::count.

Referenced by cond::FrontierProxy::makeRealConnectString().

57  {
58  unsigned int count=0;
59  std::string::size_type slashpos( 0 );
60  while( slashpos!=std::string::npos){
61  slashpos = input.find('/', slashpos );
62  if ( slashpos != std::string::npos ){
63  ++count;
64  // start next search after this word
65  slashpos += 1;
66  }
67  }
68  return count;
69  }
uint16_t size_type
void cond::draw ( std::vector< TH2F > &  graphData,
std::string  filename 
)

Definition at line 113 of file HcalGainsPyWrapper.cc.

References svgfig::canvas().

Referenced by cond::PayLoadInspector< DataT >::plot(), SiPixelRecHitQuality::Packing::setProbabilityQ(), SiPixelRecHitQuality::Packing::setProbabilityXY(), and examples::TrackAnalysisAlgorithm::terminate().

113  {
114  //Drawing...
115  // use David's palette
116  gStyle->SetPalette(1);
117  const Int_t NCont = 999;
118  gStyle->SetNumberContours(NCont);
119  TCanvas canvas("CC map","CC map",840,369*4);
120 
121  TPad pad1("pad1","pad1", 0.0, 0.75, 1.0, 1.0);
122  pad1.Draw();
123  TPad pad2("pad2","pad2", 0.0, 0.5, 1.0, 0.75);
124  pad2.Draw();
125  TPad pad3("pad3","pad3", 0.0, 0.25, 1.0, 0.5);
126  pad3.Draw();
127  TPad pad4("pad4","pad4", 0.0, 0.0, 1.0, 0.25);
128  pad4.Draw();
129 
130 
131  pad1.cd();
132  graphData[0].SetStats(0);
133  graphData[0].Draw("colz");
134 
135  pad2.cd();
136  graphData[1].SetStats(0);
137  graphData[1].Draw("colz");
138 
139  pad3.cd();
140  graphData[2].SetStats(0);
141  graphData[2].Draw("colz");
142 
143  pad4.cd();
144  graphData[3].SetStats(0);
145  graphData[3].Draw("colz");
146 
147  canvas.SaveAs(filename.c_str());
148  }
def canvas
Definition: svgfig.py:481
tuple filename
Definition: lut2db_cfg.py:20
const TimeTypeSpecs & cond::findSpecs ( std::string const &  name)

Definition at line 33 of file Time.cc.

References edm::hlt::Exception, i, TIMETYPE_LIST_MAX, and timeTypeSpecs.

Referenced by cond::service::PoolDBOutputService::fillRecord(), and cond::service::PoolDBOutputService::PoolDBOutputService().

33  {
34  size_t i=0;
35  for (; i<TIMETYPE_LIST_MAX; i++)
36  if (name==timeTypeSpecs[i].name) return timeTypeSpecs[i];
37  throw cms::Exception("invalid timetype: "+name);
38  return timeTypeSpecs[0]; // compiler happy
39  }
const TimeTypeSpecs timeTypeSpecs[]
Definition: Time.cc:22
int i
Definition: DBlmapReader.cc:9
const unsigned int TIMETYPE_LIST_MAX
Definition: Time.h:22
cond::Time_t cond::fromIOVSyncValue ( edm::IOVSyncValue const &  time,
cond::TimeType  timetype 
)

Definition at line 29 of file ConvertIOVSyncValue.cc.

References edm::IOVSyncValue::eventID(), lumiid, edm::IOVSyncValue::luminosityBlockNumber(), edm::EventID::run(), runnumber, edm::IOVSyncValue::time(), timestamp, edm::LuminosityBlockID::value(), and edm::Timestamp::value().

Referenced by CondDBESSource::setIntervalFor().

29  {
30  switch (timetype) {
31  case cond::runnumber :
32  return time.eventID().run();
33  case cond::lumiid :
34  {
35  edm::LuminosityBlockID lum(time.eventID().run(), time.luminosityBlockNumber());
36  return lum.value();
37  }
38  case cond::timestamp :
39  return time.time().value();
40  default:
41  return 0;
42  }
43  }
boost::uint64_t value() const
void * cond::genMD5 ( void *  buffer,
unsigned long  len,
void *  code 
)

Definition at line 358 of file GenMD5.cc.

Referenced by writeTokenContainerFragment().

358  {
359  MD5 checkSum((unsigned char*)buffer, len);
360  checkSum.raw_digest((unsigned char*)code);
361  return code;
362  }
void cond::genMD5 ( const std::string &  s,
void *  code 
)
void cond::genMD5 ( const string &  s,
void *  code 
)

Definition at line 363 of file GenMD5.cc.

363  {
364  MD5 checkSum((unsigned char*)s.c_str(), s.length());
365  checkSum.raw_digest((unsigned char*)code);
366  }
std::string cond::getLoginName ( )

Definition at line 41 of file DecodingKey.cc.

References lumiQueryAPI::msg, and throwException().

Referenced by cond::DecodingKey::init().

41  {
42  std::string loginName("");
43  struct passwd* userp = ::getpwuid(::getuid());
44  if(userp) {
45  char* uName = userp->pw_name;
46  if(uName){
47  loginName += uName;
48  }
49  }
50  if(loginName.empty()){
51  std::string msg("Cannot determine login name.");
52  throwException(msg,"DecodingKey::getLoginName");
53  }
54  return loginName;
55  }
void throwException(std::string const &message, std::string const &methodName)
Definition: Exception.cc:17
std::string cond::getTotalErrors ( const std::vector< EcalChannelStatusCode > &  vItems)

Definition at line 239 of file EcalChannelStatusPyWrapper.cc.

References bits, i, getHLTprescales::index, and setErr().

Referenced by cond::PayLoadInspector< DataT >::summary().

239  {
240  unsigned int stcode = 0, index = 0, totalErrorCodes = 22;
241  std::stringstream ss;
242  std::vector< std::pair< std::string, unsigned int > > vTotalWithErr(totalErrorCodes);
243 
244 
245  // init error codes:
246  index = 0;
247  ss.str(""); ss << " No errors. "; vTotalWithErr[index].first = ss.str(); ++index;
248  ss.str(""); ss << "["<< index << "]:" << "DAC settings problem, pedestal not in the design range, " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;//1
249  ss.str(""); ss << "["<< index << "]:" << "channel with no laser, ok elsewhere; " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;
250  ss.str(""); ss << "["<< index << "]:" << "noisy; " << "Reco Action: standard reco."; vTotalWithErr[index].first = ss.str(); ++index;
251  ss.str(""); ss << "["<< index << "]:" << "very noisy; " << "Reco Action: special reco (to be decided)."; vTotalWithErr[index].first = ss.str(); ++index;
252  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
253  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
254  ss.str(""); ss << "["<< index << "]: reserved for more categories of noisy channels."; vTotalWithErr[index].first = ss.str(); ++index;
255  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 6 (or 6 and 1); " << "Reco Action: 3+5 or 3+1, special reco."; vTotalWithErr[index].first = ss.str(); ++index;
256  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 1; " << "Reco Action: 3+5 or 3+1, special reco."; vTotalWithErr[index].first = ss.str(); ++index;
257  ss.str(""); ss << "["<< index << "]:" << " channel at fixed gain 0 (dead of type this); " << "Reco Action: recovery from neighbours."; vTotalWithErr[index].first = ss.str(); ++index;
258  ss.str(""); ss << "["<< index << "]:" << " non responding isolated channel (dead of type other); " << "Reco Action: recovery from neighbours."; vTotalWithErr[index].first = ss.str(); ++index;
259  ss.str(""); ss << "["<< index << "]:" << " channel and one or more neigbors not responding (e.g.: in a dead VFE 5x1 channel) " << "Reco Action: no recovery."; vTotalWithErr[index].first = ss.str(); ++index;
260  ss.str(""); ss << "["<< index << "]:" << " channel in TT with no data link, TP data ok; " << "Reco Action: recovery from TP data."; vTotalWithErr[index].first = ss.str(); ++index;
261  ss.str(""); ss << "["<< index << "]:" << " channel in TT with no data link and no TP data; " << "Reco Action: none."; vTotalWithErr[index].first = ss.str(); ++index;
262 
263  unsigned int bits = 6;
264  ss.str(""); ss << " bit["<< bits++ << "]:" << " HV good/not good;"; vTotalWithErr[index].first = ss.str(); ++index;//15
265  ss.str(""); ss << " bit["<< bits++ << "]:" << " LV on/off;"; vTotalWithErr[index].first = ss.str(); ++index;
266  ss.str(""); ss << " bit["<< bits++ << "]:" << " DAQ in/out;"; vTotalWithErr[index].first = ss.str(); ++index;
267  ss.str(""); ss << " bit["<< bits++ << "]:" << " TP readout on/off;"; vTotalWithErr[index].first = ss.str(); ++index;
268  ss.str(""); ss << " bit["<< bits++ << "]:" << " Trigger in/out;"; vTotalWithErr[index].first = ss.str(); ++index;
269  ss.str(""); ss << " bit["<< bits++ << "]:" << " Temperature ok/not ok;"; vTotalWithErr[index].first = ss.str(); ++index;
270  ss.str(""); ss << " bit["<< bits++ << "]:" << " Humidity ok/not;"; vTotalWithErr[index].first = ss.str(); ++index;//21
271 
272 
273  ss.str("");
274  //count error codes for each error:
275  for (std::vector<EcalChannelStatusCode>::const_iterator vIter = vItems.begin(); vIter != vItems.end(); ++vIter){
276  stcode = vIter->getStatusCode();
277  if (stcode !=0){
278  setErr(stcode, vTotalWithErr);
279  }
280  }
281 
282  unsigned int i = 0;
283  for (std::vector< std::pair< std::string, unsigned int > >::const_iterator iTotalErr = vTotalWithErr.begin(); iTotalErr != vTotalWithErr.end(); ++iTotalErr){
284  if (iTotalErr->second != 0)
285  ss << "Total:" << iTotalErr->second << " Error:" << iTotalErr->first << std::endl;
286  ++i;
287  }
288  return ss.str();
289  }
int i
Definition: DBlmapReader.cc:9
void setErr(unsigned int const &statusCode, std::vector< std::pair< std::string, unsigned int > > &vTotalWithErr)
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision bits
ub8 cond::hash64 ( unsigned char *  k,
unsigned long long  length,
unsigned long long  level 
)

Definition at line 45 of file hash64.cc.

References a, b, trackerHits::c, testEve_cfg::level, and mix64.

Referenced by cond::KeyedElement::convert().

49  {
50  register ub8 a,b,c,len;
51 
52  /* Set up the internal state */
53  len = length;
54  a = b = level; /* the previous hash value */
55  c = 0x9e3779b97f4a7c13LL; /* the golden ratio; an arbitrary value */
56 
57  /*---------------------------------------- handle most of the key */
58  if (((unsigned long)k)&7)
59  {
60  while (len >= 24)
61  {
62  a += (k[0] +((ub8)k[ 1]<< 8)+((ub8)k[ 2]<<16)+((ub8)k[ 3]<<24)
63  +((ub8)k[4 ]<<32)+((ub8)k[ 5]<<40)+((ub8)k[ 6]<<48)+((ub8)k[ 7]<<56));
64  b += (k[8] +((ub8)k[ 9]<< 8)+((ub8)k[10]<<16)+((ub8)k[11]<<24)
65  +((ub8)k[12]<<32)+((ub8)k[13]<<40)+((ub8)k[14]<<48)+((ub8)k[15]<<56));
66  c += (k[16] +((ub8)k[17]<< 8)+((ub8)k[18]<<16)+((ub8)k[19]<<24)
67  +((ub8)k[20]<<32)+((ub8)k[21]<<40)+((ub8)k[22]<<48)+((ub8)k[23]<<56));
68  mix64(a,b,c);
69  k += 24; len -= 24;
70  }
71  }
72  else
73  {
74  while (len >= 24) /* aligned */
75  {
76  a += *(ub8 *)(k+0);
77  b += *(ub8 *)(k+8);
78  c += *(ub8 *)(k+16);
79  mix64(a,b,c);
80  k += 24; len -= 24;
81  }
82  }
83 
84  /*------------------------------------- handle the last 23 bytes */
85  c += length;
86  switch(len) /* all the case statements fall through */
87  {
88  case 23: c+=((ub8)k[22]<<56);
89  case 22: c+=((ub8)k[21]<<48);
90  case 21: c+=((ub8)k[20]<<40);
91  case 20: c+=((ub8)k[19]<<32);
92  case 19: c+=((ub8)k[18]<<24);
93  case 18: c+=((ub8)k[17]<<16);
94  case 17: c+=((ub8)k[16]<<8);
95  /* the first byte of c is reserved for the length */
96  case 16: b+=((ub8)k[15]<<56);
97  case 15: b+=((ub8)k[14]<<48);
98  case 14: b+=((ub8)k[13]<<40);
99  case 13: b+=((ub8)k[12]<<32);
100  case 12: b+=((ub8)k[11]<<24);
101  case 11: b+=((ub8)k[10]<<16);
102  case 10: b+=((ub8)k[ 9]<<8);
103  case 9: b+=((ub8)k[ 8]);
104  case 8: a+=((ub8)k[ 7]<<56);
105  case 7: a+=((ub8)k[ 6]<<48);
106  case 6: a+=((ub8)k[ 5]<<40);
107  case 5: a+=((ub8)k[ 4]<<32);
108  case 4: a+=((ub8)k[ 3]<<24);
109  case 3: a+=((ub8)k[ 2]<<16);
110  case 2: a+=((ub8)k[ 1]<<8);
111  case 1: a+=((ub8)k[ 0]);
112  /* case 0: nothing left to add */
113  }
114  mix64(a,b,c);
115  /*-------------------------------------------- report the result */
116  return c;
117  }
#define mix64(a, b, c)
Definition: hash64.cc:22
unsigned long long ub8
Definition: hash64.cc:38
int k[5][pyjets_maxn]
double b
Definition: hdecay.h:120
double a
Definition: hdecay.h:121
tuple level
Definition: testEve_cfg.py:34
std::string cond::insertIOV ( cond::DbSession dbSess,
const boost::shared_ptr< IOVSequence > &  data,
bool  swapOIds = false 
)

Definition at line 26 of file IOVEditor.cc.

References cond::IOVNames::container(), cond::DbSession::isOldSchema(), cond::DbSession::storage(), and cond::DbSession::storeObject().

Referenced by cond::IOVEditor::create().

28  {
29  // ***** TEMPORARY FOR TRANSITION PHASE
30  if( swapOIds && dbSess.isOldSchema() ){
31  PoolTokenWriter writer( dbSess.storage() );
32  data->swapOIds( writer );
33  }
34  // *****
35  return dbSess.storeObject( data.get(), cond::IOVNames::container());
36  }
std::string storeObject(const T *object, const std::string &containerName)
Definition: DbSession.h:131
bool isOldSchema()
Definition: DbSession.cc:215
static std::string container()
Definition: IOVNames.h:7
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
ora::Database & storage()
Definition: DbSession.cc:198
const Time_t cond::invalidTime ( )
const std::string cond::invalidToken ( " "  )
edm::IOVSyncValue cond::limitedIOVSyncValue ( cond::Time_t  time,
cond::TimeType  timetype 
)

Definition at line 46 of file ConvertIOVSyncValue.cc.

References edm::IOVSyncValue::invalidIOVSyncValue(), prof2calltree::l, lumiid, edm::LuminosityBlockID::luminosityBlock(), edm::EventID::maxEventNumber(), edm::LuminosityBlockID::run(), runnumber, and timestamp.

Referenced by CondDBESSource::setIntervalFor().

46  {
47  switch (timetype) {
48  case cond::runnumber :
49  // last lumi and event of this run
53  );
54  case cond::lumiid :
55  {
56  // the same lumiblock
58  return edm::IOVSyncValue(edm::EventID(l.run(),
59  l.luminosityBlock(),
61  );
62  }
63  case cond::timestamp :
64  // next event ?
66  default:
68  }
69  }
static EventNumber_t maxEventNumber()
Definition: EventID.h:106
static const IOVSyncValue & invalidIOVSyncValue()
Definition: IOVSyncValue.cc:92
edm::IOVSyncValue cond::limitedIOVSyncValue ( edm::IOVSyncValue const &  time,
cond::TimeType  timetype 
)

Definition at line 71 of file ConvertIOVSyncValue.cc.

References edm::IOVSyncValue::eventID(), edm::IOVSyncValue::invalidIOVSyncValue(), lumiid, edm::IOVSyncValue::luminosityBlockNumber(), edm::EventID::maxEventNumber(), edm::EventID::run(), runnumber, and timestamp.

71  {
72  switch (timetype) {
73  case cond::runnumber :
74  // last event of this run
75  return edm::IOVSyncValue(edm::EventID(time.eventID().run(),
78  );
79  case cond::lumiid :
80  // the same lumiblock
81  return edm::IOVSyncValue(edm::EventID(time.eventID().run(),
82  time.luminosityBlockNumber(),
84  );
85  case cond::timestamp :
86  // same lumiblock
87  return edm::IOVSyncValue(edm::EventID(time.eventID().run(),
88  time.luminosityBlockNumber(),
90  );
91  default:
93  }
94  }
static EventNumber_t maxEventNumber()
Definition: EventID.h:106
static const IOVSyncValue & invalidIOVSyncValue()
Definition: IOVSyncValue.cc:92
Double_t cond::linearF ( Double_t *  x,
Double_t *  par 
)

Definition at line 260 of file RPCObGasPyWrapper.cc.

References detailsBasic3DVector::y.

Referenced by cond::PayLoadInspector< DataT >::plot().

260  {
261  Double_t y=0.;
262  y=par[0]*(*x);
263  return y;
264  }
boost::shared_ptr<cond::IOVSequence> cond::loadIOV ( cond::DbSession dbSess,
const std::string &  iovToken 
)

Definition at line 9 of file IOVEditor.cc.

References edm::hlt::Exception, cond::DbSession::getTypedObject(), o2o::iov, cond::DbSession::isOldSchema(), cond::IOVSequence::loadAll(), geometryXMLtoCSV::parser, and cond::DbSession::storage().

10  {
11  if( iovToken.empty()){
12  throw cond::Exception("IOVEditor::loadIOV Error: token is empty.");
13  }
14  boost::shared_ptr<cond::IOVSequence> iov = dbSess.getTypedObject<cond::IOVSequence>( iovToken );
15  // loading the lazy-loading Queryable vector...
16  iov->loadAll();
17  //**** temporary for the schema transition
18  if( dbSess.isOldSchema() ){
19  PoolTokenParser parser( dbSess.storage() );
20  iov->swapTokens( parser );
21  }
22  //****
23  return iov;
24  }
void loadAll() const
Definition: IOVSequence.cc:69
tuple iov
Definition: o2o.py:307
bool isOldSchema()
Definition: DbSession.cc:215
boost::shared_ptr< T > getTypedObject(const std::string &objectId)
Definition: DbSession.h:125
ora::Database & storage()
Definition: DbSession.cc:198
void cond::parseLineForNamedParams ( const std::string &  line,
std::map< std::string, std::string > &  params 
)

Definition at line 57 of file DecodingKey.cc.

References ItemSeparator.

Referenced by cond::DecodingKey::createFromInputFile().

57  {
58  std::stringstream str( line );
59  std::string paramName("");
60  std::string paramValue("");
61  while( str.good() ){
62  std::string item("");
63  getline( str, item, ItemSeparator);
64  if( item.size()>3 ){
65  paramName = item.substr(0,2);
66  paramValue = item.substr(2);
67  params.insert( std::make_pair( paramName, paramValue ) );
68  }
69  }
70  }
constexpr char ItemSeparator
Definition: DecodingKey.cc:13
std::pair< std::string, int > cond::parseToken ( const std::string &  objectId)

Definition at line 15 of file PoolToken.cc.

References fmt_oid, p1, p2, p3, LaserTracksInput_cfi::source, ora::throwException(), and tmp.

Referenced by cond::PayLoadInspector< DataT >::dump(), ora::CondMetadataTable::getObjectByName(), and cond::PoolTokenParser::parse().

15  {
16  if( source.empty() ) ora::throwException("Provided token is empty.","PoolToken::parseToken");
17  std::string tmp = source;
18  std::pair<std::string,int> oid;
19  oid.first = "";
20  oid.second = -1;
21  for(char* p1 = (char*)tmp.c_str(); p1; p1 = ::strchr(++p1,'[')) {
22  char* p2 = ::strchr(p1, '=');
23  char* p3 = ::strchr(p1, ']');
24  if ( p2 && p3 ) {
25  char* val = p2+1;
26  if ( ::strncmp("[DB=", p1, 4) == 0 ) {
27  *p3 = 0;
28  } else if ( ::strncmp("[CNT=", p1, 5) == 0 ) {
29  *p3 = 0;
30  oid.first = val;
31  } else if ( ::strncmp(fmt_oid, p1, 5) == 0 ) {
32  int nn;
33  ::sscanf(p1, fmt_oid, &nn, &oid.second);
34  } else {
35  *p3 = *p2 = 0;
36  }
37  *p3 = ']';
38  *p2 = '=';
39  }
40  }
41  return oid;
42  }
static const char * fmt_oid
Definition: PoolToken.cc:13
double p2[4]
Definition: TauolaWrapper.h:90
std::vector< std::vector< double > > tmp
Definition: MVATrainer.cc:100
double p1[4]
Definition: TauolaWrapper.h:89
void throwException(const std::string &message, const std::string &methodName)
Definition: Exception.cc:10
double p3[4]
Definition: TauolaWrapper.h:91
const char * cond::pluginCategory ( )

Definition at line 33 of file ProxyFactory.cc.

34  {
35  return "CondProxyFactory";
36  }
std::string cond::QIEDataCounter ( const int  nr,
unsigned int &  formated_nr,
int  base = 4 
)

Definition at line 102 of file HcalQIEDataPyWrapper.cc.

References newFWLiteAna::base.

Referenced by cond::PayLoadInspector< DataT >::plot().

102  {
103  int numer = nr;
104  int tens = 0, ones = 0;
105  if (numer >= 16){
106  numer = numer -16;
107  }
108  tens = numer / base;
109  ones = numer - (tens*base);
110  formated_nr = tens*10 + ones;
111  std::stringstream ss;
112  ss << tens << ones;
113  return ss.str();
114  }
tuple base
Main Program
Definition: newFWLiteAna.py:92
char cond::randomChar ( )

Definition at line 36 of file DecodingKey.cc.

References b64str, and rand().

Referenced by cond::KeyGenerator::make().

36  {
37  int irand = ::rand()%(::strlen(b64str));
38  return b64str[irand];
39  }
static const char * b64str
Definition: DecodingKey.cc:17
Signal rand(Signal arg)
Definition: vlib.cc:442
std::string cond::schemaLabel ( const std::string &  serviceName,
const std::string &  userName 
)

std::string defaultConnectionString( const std::string& serviceConnectionString, const std::string& serviceName, const std::string& userName ){ size_t pos = serviceConnectionString.find( serviceName ); std::string technologyPrefix = serviceConnectionString.substr(0,pos); std::stringstream connStr; connStr << technologyPrefix; if( !userName.empty() ) connStr <<"/"<< userName; return connStr.str(); }

Definition at line 164 of file CredentialStore.cc.

References run_regression::ret, and serviceName.

Referenced by cond::CredentialStore::importForPrincipal(), and schemaLabelForCredentialStore().

165  {
166  std::string ret = userName;
167  if( !serviceName.empty() ){
168  ret += "@"+serviceName;
169  }
170  return ret;
171  }
static const std::string serviceName
std::string cond::schemaLabelForCredentialStore ( const std::string &  connectionString)

Definition at line 172 of file CredentialStore.cc.

References geometryXMLtoCSV::parser, schemaLabel(), and serviceName.

Referenced by cond::CredentialStore::installAdmin(), and cond::CredentialStore::updatePrincipal().

172  {
173  coral::URIParser parser;
174  parser.setURI( connectionString );
175  std::string serviceName = parser.hostName();
176  std::string schemaName = parser.databaseOrSchemaName();
177  return schemaLabel( serviceName, schemaName );
178  }
static const std::string serviceName
std::string schemaLabel(const std::string &serviceName, const std::string &userName)
bool cond::selectAuthorization ( coral::ISchema &  schema,
int  principalId,
const std::string &  role,
const std::string &  connectionString,
AuthorizationData &  destination 
)

Definition at line 301 of file CredentialStore.cc.

References AUTH_ID_COL(), AUTH_KEY_COL(), C_ID_COL(), COND_AUTHORIZATION_TABLE(), cond::AuthorizationData::connectionId, newFWLiteAna::found, cond::AuthorizationData::id, cond::AuthorizationData::key, P_ID_COL(), o2o::query, ROLE_COL(), and SCHEMA_COL().

Referenced by cond::CredentialStore::setPermission().

301  {
302  std::auto_ptr<coral::IQuery> query(schema.tableHandle(COND_AUTHORIZATION_TABLE).newQuery());
303  coral::AttributeList readBuff;
304  readBuff.extend<int>(AUTH_ID_COL);
305  readBuff.extend<int>(C_ID_COL);
306  readBuff.extend<std::string>(AUTH_KEY_COL);
307  coral::AttributeList whereData;
308  whereData.extend<int>(P_ID_COL);
309  whereData.extend<std::string>(ROLE_COL);
310  whereData.extend<std::string>(SCHEMA_COL);
311  whereData[ P_ID_COL ].data<int>() = principalId;
312  whereData[ ROLE_COL ].data<std::string>() = role;
313  whereData[ SCHEMA_COL ].data<std::string>() = connectionString;
314  std::stringstream whereClause;
315  whereClause << P_ID_COL << " = :"<<P_ID_COL;
316  whereClause << " AND " << ROLE_COL << " = :"<<ROLE_COL;
317  whereClause << " AND " << SCHEMA_COL << " = :"<<SCHEMA_COL;
318  query->defineOutput(readBuff);
319  query->addToOutputList( AUTH_ID_COL );
320  query->addToOutputList( C_ID_COL );
321  query->addToOutputList( AUTH_KEY_COL );
322  query->setCondition( whereClause.str(), whereData );
323  coral::ICursor& cursor = query->execute();
324  bool found = false;
325  if ( cursor.next() ) {
326  const coral::AttributeList& row = cursor.currentRow();
327  destination.id = row[AUTH_ID_COL].data<int>();
328  destination.connectionId = row[C_ID_COL].data<int>();
329  destination.key = row[AUTH_KEY_COL].data<std::string>();
330  found = true;
331  }
332  return found;
333  }
static const std::string ROLE_COL("C_ROLE")
static const std::string SCHEMA_COL("C_SCHEMA")
static const std::string COND_AUTHORIZATION_TABLE("COND_AUTHORIZATION")
static const std::string AUTH_ID_COL("AUTH_ID")
tuple query
Definition: o2o.py:269
static const std::string P_ID_COL("P_ID")
static const std::string C_ID_COL("C_ID")
static const std::string AUTH_KEY_COL("CRED3")
bool cond::selectConnection ( coral::ISchema &  schema,
const std::string &  connectionLabel,
CredentialData &  destination 
)

Definition at line 257 of file CredentialStore.cc.

References COND_CREDENTIAL_TABLE(), CONNECTION_ID_COL(), CONNECTION_KEY_COL(), CONNECTION_LABEL_COL(), cond::CredentialData::connectionKey, newFWLiteAna::found, cond::CredentialData::id, cond::CredentialData::password, PASSWORD_COL(), o2o::query, cond::CredentialData::userName, USERNAME_COL(), VERIFICATION_KEY_COL(), and cond::CredentialData::verificationKey.

Referenced by cond::CredentialStore::removeConnection(), cond::CredentialStore::setPermission(), cond::CredentialStore::updateConnection(), and cond::CredentialStore::updatePrincipal().

257  {
258 
259  std::auto_ptr<coral::IQuery> query(schema.tableHandle(COND_CREDENTIAL_TABLE).newQuery());
260  coral::AttributeList readBuff;
261  readBuff.extend<int>( CONNECTION_ID_COL );
262  readBuff.extend<std::string>( USERNAME_COL );
263  readBuff.extend<std::string>( PASSWORD_COL );
264  readBuff.extend<std::string>( VERIFICATION_KEY_COL );
265  readBuff.extend<std::string>( CONNECTION_KEY_COL );
266  coral::AttributeList whereData;
267  whereData.extend<std::string>( CONNECTION_LABEL_COL );
268  whereData[ CONNECTION_LABEL_COL ].data<std::string>() = connectionLabel;
269  std::string whereClause = CONNECTION_LABEL_COL + " = :" + CONNECTION_LABEL_COL;
270  query->defineOutput(readBuff);
271  query->addToOutputList( CONNECTION_ID_COL );
272  query->addToOutputList( USERNAME_COL );
273  query->addToOutputList( PASSWORD_COL );
274  query->addToOutputList( VERIFICATION_KEY_COL );
275  query->addToOutputList( CONNECTION_KEY_COL );
276  query->setCondition( whereClause, whereData );
277  coral::ICursor& cursor = query->execute();
278  bool found = false;
279  if ( cursor.next() ) {
280  const coral::AttributeList& row = cursor.currentRow();
281  destination.id = row[ CONNECTION_ID_COL].data<int>();
282  destination.userName = row[ USERNAME_COL].data<std::string>();
283  destination.password = row[ PASSWORD_COL].data<std::string>();
284  destination.verificationKey = row[ VERIFICATION_KEY_COL].data<std::string>();
285  destination.connectionKey = row[ CONNECTION_KEY_COL].data<std::string>();
286  found = true;
287  }
288  return found;
289  }
static const std::string PASSWORD_COL("CRED5")
static const std::string COND_CREDENTIAL_TABLE("COND_CREDENTIAL")
static const std::string CONNECTION_KEY_COL("CRED7")
static const std::string VERIFICATION_KEY_COL("CRED6")
static const std::string USERNAME_COL("CRED4")
static const std::string CONNECTION_ID_COL("CONN_ID")
tuple query
Definition: o2o.py:269
static const std::string CONNECTION_LABEL_COL("CONN_LABEL")
bool cond::selectPrincipal ( coral::ISchema &  schema,
const std::string &  principal,
PrincipalData &  destination 
)

Definition at line 213 of file CredentialStore.cc.

References ADMIN_KEY_COL(), cond::PrincipalData::adminKey, COND_AUTHENTICATION_TABLE(), newFWLiteAna::found, cond::PrincipalData::id, PRINCIPAL_ID_COL(), PRINCIPAL_KEY_COL(), PRINCIPAL_NAME_COL(), cond::PrincipalData::principalKey, o2o::query, VERIFICATION_COL(), and cond::PrincipalData::verifKey.

Referenced by cond::CredentialStore::importForPrincipal(), cond::CredentialStore::installAdmin(), cond::CredentialStore::removePrincipal(), cond::CredentialStore::setPermission(), cond::CredentialStore::startSession(), cond::CredentialStore::unsetPermission(), and cond::CredentialStore::updatePrincipal().

213  {
214  std::auto_ptr<coral::IQuery> query(schema.tableHandle(COND_AUTHENTICATION_TABLE).newQuery());
215  coral::AttributeList readBuff;
216  readBuff.extend<int>(PRINCIPAL_ID_COL);
217  readBuff.extend<std::string>(VERIFICATION_COL);
218  readBuff.extend<std::string>(PRINCIPAL_KEY_COL);
219  readBuff.extend<std::string>(ADMIN_KEY_COL);
220  coral::AttributeList whereData;
221  whereData.extend<std::string>(PRINCIPAL_NAME_COL);
222  whereData[ PRINCIPAL_NAME_COL ].data<std::string>() = principal;
223  std::string whereClause = PRINCIPAL_NAME_COL + " = :" + PRINCIPAL_NAME_COL;
224  query->defineOutput(readBuff);
225  query->addToOutputList( PRINCIPAL_ID_COL );
226  query->addToOutputList( VERIFICATION_COL );
227  query->addToOutputList( PRINCIPAL_KEY_COL );
228  query->addToOutputList( ADMIN_KEY_COL );
229  query->setCondition( whereClause, whereData );
230  coral::ICursor& cursor = query->execute();
231  bool found = false;
232  if ( cursor.next() ) {
233  found = true;
234  const coral::AttributeList& row = cursor.currentRow();
235  destination.id = row[ PRINCIPAL_ID_COL ].data<int>();
236  destination.verifKey = row[ VERIFICATION_COL ].data<std::string>();
237  destination.principalKey = row[ PRINCIPAL_KEY_COL ].data<std::string>();
238  destination.adminKey = row[ ADMIN_KEY_COL ].data<std::string>();
239  }
240  return found;
241  }
static const std::string COND_AUTHENTICATION_TABLE("COND_AUTHENTICATION")
static const std::string ADMIN_KEY_COL("CRED2")
static const std::string VERIFICATION_COL("CRED0")
static const std::string PRINCIPAL_ID_COL("P_ID")
static const std::string PRINCIPAL_KEY_COL("CRED1")
tuple query
Definition: o2o.py:269
static const std::string PRINCIPAL_NAME_COL("P_NAME")
void cond::setErr ( unsigned int const &  statusCode,
std::vector< std::pair< std::string, unsigned int > > &  vTotalWithErr 
)

Definition at line 199 of file EcalChannelStatusPyWrapper.cc.

References bits.

Referenced by getTotalErrors().

199  {
200  unsigned int bits_1to5, bits, mask;
201  mask = 0x1F;//get first 5 bits;
202 
203  bits_1to5 = mask & statusCode;
204  if ((bits_1to5 > 0) &&( bits_1to5 < 15)){
205  vTotalWithErr[bits_1to5].second += 1;
206  }
207 
208  bits = 6;
209 
210  mask = 1 << bits;
211  if (statusCode & mask) //case 15
212  vTotalWithErr[bits + 11].second += 1;
213 
214  mask = 1 << ++bits;
215  if (statusCode & mask)//case 16
216  vTotalWithErr[bits + 11].second += 1;
217 
218  mask = 1 << ++bits;
219  if (statusCode & mask)//case 17
220  vTotalWithErr[bits + 11].second += 1;
221 
222  mask = 1 << ++bits;
223  if (statusCode & mask)//case 18
224  vTotalWithErr[bits + 11].second += 1;
225 
226  mask = 1 << ++bits;
227  if (statusCode & mask)//case 19
228  vTotalWithErr[bits + 11].second += 1;
229 
230  mask = 1 << ++bits;
231  if (statusCode & mask)//case 20
232  vTotalWithErr[bits + 11].second += 1;
233 
234  mask = 1 << ++bits;
235  if (statusCode & mask)//case 21
236  vTotalWithErr[bits + 11].second += 1;
237  }
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision bits
std::string cond::StCodeToStr ( unsigned int const &  statusCode)

Definition at line 139 of file EcalChannelStatusPyWrapper.cc.

References bits.

139  {
140  unsigned int bits_1to5, bits, mask;
141  mask = 0x1F;//get first 5 bits;
142  bits_1to5 = mask & statusCode;
143  std::stringstream ss;
144  switch(bits_1to5){
145  case 0: break;
146  case 1: ss<< "["<< bits_1to5 << "]:" << "DAC settings problem, pedestal not in the design range, " << "Reco Action: standard reco."; break;
147  case 2: ss<< "["<< bits_1to5 << "]:" << "channel with no laser, ok elsewhere; " << "Reco Action: standard reco."; break;
148  case 3: ss<< "["<< bits_1to5 << "]:" << "noisy; " << "Reco Action: standard reco."; break;
149  case 4: ss<< "["<< bits_1to5 << "]:" << "very noisy; " << "Reco Action: special reco (to be decided)."; break;
150  case 5: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
151  case 6: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
152  case 7: ss<< "["<< bits_1to5 << "]: reserved for more categories of noisy channels."; break;
153  case 8: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 6 (or 6 and 1); " << "Reco Action: 3+5 or 3+1, special reco."; break;
154  case 9: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 1; " << "Reco Action: 3+5 or 3+1, special reco."; break;
155  case 10: ss<< "["<< bits_1to5 << "]:" << " channel at fixed gain 0 (dead of type this); " << "Reco Action: recovery from neighbours."; break;
156  case 11: ss<< "["<< bits_1to5 << "]:" << " non responding isolated channel (dead of type other); " << "Reco Action: recovery from neighbours."; break;
157  case 12: ss<< "["<< bits_1to5 << "]:" << " channel and one or more neigbors not responding (e.g.: in a dead VFE 5x1 channel) " << "Reco Action: no recovery."; break;
158  case 13: ss<< "["<< bits_1to5 << "]:" << " channel in TT with no data link, TP data ok; " << "Reco Action: recovery from TP data."; break;
159  case 14: ss<< "["<< bits_1to5 << "]:" << " channel in TT with no data link and no TP data; " << "Reco Action: none."; break;
160  default:
161  ss<< "no such bits can be set!";
162  }
163  bits = 6;
164 
165  mask = 1 << bits;
166  if (statusCode & mask) //case 15
167  ss << " bit["<< bits << "]:" << " HV good/not good;";
168 
169  mask = 1 << ++bits;
170  if (statusCode & mask)//case 16
171  ss << " bit["<< bits << "]:" << " LV on/off;";
172 
173  mask = 1 << ++bits;
174  if (statusCode & mask)//case 17
175  ss << " bit["<< bits << "]:" << " DAQ in/out;";
176 
177  mask = 1 << ++bits;
178  if (statusCode & mask)//case 18
179  ss << " bit["<< bits << "]:" << " TP readout on/off;";
180 
181  mask = 1 << ++bits;
182  if (statusCode & mask)//case 19
183  ss << " bit["<< bits << "]:" << " Trigger in/out;";
184 
185  mask = 1 << ++bits;
186  if (statusCode & mask)//case 20
187  ss << " bit["<< bits << "]:" << " Temperature ok/not ok;";
188 
189  mask = 1 << ++bits;
190  if (statusCode & mask)//case 21
191  ss << " bit["<< bits << "]:" << " Humidity ok/not;";
192 
193  //for debugging:
194  //ss << " StatusCode: " << statusCode << " bits_1to5: " <<bits_1to5 << std::endl;
195  ss << std::endl;
196  return ss.str();
197  }
How EventSelector::AcceptEvent() decides whether to accept an event for output otherwise it is excluding the probing of A single or multiple positive and the trigger will pass if any such matching triggers are PASS or EXCEPTION[A criterion thatmatches no triggers at all is detected and causes a throw.] A single negative with an expectation of appropriate bit checking in the decision bits
const std::string cond::tagInventoryTable ( "TAGINVENTORY_TABLE"  )
const std::string cond::tagTreeTablePrefix ( "TAGTREE_TABLE"  )
void cond::throwException ( std::string const &  message,
std::string const &  methodName 
)
const Time_t cond::TIMELIMIT ( std::numeric_limits< Time_t >::  max())
std::string const & cond::timeTypeNames ( int  i)

Definition at line 15 of file Time.cc.

References i.

Referenced by CondDBESSource::setIntervalFor(), and cond::TimeTypeTraits< type >::specs().

15  {
16  static const std::string local[]=
17  {"runnumber","timestamp","lumiid","hash","userid"};
18  return local[i];
19  }
int i
Definition: DBlmapReader.cc:9
template<class T >
std::string cond::to_string ( const T t)
edm::IOVSyncValue cond::toIOVSyncValue ( cond::Time_t  time,
cond::TimeType  timetype,
bool  startOrStop 
)

Definition at line 7 of file ConvertIOVSyncValue.cc.

References edm::IOVSyncValue::invalidIOVSyncValue(), prof2calltree::l, lumiid, edm::LuminosityBlockID::luminosityBlock(), edm::EventID::maxEventNumber(), edm::LuminosityBlockID::run(), runnumber, and timestamp.

Referenced by CondDBESSource::setIntervalFor().

7  {
8  switch (timetype) {
9  case cond::runnumber :
11  startOrStop ? 0 : edm::EventID::maxEventNumber(),
12  startOrStop ? 0 : edm::EventID::maxEventNumber())
13  );
14  case cond::lumiid :
15  {
17  return edm::IOVSyncValue(edm::EventID(l.run(),
18  l.luminosityBlock(),
19  startOrStop ? 0 : edm::EventID::maxEventNumber())
20  );
21  }
22  case cond::timestamp :
24  default:
26  }
27  }
static EventNumber_t maxEventNumber()
Definition: EventID.h:106
static const IOVSyncValue & invalidIOVSyncValue()
Definition: IOVSyncValue.cc:92
static void cond::topinit ( )
static
unsigned long long cond::toUNIX ( int  date,
int  time 
)

Definition at line 240 of file RPCObImonPyWrapper.cc.

References cond::rpcobgas::day, min, LaserDQM_cfi::mon, and estimatePileup_makeJSON::trunc.

Referenced by cond::PayLoadInspector< DataT >::plot().

241  {
242  int yea_ = (int)date/100;
243  int yea = 2000 + (date - yea_*100);
244  int mon_ = (int)yea_/100;
245  int mon = yea_ - mon_*100;
246  int day = (int)yea_/100;
247  int sec_ = (int)time/100;
248  int sec = time - sec_*100;
249  int min_ = (int)sec_/100;
250  int min = sec_ - min_*100;
251  int hou = (int)sec_/100;
252  int nan = 0;
253  coral::TimeStamp TS;
254  TS = coral::TimeStamp(yea, mon, day, hou, min, sec, nan);
255 
256  long long UT = (TS.year()-1970)*31536000+static_cast<int>(trunc((TS.year()-1972)/4))*86400+
257  (((TS.month()-1)*31)*86400)+((TS.day()-1)*86400)+TS.hour()*3600+TS.minute()*60+TS.second();
258 
259  if (TS.month() == 3) UT = UT - 3*86400;
260  if (TS.month() == 4) UT = UT - 3*86400;
261  if (TS.month() == 5) UT = UT - 4*86400;
262  if (TS.month() == 6) UT = UT - 4*86400;
263  if (TS.month() == 7) UT = UT - 5*86400;
264  if (TS.month() == 8) UT = UT - 5*86400;
265  if (TS.month() == 9) UT = UT - 5*86400;
266  if (TS.month() == 10) UT = UT - 6*86400;
267  if (TS.month() == 11) UT = UT - 6*86400;
268  if (TS.month() == 12) UT = UT - 7*86400;
269 
270  return UT;
271  }
#define min(a, b)
Definition: mlp_lapack.h:161
void cond::updateIOV ( cond::DbSession dbSess,
const boost::shared_ptr< IOVSequence > &  data,
const std::string &  token 
)

Definition at line 38 of file IOVEditor.cc.

References cond::DbSession::isOldSchema(), cond::DbSession::storage(), and cond::DbSession::updateObject().

Referenced by cond::IOVEditor::append(), cond::IOVEditor::bulkAppend(), cond::IOVEditor::editMetadata(), cond::IOVEditor::freeInsert(), cond::IOVImportIterator::importMoreElements(), cond::IOVEditor::insert(), cond::IOVEditor::setScope(), cond::IOVEditor::stamp(), cond::IOVEditor::truncate(), and cond::IOVEditor::updateClosure().

40  {
41  // ***** TEMPORARY FOR TRANSITION PHASE
42  if( dbSess.isOldSchema() ){
43  PoolTokenWriter writer( dbSess.storage() );
44  data->swapOIds( writer );
45  }
46  // *****
47  dbSess.updateObject( data.get(), token );
48  }
bool isOldSchema()
Definition: DbSession.cc:215
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
bool updateObject(const T *object, const std::string &objectId)
Definition: DbSession.h:142
ora::Database & storage()
Definition: DbSession.cc:198
std::string cond::userInfo ( )

Definition at line 9 of file IOVInfo.cc.

References alignCSCRings::pwd, and hcal_dqm_sourceclient-file_cfg::user.

Referenced by cond::service::PoolDBOutputService::appendIOV(), cond::service::PoolDBOutputService::closeIOV(), cond::service::PoolDBOutputService::createNewIOV(), cond::AlignSplitIOV::execute(), cond::IOVImportIterator::importMoreElements(), and popcon::PopCon::write().

9  {
10  // this are really static stuff
11  std::ostringstream user_info;
12  char * user= ::getenv("USER");
13  std::vector<char> hname(1024,'\0');
14  char * hostname = &hname.front();
15  ::gethostname(hostname, 1024);
16  char * pwd = ::getenv("PWD");
17  if (user) { user_info<< "USER=" << user <<";" ;} else { user_info<< "USER="<< "??;";}
18  if (hostname[0] != '\0') {user_info<< "HOSTNAME=" << hostname <<";";}
19  else { user_info<< "HOSTNAME="<< "??;";}
20  if (pwd) {user_info<< "PWD=" << pwd <<";";} else {user_info<< "PWD="<< "??;";}
21  return user_info.str();
22  }
std::string cond::writeToken ( const std::string &  containerName,
int  oid0,
int  oid1,
const std::string &  className 
)

Definition at line 44 of file PoolToken.cc.

References fmt_oid, runonSM::text, and writeTokenContainerFragment().

Referenced by ora::CondMetadataTable::getNamesForObject(), ora::CondMetadataTable::setObjectName(), and cond::PoolTokenWriter::write().

47  {
48  std::string str = writeTokenContainerFragment( containerName, className );
49  char text[128];
50  ::sprintf(text, fmt_oid, oid0, oid1);
51  str += text;
52  return str;
53  }
static const char * fmt_oid
Definition: PoolToken.cc:13
std::string writeTokenContainerFragment(const std::string &containerName, const std::string &className)
Definition: PoolToken.cc:55
tuple text
Definition: runonSM.py:42
std::string className(const T &t)
Definition: ClassName.h:30
std::string cond::writeTokenContainerFragment ( const std::string &  containerName,
const std::string &  className 
)

Definition at line 55 of file PoolToken.cc.

References fmt_tech, genMD5(), ora::Guid::null(), runonSM::text, and ora::Guid::toString().

Referenced by ora::CondMetadataTable::getNamesForContainer(), and writeToken().

56  {
57 
58  char buff[20];
59  std::string clguid("");
60  // first lookup the class guid in the dictionary
61  Reflex::Type containerType = Reflex::Type::ByName( className );
62  if( containerType ){
63  Reflex::PropertyList props = containerType.Properties();
64  if( props.HasProperty("ClassID")){
65  clguid = props.PropertyAsString("ClassID");
66  }
67  }
68  // if not found, generate one...
69  if( clguid.empty() ){
70  genMD5(className,buff);
71  Guid* gd = reinterpret_cast<Guid*>(buff);
72  clguid = gd->toString();
73  }
74  int tech = 0xB01;
75  char text[128];
76  std::string str = "[DB="+Guid::null()+"][CNT=" + containerName + "][CLID="+clguid+"]";
77  ::sprintf(text, fmt_tech, tech);
78  str += text;
79  return str;
80  }
std::string toString() const
Definition: Guid.cc:27
static const char * fmt_tech
Definition: PoolToken.cc:12
void * genMD5(void *buffer, unsigned long len, void *code)
Definition: GenMD5.cc:358
tuple text
Definition: runonSM.py:42
ora::Guid Guid
Definition: Guid.h:26
std::string className(const T &t)
Definition: ClassName.h:30

Variable Documentation

const char* cond::fmt_oid = "[OID=%08X-%08X]"
static

Definition at line 13 of file PoolToken.cc.

Referenced by parseToken(), and writeToken().

const char* cond::fmt_tech = "[TECH=%08X]"
static

Definition at line 12 of file PoolToken.cc.

Referenced by writeTokenContainerFragment().

const std::string cond::tagInventoryTable
const std::string cond::tagTreeTablePrefix
const unsigned int cond::TIMETYPE_LIST_MAX =5

Definition at line 22 of file Time.h.

Referenced by findSpecs().

const cond::TimeType cond::timeTypeList
Initial value:

Definition at line 9 of file Time.cc.

const TimeTypeSpecs cond::timeTypeSpecs
const cond::TimeType cond::timeTypeValues
Initial value:

Definition at line 12 of file Time.cc.