Logo ROOT  
Reference Guide
TOracleRow.h
Go to the documentation of this file.
1// @(#)root/physics:$Id$
2// Author: Yan Liu and Shaowen Wang 23/11/04
3
4/*************************************************************************
5 * Copyright (C) 1995-2005, 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_TOracleRow
13#define ROOT_TOracleRow
14
15#include "TSQLRow.h"
16
17#include <occi.h>
18
19#ifdef CONST
20#undef CONST
21#endif
22
23class TOracleRow : public TSQLRow {
24
25private:
26 oracle::occi::ResultSet *fResult{nullptr}; // current result set
27 std::vector<oracle::occi::MetaData> *fFieldInfo{nullptr}; // metadata for columns
29 char **fFieldsBuffer{nullptr};
30
31 Bool_t IsValid(Int_t field);
32
33 TOracleRow(const TOracleRow&) = delete; // Not implemented.
34 TOracleRow &operator=(const TOracleRow&)= delete; // Not implemented.
35
36protected:
37 void GetRowData();
38
39public:
40 TOracleRow(oracle::occi::ResultSet *rs,
41 std::vector<oracle::occi::MetaData> *fieldMetaData);
43
44 void Close(Option_t *opt="") final;
45 ULong_t GetFieldLength(Int_t field) final;
46 const char *GetField(Int_t field) final;
47
48 ClassDefOverride(TOracleRow,0) // One row of Oracle query result
49};
50
51#endif
int Int_t
Definition: RtypesCore.h:43
unsigned long ULong_t
Definition: RtypesCore.h:53
bool Bool_t
Definition: RtypesCore.h:61
const char Option_t
Definition: RtypesCore.h:64
#define ClassDefOverride(name, id)
Definition: Rtypes.h:326
~TOracleRow()
Destroy row object.
Definition: TOracleRow.cxx:40
TOracleRow & operator=(const TOracleRow &)=delete
ULong_t GetFieldLength(Int_t field) final
Get length in bytes of specified field.
Definition: TOracleRow.cxx:82
Bool_t IsValid(Int_t field)
Check if row is open and field index within range.
Definition: TOracleRow.cxx:66
TOracleRow(oracle::occi::ResultSet *rs, std::vector< oracle::occi::MetaData > *fieldMetaData)
Int_t fFieldCount
Definition: TOracleRow.h:28
TOracleRow(const TOracleRow &)=delete
std::vector< oracle::occi::MetaData > * fFieldInfo
Definition: TOracleRow.h:27
void GetRowData()
Definition: TOracleRow.cxx:106
void Close(Option_t *opt="") final
Close row.
Definition: TOracleRow.cxx:48
oracle::occi::ResultSet * fResult
Definition: TOracleRow.h:26
const char * GetField(Int_t field) final
Definition: TOracleRow.cxx:94
char ** fFieldsBuffer
Definition: TOracleRow.h:29