#include <TSQLServer.h>
Inheritance diagram for TSQLServer:
Public Types | |
enum | ESQLDataTypes |
printf argument for floats and doubles, either "%f" or "%e" or "%10f" and so on More... | |
enum | ESQLDataTypes |
printf argument for floats and doubles, either "%f" or "%e" or "%10f" and so on More... | |
Public Member Functions | |
virtual | ~TSQLServer () |
virtual void | Close (Option_t *option="")=0 |
virtual TSQLResult * | Query (const char *sql)=0 |
virtual Bool_t | Exec (const char *sql) |
virtual TSQLStatement * | Statement (const char *, Int_t=100) |
virtual Bool_t | HasStatement () const |
virtual Int_t | SelectDataBase (const char *dbname)=0 |
virtual TSQLResult * | GetDataBases (const char *wild=0)=0 |
virtual TSQLResult * | GetTables (const char *dbname, const char *wild=0)=0 |
virtual TList * | GetTablesList (const char *wild=0) |
virtual Bool_t | HasTable (const char *tablename) |
virtual TSQLTableInfo * | GetTableInfo (const char *tablename) |
virtual TSQLResult * | GetColumns (const char *dbname, const char *table, const char *wild=0)=0 |
virtual Int_t | GetMaxIdentifierLength () |
virtual Int_t | CreateDataBase (const char *dbname)=0 |
virtual Int_t | DropDataBase (const char *dbname)=0 |
virtual Int_t | Reload ()=0 |
virtual Int_t | Shutdown ()=0 |
virtual const char * | ServerInfo ()=0 |
virtual Bool_t | IsConnected () const |
const char * | GetDBMS () const |
const char * | GetDB () const |
const char * | GetHost () const |
Int_t | GetPort () const |
virtual Bool_t | IsError () const |
virtual Int_t | GetErrorCode () const |
virtual const char * | GetErrorMsg () const |
virtual void | EnableErrorOutput (Bool_t on=kTRUE) |
virtual Bool_t | StartTransaction () |
virtual Bool_t | Commit () |
virtual Bool_t | Rollback () |
virtual Bool_t | PingVerify () |
virtual Int_t | Ping () |
virtual | ~TSQLServer () |
virtual void | Close (Option_t *option="")=0 |
virtual TSQLResult * | Query (const char *sql)=0 |
virtual Bool_t | Exec (const char *sql) |
virtual TSQLStatement * | Statement (const char *, Int_t=100) |
virtual Bool_t | HasStatement () const |
virtual Int_t | SelectDataBase (const char *dbname)=0 |
virtual TSQLResult * | GetDataBases (const char *wild=0)=0 |
virtual TSQLResult * | GetTables (const char *dbname, const char *wild=0)=0 |
virtual TList * | GetTablesList (const char *wild=0) |
virtual Bool_t | HasTable (const char *tablename) |
virtual TSQLTableInfo * | GetTableInfo (const char *tablename) |
virtual TSQLResult * | GetColumns (const char *dbname, const char *table, const char *wild=0)=0 |
virtual Int_t | GetMaxIdentifierLength () |
virtual Int_t | CreateDataBase (const char *dbname)=0 |
virtual Int_t | DropDataBase (const char *dbname)=0 |
virtual Int_t | Reload ()=0 |
virtual Int_t | Shutdown ()=0 |
virtual const char * | ServerInfo ()=0 |
virtual Bool_t | IsConnected () const |
const char * | GetDBMS () const |
const char * | GetDB () const |
const char * | GetHost () const |
Int_t | GetPort () const |
virtual Bool_t | IsError () const |
virtual Int_t | GetErrorCode () const |
virtual const char * | GetErrorMsg () const |
virtual void | EnableErrorOutput (Bool_t on=kTRUE) |
virtual Bool_t | StartTransaction () |
virtual Bool_t | Commit () |
virtual Bool_t | Rollback () |
virtual Bool_t | PingVerify () |
virtual Int_t | Ping () |
Static Public Member Functions | |
static TSQLServer * | Connect (const char *db, const char *uid, const char *pw) |
static void | SetFloatFormat (const char *fmt="%e") |
static const char * | GetFloatFormat () |
static TSQLServer * | Connect (const char *db, const char *uid, const char *pw) |
static void | SetFloatFormat (const char *fmt="%e") |
static const char * | GetFloatFormat () |
Protected Member Functions | |
TSQLServer () | |
void | ClearError () |
void | SetError (Int_t code, const char *msg, const char *method=0) |
TSQLServer () | |
void | ClearError () |
void | SetError (Int_t code, const char *msg, const char *method=0) |
Protected Attributes | |
TString | fType |
TString | fHost |
TString | fDB |
Int_t | fPort |
Int_t | fErrorCode |
TString | fErrorMsg |
Bool_t | fErrorOut |
Static Protected Attributes | |
static const char * | fgFloatFmt |
static const char * | fgFloatFmt |
Definition at line 45 of file TSQLServer.h.
printf argument for floats and doubles, either "%f" or "%e" or "%10f" and so on
Definition at line 66 of file TSQLServer.h.
printf argument for floats and doubles, either "%f" or "%e" or "%10f" and so on
Definition at line 66 of file TSQLServer.h.
TSQLServer::TSQLServer | ( | ) | [inline, protected] |
virtual TSQLServer::~TSQLServer | ( | ) | [inline, virtual] |
Definition at line 78 of file TSQLServer.h.
TSQLServer::TSQLServer | ( | ) | [inline, protected] |
virtual TSQLServer::~TSQLServer | ( | ) | [inline, virtual] |
Definition at line 78 of file TSQLServer.h.
void TSQLServer::ClearError | ( | ) | [protected] |
Definition at line 111 of file TSQLServer.cxx.
References fErrorCode, and fErrorMsg.
Referenced by TOracleServer::Close(), TMySQLServer::Close(), TMySQLServer::Statement(), and TSQLServer().
void TSQLServer::SetError | ( | Int_t | code, | |
const char * | msg, | |||
const char * | method = 0 | |||
) | [protected] |
Definition at line 120 of file TSQLServer.cxx.
References TObject::Error(), fErrorCode, fErrorMsg, and fErrorOut.
Referenced by TOracleServer::Exec(), TODBCServer::ExtractErrors(), TMySQLServer::GetTableInfo(), TOracleServer::Query(), TODBCServer::StartTransaction(), TMySQLServer::Statement(), TOracleServer::Statement(), TODBCServer::Statement(), and TOracleServer::TOracleServer().
virtual void TSQLServer::Close | ( | Option_t * | option = "" |
) | [pure virtual] |
virtual TSQLResult* TSQLServer::Query | ( | const char * | sql | ) | [pure virtual] |
Referenced by TTreeSQL::CreateBranch(), TTreeSQL::CreateTable(), Exec(), TTreeSQL::Fill(), TTreeSQL::GetEntries(), TProofServ::GetPriority(), TTreeSQL::Init(), TTreeSQL::PrepEntry(), TSQLMonitoringWriter::SendParameters(), sqlcreatedb(), sqlfilldb(), TSQLFile::SQLQuery(), sqlselect(), and TPerfStats::WriteQueryLog().
Bool_t TSQLServer::Exec | ( | const char * | sql | ) | [virtual] |
Definition at line 75 of file TSQLServer.cxx.
References IsError(), kFALSE, and Query().
Referenced by Commit(), Rollback(), TSQLFile::SQLQuery(), and StartTransaction().
virtual TSQLStatement* TSQLServer::Statement | ( | const char * | , | |
Int_t | = 100 | |||
) | [inline, virtual] |
Definition at line 83 of file TSQLServer.h.
References TObject::AbstractMethod().
Referenced by TSQLFile::SQLStatement().
virtual Bool_t TSQLServer::HasStatement | ( | ) | const [inline, virtual] |
Definition at line 85 of file TSQLServer.h.
References kFALSE.
Referenced by TSQLFile::SQLCanStatement(), and TSQLFile::SQLStatement().
virtual Int_t TSQLServer::SelectDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual TSQLResult* TSQLServer::GetDataBases | ( | const char * | wild = 0 |
) | [pure virtual] |
Referenced by sqlselect().
virtual TSQLResult* TSQLServer::GetTables | ( | const char * | dbname, | |
const char * | wild = 0 | |||
) | [pure virtual] |
Referenced by TTreeSQL::CheckTable(), GetTablesList(), and sqlselect().
TList * TSQLServer::GetTablesList | ( | const char * | wild = 0 |
) | [virtual] |
Definition at line 159 of file TSQLServer.cxx.
References TList::Add(), TString::Data(), fDB, GetTables(), kTRUE, row, and TCollection::SetOwner().
Referenced by HasTable(), and TSQLFile::SQLDeleteAllTables().
Bool_t TSQLServer::HasTable | ( | const char * | tablename | ) | [virtual] |
Definition at line 199 of file TSQLServer.cxx.
References GetTablesList(), kFALSE, and kTRUE.
Referenced by TSQLFile::SQLTestTable().
TSQLTableInfo * TSQLServer::GetTableInfo | ( | const char * | tablename | ) | [virtual] |
Definition at line 226 of file TSQLServer.cxx.
References TList::Add(), TString::Data(), fDB, GetColumns(), and row.
virtual TSQLResult* TSQLServer::GetColumns | ( | const char * | dbname, | |
const char * | table, | |||
const char * | wild = 0 | |||
) | [pure virtual] |
Referenced by TTreeSQL::CheckTable(), TTreeSQL::GetColumnIndice(), GetTableInfo(), TTreeSQL::Init(), and sqlselect().
virtual Int_t TSQLServer::GetMaxIdentifierLength | ( | ) | [inline, virtual] |
virtual Int_t TSQLServer::CreateDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual Int_t TSQLServer::DropDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual Int_t TSQLServer::Reload | ( | ) | [pure virtual] |
virtual Int_t TSQLServer::Shutdown | ( | ) | [pure virtual] |
virtual const char* TSQLServer::ServerInfo | ( | ) | [pure virtual] |
Referenced by sqlselect().
virtual Bool_t TSQLServer::IsConnected | ( | ) | const [inline, virtual] |
Definition at line 99 of file TSQLServer.h.
References fPort, kFALSE, and kTRUE.
Referenced by TSapDBServer::CreateDataBase(), TPgSQLServer::CreateDataBase(), TSapDBServer::DropDataBase(), TPgSQLServer::DropDataBase(), TPgSQLServer::GetColumns(), TSapDBServer::GetColumns(), TSapDBServer::GetDataBases(), TPgSQLServer::GetDataBases(), TSapDBServer::GetTables(), TPgSQLServer::GetTables(), TPgSQLServer::Query(), TSapDBServer::Query(), TPgSQLServer::Reload(), TSapDBServer::Reload(), TSapDBServer::SelectDataBase(), TPgSQLServer::SelectDataBase(), TSapDBServer::ServerInfo(), TPgSQLServer::ServerInfo(), TSapDBServer::Shutdown(), TPgSQLServer::Shutdown(), TMySQLServer::~TMySQLServer(), TODBCServer::~TODBCServer(), TPgSQLServer::~TPgSQLServer(), and TSapDBServer::~TSapDBServer().
const char* TSQLServer::GetDBMS | ( | ) | const [inline] |
const char* TSQLServer::GetDB | ( | ) | const [inline] |
const char* TSQLServer::GetHost | ( | void | ) | const [inline] |
Definition at line 102 of file TSQLServer.h.
References TString::Data(), and fHost.
Referenced by sqlselect().
Int_t TSQLServer::GetPort | ( | ) | const [inline] |
virtual Bool_t TSQLServer::IsError | ( | ) | const [inline, virtual] |
Definition at line 105 of file TSQLServer.h.
References GetErrorCode().
Referenced by TMySQLServer::Exec(), Exec(), and TMySQLServer::PingVerify().
Int_t TSQLServer::GetErrorCode | ( | ) | const [virtual] |
Definition at line 91 of file TSQLServer.cxx.
References fErrorCode.
Referenced by GetErrorMsg(), and IsError().
const char * TSQLServer::GetErrorMsg | ( | ) | const [virtual] |
Definition at line 101 of file TSQLServer.cxx.
References TString::Data(), fErrorMsg, and GetErrorCode().
Bool_t TSQLServer::StartTransaction | ( | ) | [virtual] |
Definition at line 132 of file TSQLServer.cxx.
References Exec().
Referenced by TSQLFile::SQLStartTransaction(), and TMySQLServer::StartTransaction().
Bool_t TSQLServer::Commit | ( | ) | [virtual] |
Definition at line 141 of file TSQLServer.cxx.
References Exec().
Referenced by TMySQLServer::Commit(), and TSQLFile::SQLCommit().
Bool_t TSQLServer::Rollback | ( | ) | [virtual] |
Definition at line 150 of file TSQLServer.cxx.
References Exec().
Referenced by TMySQLServer::Rollback(), and TSQLFile::SQLRollback().
virtual Bool_t TSQLServer::PingVerify | ( | ) | [inline, virtual] |
virtual Int_t TSQLServer::Ping | ( | ) | [inline, virtual] |
Definition at line 115 of file TSQLServer.h.
static TSQLServer* TSQLServer::Connect | ( | const char * | db, | |
const char * | uid, | |||
const char * | pw | |||
) | [static] |
void TSQLServer::SetFloatFormat | ( | const char * | fmt = "%e" |
) | [static] |
Definition at line 252 of file TSQLServer.cxx.
References fgFloatFmt.
Referenced by G__G__Net_275_0_37(), G__setup_memfuncTSQLServer(), and TBufferSQL2::SetFloatFormat().
const char * TSQLServer::GetFloatFormat | ( | ) | [static] |
Definition at line 261 of file TSQLServer.cxx.
References fgFloatFmt.
Referenced by TODBCStatement::ConvertToString(), G__G__Net_275_0_38(), G__setup_memfuncTSQLServer(), TBufferSQL2::GetFloatFormat(), TOracleRow::GetRowData(), TOracleStatement::GetString(), and TBufferSQL2::SqlWriteBasic().
void TSQLServer::ClearError | ( | ) | [protected] |
void TSQLServer::SetError | ( | Int_t | code, | |
const char * | msg, | |||
const char * | method = 0 | |||
) | [protected] |
virtual void TSQLServer::Close | ( | Option_t * | option = "" |
) | [pure virtual] |
virtual TSQLResult* TSQLServer::Query | ( | const char * | sql | ) | [pure virtual] |
virtual Bool_t TSQLServer::Exec | ( | const char * | sql | ) | [virtual] |
virtual TSQLStatement* TSQLServer::Statement | ( | const char * | , | |
Int_t | = 100 | |||
) | [inline, virtual] |
virtual Bool_t TSQLServer::HasStatement | ( | ) | const [inline, virtual] |
virtual Int_t TSQLServer::SelectDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual TSQLResult* TSQLServer::GetDataBases | ( | const char * | wild = 0 |
) | [pure virtual] |
virtual TSQLResult* TSQLServer::GetTables | ( | const char * | dbname, | |
const char * | wild = 0 | |||
) | [pure virtual] |
virtual TList* TSQLServer::GetTablesList | ( | const char * | wild = 0 |
) | [virtual] |
virtual Bool_t TSQLServer::HasTable | ( | const char * | tablename | ) | [virtual] |
virtual TSQLTableInfo* TSQLServer::GetTableInfo | ( | const char * | tablename | ) | [virtual] |
virtual TSQLResult* TSQLServer::GetColumns | ( | const char * | dbname, | |
const char * | table, | |||
const char * | wild = 0 | |||
) | [pure virtual] |
virtual Int_t TSQLServer::GetMaxIdentifierLength | ( | ) | [inline, virtual] |
Definition at line 93 of file TSQLServer.h.
virtual Int_t TSQLServer::CreateDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual Int_t TSQLServer::DropDataBase | ( | const char * | dbname | ) | [pure virtual] |
virtual Int_t TSQLServer::Reload | ( | ) | [pure virtual] |
virtual Int_t TSQLServer::Shutdown | ( | ) | [pure virtual] |
virtual const char* TSQLServer::ServerInfo | ( | ) | [pure virtual] |
virtual Bool_t TSQLServer::IsConnected | ( | ) | const [inline, virtual] |
const char* TSQLServer::GetDBMS | ( | ) | const [inline] |
const char* TSQLServer::GetDB | ( | ) | const [inline] |
const char* TSQLServer::GetHost | ( | void | ) | const [inline] |
Int_t TSQLServer::GetPort | ( | ) | const [inline] |
virtual Bool_t TSQLServer::IsError | ( | ) | const [inline, virtual] |
virtual Int_t TSQLServer::GetErrorCode | ( | ) | const [virtual] |
virtual const char* TSQLServer::GetErrorMsg | ( | ) | const [virtual] |
virtual Bool_t TSQLServer::StartTransaction | ( | ) | [virtual] |
virtual Bool_t TSQLServer::Commit | ( | ) | [virtual] |
virtual Bool_t TSQLServer::Rollback | ( | ) | [virtual] |
virtual Bool_t TSQLServer::PingVerify | ( | ) | [inline, virtual] |
virtual Int_t TSQLServer::Ping | ( | ) | [inline, virtual] |
Definition at line 115 of file TSQLServer.h.
static TSQLServer* TSQLServer::Connect | ( | const char * | db, | |
const char * | uid, | |||
const char * | pw | |||
) | [static] |
static void TSQLServer::SetFloatFormat | ( | const char * | fmt = "%e" |
) | [static] |
static const char* TSQLServer::GetFloatFormat | ( | ) | [static] |
TString TSQLServer::fType [protected] |
Definition at line 48 of file TSQLServer.h.
Referenced by GetDBMS(), and TOracleServer::TOracleServer().
TString TSQLServer::fHost [protected] |
Definition at line 49 of file TSQLServer.h.
Referenced by GetHost(), TPgSQLServer::SelectDataBase(), and TOracleServer::TOracleServer().
TString TSQLServer::fDB [protected] |
Definition at line 50 of file TSQLServer.h.
Referenced by TSapDBServer::GetDataBases(), GetDB(), GetTableInfo(), GetTablesList(), TSapDBServer::SelectDataBase(), TODBCServer::SelectDataBase(), TMySQLServer::SelectDataBase(), TPgSQLServer::SelectDataBase(), and TOracleServer::TOracleServer().
Int_t TSQLServer::fPort [protected] |
Definition at line 51 of file TSQLServer.h.
Referenced by TOracleServer::Close(), TSapDBServer::Close(), TPgSQLServer::Close(), TMySQLServer::Close(), TODBCServer::Close(), GetPort(), IsConnected(), TPgSQLServer::SelectDataBase(), and TOracleServer::TOracleServer().
Int_t TSQLServer::fErrorCode [protected] |
Definition at line 52 of file TSQLServer.h.
Referenced by ClearError(), GetErrorCode(), and SetError().
TString TSQLServer::fErrorMsg [protected] |
Definition at line 53 of file TSQLServer.h.
Referenced by ClearError(), GetErrorMsg(), and SetError().
Bool_t TSQLServer::fErrorOut [protected] |
Definition at line 54 of file TSQLServer.h.
Referenced by EnableErrorOutput(), SetError(), TMySQLServer::Statement(), TOracleServer::Statement(), and TODBCServer::Statement().
const char* TSQLServer::fgFloatFmt [static, protected] |
const char* TSQLServer::fgFloatFmt [static, protected] |
Definition at line 63 of file TSQLServer.h.