Back to home page

EIC code displayed by LXR

 
 

    


Warning, file /include/root/TSQLMonitoring.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).

0001 // @(#)root/net:$Id$
0002 // Author: J.F. Grosse-Oetringhaus, G.Ganis
0003 
0004 /*************************************************************************
0005  * Copyright (C) 1995-2007, Rene Brun and Fons Rademakers.               *
0006  * All rights reserved.                                                  *
0007  *                                                                       *
0008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
0009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
0010  *************************************************************************/
0011 
0012 #ifndef ROOT_TSQLMonitoring
0013 #define ROOT_TSQLMonitoring
0014 
0015 //////////////////////////////////////////////////////////////////////////
0016 //                                                                      //
0017 // TSQLMonitoringWriter                                                 //
0018 //                                                                      //
0019 // SQL implementation of TVirtualMonitoringWriter.                      //
0020 //                                                                      //
0021 //////////////////////////////////////////////////////////////////////////
0022 
0023 #include "TVirtualMonitoring.h"
0024 #include "TString.h"
0025 
0026 
0027 class TSQLServer;
0028 
0029 
0030 class TSQLMonitoringWriter : public TVirtualMonitoringWriter {
0031 
0032 private:
0033    TSQLServer  *fDB;              // SQL database where to write
0034    TString      fTable;           // SQL table name
0035 
0036    Long64_t     fMaxBulkSize;     // Max packet size for insertions
0037 
0038    Bool_t       fVerbose;         // Verbosity toggle
0039 
0040    TSQLMonitoringWriter(const TSQLMonitoringWriter&) = delete;
0041    TSQLMonitoringWriter& operator=(const TSQLMonitoringWriter&) = delete;
0042 
0043 public:
0044    TSQLMonitoringWriter(const char *serv, const char *user, const char *pass, const char *table);
0045    virtual ~TSQLMonitoringWriter();
0046 
0047    Bool_t SendParameters(TList *values, const char * /*identifier*/) override;
0048 
0049    void Verbose(Bool_t onoff) override { fVerbose = onoff; }
0050 
0051    ClassDefOverride(TSQLMonitoringWriter, 0)   // Sending monitoring data to a SQL DB
0052 };
0053 
0054 #endif