TMySQLStatement Class Reference

#include <TMySQLStatement.h>

Inheritance diagram for TMySQLStatement:

TSQLStatement TObject TObject List of all members.

Public Member Functions

 TMySQLStatement (MYSQL_STMT *stmt, Bool_t errout=kTRUE)
virtual ~TMySQLStatement ()
virtual void Close (Option_t *="")
virtual Int_t GetBufferLength () const
virtual Int_t GetNumParameters ()
virtual Bool_t SetNull (Int_t npar)
virtual Bool_t SetInt (Int_t npar, Int_t value)
virtual Bool_t SetUInt (Int_t npar, UInt_t value)
virtual Bool_t SetLong (Int_t npar, Long_t value)
virtual Bool_t SetLong64 (Int_t npar, Long64_t value)
virtual Bool_t SetULong64 (Int_t npar, ULong64_t value)
virtual Bool_t SetDouble (Int_t npar, Double_t value)
virtual Bool_t SetString (Int_t npar, const char *value, Int_t maxsize=256)
virtual Bool_t SetBinary (Int_t npar, void *mem, Long_t size, Long_t maxsize=0x1000)
virtual Bool_t SetDate (Int_t npar, Int_t year, Int_t month, Int_t day)
virtual Bool_t SetTime (Int_t npar, Int_t hour, Int_t min, Int_t sec)
virtual Bool_t SetDatime (Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec)
virtual Bool_t SetTimestamp (Int_t npar, Int_t year, Int_t month, Int_t day, Int_t hour, Int_t min, Int_t sec, Int_t frac=0)
virtual Bool_t NextIteration ()
virtual Bool_t Process ()
virtual Int_t GetNumAffectedRows ()
virtual Bool_t StoreResult ()
virtual Int_t GetNumFields ()
virtual const char * GetFieldName (Int_t nfield)
virtual Bool_t NextResultRow ()
virtual Bool_t IsNull (Int_t npar)
virtual Int_t GetInt (Int_t npar)
virtual UInt_t GetUInt (Int_t npar)
virtual Long_t GetLong (Int_t npar)
virtual Long64_t GetLong64 (Int_t npar)
virtual ULong64_t GetULong64 (Int_t npar)
virtual Double_t GetDouble (Int_t npar)
virtual const char * GetString (Int_t npar)
virtual Bool_t GetBinary (Int_t npar, void *&mem, Long_t &size)
virtual Bool_t GetDate (Int_t npar, Int_t &year, Int_t &month, Int_t &day)
virtual Bool_t GetTime (Int_t npar, Int_t &hour, Int_t &min, Int_t &sec)
virtual Bool_t GetDatime (Int_t npar, Int_t &year, Int_t &month, Int_t &day, Int_t &hour, Int_t &min, Int_t &sec)
virtual Bool_t GetTimestamp (Int_t npar, Int_t &year, Int_t &month, Int_t &day, Int_t &hour, Int_t &min, Int_t &sec, Int_t &)
 ClassDef (TMySQLStatement, 0)

Static Public Member Functions

static unsigned long GetAllocSizeLimit ()
static void SetAllocSizeLimit (unsigned long sz)

Protected Member Functions

Bool_t IsSetParsMode () const
 indicates when parameters bind should be called
Bool_t IsResultSetMode () const
Bool_t SetSQLParamType (Int_t npar, int sqltype, bool sig, unsigned long sqlsize=0)
long double ConvertToNumeric (Int_t npar)
const char * ConvertToString (Int_t npar)
void FreeBuffers ()
void SetBuffersNumber (Int_t n)
void * BeforeSet (const char *method, Int_t npar, Int_t sqltype, Bool_t sig=kTRUE, unsigned long size=0)

Protected Attributes

MYSQL_STMTfStmt
Int_t fNumBuffers
 executed statement
MYSQL_BINDfBind
 number of statement parameters
TParamDatafBuffer
 array of bind data
Int_t fWorkingMode
 parameter definition structures
Int_t fIterationCount
 1 - setting parameters, 2 - retrieving results
Bool_t fNeedParBind
 number of iteration

Static Protected Attributes

static ULong64_t fgAllocSizeLimit

Classes

struct  TParamData

Detailed Description

Definition at line 38 of file TMySQLStatement.h.


Constructor & Destructor Documentation

TMySQLStatement::TMySQLStatement ( MYSQL_STMT stmt,
Bool_t  errout = kTRUE 
)

TMySQLStatement::~TMySQLStatement (  )  [virtual]

Definition at line 1059 of file TMySQLStatement.cxx.


Member Function Documentation

Bool_t TMySQLStatement::IsSetParsMode (  )  const [inline, protected]

indicates when parameters bind should be called

Definition at line 61 of file TMySQLStatement.h.

References fWorkingMode.

Bool_t TMySQLStatement::IsResultSetMode (  )  const [inline, protected]

Definition at line 62 of file TMySQLStatement.h.

References fWorkingMode.

Bool_t TMySQLStatement::SetSQLParamType ( Int_t  npar,
int  sqltype,
bool  sig,
unsigned long  sqlsize = 0 
) [protected]

Definition at line 1272 of file TMySQLStatement.cxx.

References kFALSE.

long double TMySQLStatement::ConvertToNumeric ( Int_t  npar  )  [protected]

Definition at line 1159 of file TMySQLStatement.cxx.

const char * TMySQLStatement::ConvertToString ( Int_t  npar  )  [protected]

Definition at line 1151 of file TMySQLStatement.cxx.

void TMySQLStatement::FreeBuffers (  )  [protected]

Definition at line 1139 of file TMySQLStatement.cxx.

void TMySQLStatement::SetBuffersNumber ( Int_t  n  )  [protected]

Definition at line 1145 of file TMySQLStatement.cxx.

void * TMySQLStatement::BeforeSet ( const char *  method,
Int_t  npar,
Int_t  sqltype,
Bool_t  sig = kTRUE,
unsigned long  size = 0 
) [protected]

Definition at line 1282 of file TMySQLStatement.cxx.

static unsigned long TMySQLStatement::GetAllocSizeLimit (  )  [inline, static]

Definition at line 80 of file TMySQLStatement.h.

References fgAllocSizeLimit.

static void TMySQLStatement::SetAllocSizeLimit ( unsigned long  sz  )  [inline, static]

Definition at line 81 of file TMySQLStatement.h.

References fgAllocSizeLimit.

void TMySQLStatement::Close ( Option_t = ""  )  [virtual]

Definition at line 1065 of file TMySQLStatement.cxx.

virtual Int_t TMySQLStatement::GetBufferLength (  )  const [inline, virtual]

Implements TSQLStatement.

Definition at line 85 of file TMySQLStatement.h.

Int_t TMySQLStatement::GetNumParameters (  )  [virtual]

Implements TSQLStatement.

Definition at line 1087 of file TMySQLStatement.cxx.

Bool_t TMySQLStatement::SetNull ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1291 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetInt ( Int_t  npar,
Int_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1305 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetUInt ( Int_t  npar,
UInt_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1313 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetLong ( Int_t  npar,
Long_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1321 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetLong64 ( Int_t  npar,
Long64_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1329 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetULong64 ( Int_t  npar,
ULong64_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1337 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetDouble ( Int_t  npar,
Double_t  value 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1345 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetString ( Int_t  npar,
const char *  value,
Int_t  maxsize = 256 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1353 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetBinary ( Int_t  npar,
void *  mem,
Long_t  size,
Long_t  maxsize = 0x1000 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1361 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetDate ( Int_t  npar,
Int_t  year,
Int_t  month,
Int_t  day 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1369 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetTime ( Int_t  npar,
Int_t  hour,
Int_t  min,
Int_t  sec 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1377 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetDatime ( Int_t  npar,
Int_t  year,
Int_t  month,
Int_t  day,
Int_t  hour,
Int_t  min,
Int_t  sec 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1385 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::SetTimestamp ( Int_t  npar,
Int_t  year,
Int_t  month,
Int_t  day,
Int_t  hour,
Int_t  min,
Int_t  sec,
Int_t  frac = 0 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1393 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::NextIteration (  )  [virtual]

Implements TSQLStatement.

Definition at line 1129 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::Process (  )  [virtual]

Implements TSQLStatement.

Definition at line 1071 of file TMySQLStatement.cxx.

References kFALSE.

Int_t TMySQLStatement::GetNumAffectedRows (  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1079 of file TMySQLStatement.cxx.

Bool_t TMySQLStatement::StoreResult (  )  [virtual]

Implements TSQLStatement.

Definition at line 1095 of file TMySQLStatement.cxx.

References kFALSE.

Int_t TMySQLStatement::GetNumFields (  )  [virtual]

Implements TSQLStatement.

Definition at line 1104 of file TMySQLStatement.cxx.

const char * TMySQLStatement::GetFieldName ( Int_t  nfield  )  [virtual]

Implements TSQLStatement.

Definition at line 1112 of file TMySQLStatement.cxx.

Bool_t TMySQLStatement::NextResultRow (  )  [virtual]

Implements TSQLStatement.

Definition at line 1120 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::IsNull ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1167 of file TMySQLStatement.cxx.

References kTRUE.

Int_t TMySQLStatement::GetInt ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1175 of file TMySQLStatement.cxx.

UInt_t TMySQLStatement::GetUInt ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1183 of file TMySQLStatement.cxx.

Long_t TMySQLStatement::GetLong ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1191 of file TMySQLStatement.cxx.

Long64_t TMySQLStatement::GetLong64 ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1199 of file TMySQLStatement.cxx.

ULong64_t TMySQLStatement::GetULong64 ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1207 of file TMySQLStatement.cxx.

Double_t TMySQLStatement::GetDouble ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1215 of file TMySQLStatement.cxx.

const char * TMySQLStatement::GetString ( Int_t  npar  )  [virtual]

Reimplemented from TSQLStatement.

Definition at line 1223 of file TMySQLStatement.cxx.

Bool_t TMySQLStatement::GetBinary ( Int_t  npar,
void *&  mem,
Long_t size 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1231 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::GetDate ( Int_t  npar,
Int_t year,
Int_t month,
Int_t day 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1240 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::GetTime ( Int_t  npar,
Int_t hour,
Int_t min,
Int_t sec 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1248 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::GetDatime ( Int_t  npar,
Int_t year,
Int_t month,
Int_t day,
Int_t hour,
Int_t min,
Int_t sec 
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1256 of file TMySQLStatement.cxx.

References kFALSE.

Bool_t TMySQLStatement::GetTimestamp ( Int_t  npar,
Int_t year,
Int_t month,
Int_t day,
Int_t hour,
Int_t min,
Int_t sec,
Int_t  
) [virtual]

Reimplemented from TSQLStatement.

Definition at line 1264 of file TMySQLStatement.cxx.

References kFALSE.

TMySQLStatement::ClassDef ( TMySQLStatement  ,
 
)


Member Data Documentation

MYSQL_STMT* TMySQLStatement::fStmt [protected]

Definition at line 53 of file TMySQLStatement.h.

Int_t TMySQLStatement::fNumBuffers [protected]

executed statement

Definition at line 54 of file TMySQLStatement.h.

MYSQL_BIND* TMySQLStatement::fBind [protected]

number of statement parameters

Definition at line 55 of file TMySQLStatement.h.

TParamData* TMySQLStatement::fBuffer [protected]

array of bind data

Definition at line 56 of file TMySQLStatement.h.

Int_t TMySQLStatement::fWorkingMode [protected]

parameter definition structures

Definition at line 57 of file TMySQLStatement.h.

Referenced by IsResultSetMode(), and IsSetParsMode().

Int_t TMySQLStatement::fIterationCount [protected]

1 - setting parameters, 2 - retrieving results

Definition at line 58 of file TMySQLStatement.h.

Bool_t TMySQLStatement::fNeedParBind [protected]

number of iteration

Definition at line 59 of file TMySQLStatement.h.

ULong64_t TMySQLStatement::fgAllocSizeLimit [static, protected]

Definition at line 74 of file TMySQLStatement.h.

Referenced by GetAllocSizeLimit(), and SetAllocSizeLimit().


The documentation for this class was generated from the following files:
Generated on Tue Jul 5 16:43:12 2011 for ROOT_528-00b_version by  doxygen 1.5.1