Logo ROOT  
Reference Guide
TSQLResult.h
Go to the documentation of this file.
1// @(#)root/net:$Id$
2// Author: Fons Rademakers 25/11/99
3
4/*************************************************************************
5 * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6 * All rights reserved. *
7 * *
8 * For the licensing terms see $ROOTSYS/LICENSE. *
9 * For the list of contributors see $ROOTSYS/README/CREDITS. *
10 *************************************************************************/
11
12#ifndef ROOT_TSQLResult
13#define ROOT_TSQLResult
14
15
16//////////////////////////////////////////////////////////////////////////
17// //
18// TSQLResult //
19// //
20// Abstract base class defining interface to a SQL query result. //
21// Objects of this class are created by TSQLServer methods. //
22// //
23// Related classes are TSQLServer and TSQLRow. //
24// //
25//////////////////////////////////////////////////////////////////////////
26
27#include "TObject.h"
28
29class TSQLRow;
30
31class TSQLResult : public TObject {
32
33protected:
34 Int_t fRowCount; // number of rows in result
35
37
38public:
39 virtual ~TSQLResult() {}
40
41 virtual void Close(Option_t *option="") = 0;
42 virtual Int_t GetFieldCount() = 0;
43 virtual const char *GetFieldName(Int_t field) = 0;
44 virtual Int_t GetRowCount() const { return fRowCount; }
45 virtual TSQLRow *Next() = 0;
46
47 ClassDefOverride(TSQLResult,0) // SQL query result
48};
49
50#endif
const char Option_t
Definition: RtypesCore.h:66
#define ClassDefOverride(name, id)
Definition: Rtypes.h:339
Option_t Option_t option
Mother of all ROOT objects.
Definition: TObject.h:37
virtual const char * GetFieldName(Int_t field)=0
virtual Int_t GetRowCount() const
Definition: TSQLResult.h:44
virtual TSQLRow * Next()=0
virtual ~TSQLResult()
Definition: TSQLResult.h:39
Int_t fRowCount
Definition: TSQLResult.h:34
virtual void Close(Option_t *option="")=0
virtual Int_t GetFieldCount()=0