TSapDBRow.h

Go to the documentation of this file.
00001 // @(#)root/sapdb:$Id: TSapDBRow.h 20882 2007-11-19 11:31:26Z rdm $
00002 // Author: Mark Hemberger & Fons Rademakers   03/08/2001
00003 
00004 /*************************************************************************
00005  * Copyright (C) 1995-2001, Rene Brun and Fons Rademakers.               *
00006  * All rights reserved.                                                  *
00007  *                                                                       *
00008  * For the licensing terms see $ROOTSYS/LICENSE.                         *
00009  * For the list of contributors see $ROOTSYS/README/CREDITS.             *
00010  *************************************************************************/
00011 
00012 #ifndef ROOT_TSapDBRow
00013 #define ROOT_TSapDBRow
00014 
00015 #ifndef ROOT_TSQLRow
00016 #include "TSQLRow.h"
00017 #endif
00018 
00019 #if !defined(__CINT__)
00020 #include <sys/time.h>
00021 #include <WINDOWS.H>
00022 #ifdef min
00023 #undef min
00024 #endif
00025 #ifdef max
00026 #undef max
00027 #endif
00028 #include <sql.h>
00029 #include <sqlext.h>
00030 #else
00031 typedef long SQLHSTMT;
00032 #endif
00033 
00034 class TString;
00035 
00036 
00037 class TSapDBRow : public TSQLRow {
00038 
00039 private:
00040    SQLHSTMT    fResult;       // current result set
00041    Int_t       fFieldCount;   // number of fields in row
00042    ULong_t    *fFieldLength;  // length of each field in the row
00043    TString    *fFieldValue;   // value of each field in the row
00044 
00045    Bool_t  IsValid(Int_t field);
00046 
00047 public:
00048    TSapDBRow(SQLHSTMT fResult, Int_t nfields);
00049    ~TSapDBRow();
00050 
00051    void        Close(Option_t *opt="");
00052    ULong_t     GetFieldLength(Int_t field);
00053    const char *GetField(Int_t field);
00054 
00055    ClassDef(TSapDBRow,0)  // One row of SapDB query result
00056 };
00057 
00058 #endif

Generated on Tue Jul 5 15:14:41 2011 for ROOT_528-00b_version by  doxygen 1.5.1