TerraLib 4.1
TeFirebirdPortal Class Reference

A concrete implementation of a portal to a Firebird database. More...

#include <TeFirebird.h>

Inheritance diagram for TeFirebirdPortal:
TeDatabasePortal

List of all members.

Public Member Functions

 TeFirebirdPortal (TeFirebird *firebird)
 TeFirebirdPortal (const TeFirebirdPortal &p)
virtual ~TeFirebirdPortal ()
bool query (const string &qry, TeCursorLocation l=TeSERVERSIDE, TeCursorType t=TeUNIDIRECTIONAL, TeCursorEditType e=TeREADONLY, TeCursorDataType dt=TeTEXTCURSOR)
 Executes a SQL query that opens a record set.
bool fetchRow ()
 Fetchs the next row in a record set that shouldve been previously opened.
bool fetchRow (int i)
 Fetchs a particular row.
void freeResult ()
 Frees the current record set.
char * getData (int i)
 Gets the value of the i-th attribute as a literal.
char * getData (const string &s)
 Gets the value of a named attribute as a literal.
double getDouble (int i)
 Gets the value of the i-th attribute as a double.
double getDouble (const string &s)
 Gets the value of a named attribute as a double.
int getInt (int i)
 Gets the value of the i-th attribute as an integer.
int getInt (const string &s)
 Gets the value of a named attribute as an integer.
bool getBool (const string &s)
 Gets the value of a named attribute as a boolean.
bool getBool (int i)
 Gets the value of the i-th attribute as a boolean.
virtual bool fetchGeometry (TePolygon &pol)
virtual bool fetchGeometry (TeLine2D &line)
bool fetchGeometry (TeNode &n)
bool fetchGeometry (TePoint &p)
virtual bool fetchGeometry (TePolygon &pol, const unsigned int &initIndex)
virtual bool fetchGeometry (TeLine2D &line, const unsigned int &initIndex)
bool fetchGeometry (TeNode &n, const unsigned int &initIndex)
bool fetchGeometry (TePoint &p, const unsigned int &initIndex)
bool setData (int, string)
bool getBlob (const int &column, unsigned char *&data, unsigned long &size)
bool getBlob (const string &s, unsigned char *&data, long &size)
 Gets the value of a named BLOB attribute.
bool getRasterBlock (unsigned long &size, unsigned char *ptData)
TeTime getDate (int i)
 Gets the value of the i-th attribute as a date.
TeTime getDate (const string &s)
 Gets the value of a named attribute as a date.
string getDateAsString (int i)
 Gets the of a date/time attribute as a string formatted as accepted in further SQL statements.
string getDateAsString (const string &s)
 Gets the of a date/time attribute as a string formatted as accepted in further SQL statements.

Protected Member Functions

virtual TeLinearRing getLinearRing (int &ni)

Protected Attributes

IBPP::Database firebird_
IBPP::Statement result_
IBPP::Transaction transaction_
std::string data_
std::string query_
int currRow_

Detailed Description

A concrete implementation of a portal to a Firebird database.


Constructor & Destructor Documentation

TeFirebirdPortal::TeFirebirdPortal ( TeFirebird firebird)
TeFirebirdPortal::TeFirebirdPortal ( const TeFirebirdPortal p)
TeFirebirdPortal::~TeFirebirdPortal ( ) [virtual]

Member Function Documentation

bool TeFirebirdPortal::fetchGeometry ( TePolygon pol) [virtual]

Implements TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TePoint p) [virtual]

Implements TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TePolygon pol,
const unsigned int &  initIndex 
) [virtual]

Reimplemented from TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TeLine2D line,
const unsigned int &  initIndex 
) [virtual]

Reimplemented from TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TeNode n,
const unsigned int &  initIndex 
) [virtual]

Reimplemented from TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TePoint p,
const unsigned int &  initIndex 
) [virtual]

Reimplemented from TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TeLine2D line) [virtual]

Implements TeDatabasePortal.

bool TeFirebirdPortal::fetchGeometry ( TeNode n) [virtual]

Implements TeDatabasePortal.

bool TeFirebirdPortal::fetchRow ( int  i) [virtual]

Fetchs a particular row.

Implements TeDatabasePortal.

bool TeFirebirdPortal::fetchRow ( ) [virtual]

Fetchs the next row in a record set that shouldve been previously opened.

Implements TeDatabasePortal.

void TeFirebirdPortal::freeResult ( ) [virtual]

Frees the current record set.

Implements TeDatabasePortal.

bool TeFirebirdPortal::getBlob ( const int &  column,
unsigned char *&  data,
unsigned long &  size 
)
bool TeFirebirdPortal::getBlob ( const string s,
unsigned char *&  data,
long &  size 
) [virtual]

Gets the value of a named BLOB attribute.

Implements TeDatabasePortal.

bool TeFirebirdPortal::getBool ( const string s) [virtual]

Gets the value of a named attribute as a boolean.

Implements TeDatabasePortal.

bool TeFirebirdPortal::getBool ( int  i) [virtual]

Gets the value of the i-th attribute as a boolean.

Implements TeDatabasePortal.

char * TeFirebirdPortal::getData ( const string s) [virtual]

Gets the value of a named attribute as a literal.

Implements TeDatabasePortal.

char * TeFirebirdPortal::getData ( int  i) [virtual]

Gets the value of the i-th attribute as a literal.

Implements TeDatabasePortal.

TeTime TeFirebirdPortal::getDate ( int  i) [virtual]

Gets the value of the i-th attribute as a date.

Implements TeDatabasePortal.

TeTime TeFirebirdPortal::getDate ( const string s) [virtual]

Gets the value of a named attribute as a date.

Implements TeDatabasePortal.

string TeFirebirdPortal::getDateAsString ( int  i) [virtual]

Gets the of a date/time attribute as a string formatted as accepted in further SQL statements.

Implements TeDatabasePortal.

string TeFirebirdPortal::getDateAsString ( const string s) [virtual]

Gets the of a date/time attribute as a string formatted as accepted in further SQL statements.

Implements TeDatabasePortal.

double TeFirebirdPortal::getDouble ( const string s) [virtual]

Gets the value of a named attribute as a double.

Reimplemented from TeDatabasePortal.

double TeFirebirdPortal::getDouble ( int  i) [virtual]

Gets the value of the i-th attribute as a double.

Reimplemented from TeDatabasePortal.

int TeFirebirdPortal::getInt ( const string s) [virtual]

Gets the value of a named attribute as an integer.

Reimplemented from TeDatabasePortal.

int TeFirebirdPortal::getInt ( int  i) [virtual]

Gets the value of the i-th attribute as an integer.

Reimplemented from TeDatabasePortal.

TeLinearRing TeFirebirdPortal::getLinearRing ( int &  ni) [protected, virtual]
bool TeFirebirdPortal::getRasterBlock ( unsigned long &  size,
unsigned char *  ptData 
) [virtual]

Implements TeDatabasePortal.

bool TeFirebirdPortal::query ( const string qry,
TeCursorLocation  l = TeSERVERSIDE,
TeCursorType  t = TeUNIDIRECTIONAL,
TeCursorEditType  e = TeREADONLY,
TeCursorDataType  dt = TeTEXTCURSOR 
) [virtual]

Executes a SQL query that opens a record set.

Implements TeDatabasePortal.

bool TeFirebirdPortal::setData ( int  ,
string   
) [inline]

Member Data Documentation

int TeFirebirdPortal::currRow_ [protected]

The documentation for this class was generated from the following files:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines