wxSQLite3 4.9.12
|
Holds the complete result set of a SQL query. More...
#include <wxsqlite3.h>
Public Member Functions | |
wxSQLite3Table () | |
Constructor. | |
wxSQLite3Table (const wxSQLite3Table &table) | |
wxSQLite3Table (char **results, int rows, int cols) | |
virtual | ~wxSQLite3Table () |
wxSQLite3Table & | operator= (const wxSQLite3Table &table) |
int | GetColumnCount () const |
Get the number of columns in the result set. | |
int | GetRowCount () const |
Get the number of rows in the result set. | |
int | FindColumnIndex (const wxString &columnName) const |
Find the index of a column by name. | |
wxString | GetColumnName (int columnIndex) const |
Get the name of a column. | |
wxString | GetAsString (int columnIndex) const |
Get a column as a string using the column index. | |
wxString | GetAsString (const wxString &columnName) const |
Get a column as a string using the column name. | |
int | GetInt (int columnIndex, int nullValue=0) const |
Get a column as an integer using the column index. | |
int | GetInt (const wxString &columnName, int nullValue=0) const |
Get a column as an integer using the column name. | |
wxLongLong | GetInt64 (int columnIndex, wxLongLong nullValue=0) const |
Get a column as a 64-bit integer using the column index. | |
wxLongLong | GetInt64 (const wxString &columnName, wxLongLong nullValue=0) const |
Get a column as an integer using the column name. | |
double | GetDouble (int columnIndex, double nullValue=0.0) const |
Get a column as a double using the column index. | |
double | GetDouble (const wxString &columnName, double nullValue=0.0) const |
Get a column as a double using the column name. | |
wxString | GetString (int columnIndex, const wxString &nullValue=wxEmptyString) const |
Get a column as a string using the column index. | |
wxString | GetString (const wxString &columnName, const wxString &nullValue=wxEmptyString) const |
Get a column as a string using the column name. | |
wxDateTime | GetDate (int columnIndex) const |
Get a column as a date value using the column index. | |
wxDateTime | GetDate (const wxString &columnName) const |
Get a column as a date value using the column name. | |
wxDateTime | GetTime (int columnIndex) const |
Get a column as a time value using the column index. | |
wxDateTime | GetTime (const wxString &columnName) const |
Get a column as a time value using the column name. | |
wxDateTime | GetDateTime (int columnIndex) const |
Get a column as a date/time value using the column index. | |
wxDateTime | GetDateTime (const wxString &columnName) const |
Get a column as a date/time value using the column name. | |
bool | GetBool (int columnIndex) const |
Get a column as a boolean using the column index. | |
bool | GetBool (const wxString &columnName) const |
Get a column as a boolean using the column name. | |
bool | IsNull (int columnIndex) const |
Check whether the column selected by index is a NULL value. | |
bool | IsNull (const wxString &columnName) const |
Check whether the column selected by name is a NULL value. | |
void | SetRow (int row) |
Set the current row. | |
void | Finalize () |
Finalize the result set. | |
bool | IsOk () const |
Validate associated SQLite resultset. | |
Holds the complete result set of a SQL query.
wxSQLite3Table::wxSQLite3Table | ( | ) |
Constructor.
wxSQLite3Table::wxSQLite3Table | ( | const wxSQLite3Table & | table | ) |
wxSQLite3Table::wxSQLite3Table | ( | char ** | results, |
int | rows, | ||
int | cols ) |
|
virtual |
void wxSQLite3Table::Finalize | ( | ) |
Finalize the result set.
int wxSQLite3Table::FindColumnIndex | ( | const wxString & | columnName | ) | const |
Find the index of a column by name.
columnName | name of the column |
wxString wxSQLite3Table::GetAsString | ( | const wxString & | columnName | ) | const |
Get a column as a string using the column name.
columnName | name of the column |
double
always using the point character as the decimal separator. This is SQLite default behaviour. Use method wxSQLite3Table::GetDouble to apply correct conversion from string
to double
. wxString wxSQLite3Table::GetAsString | ( | int | columnIndex | ) | const |
Get a column as a string using the column index.
columnIndex | index of the column. Indices start with 0. |
double
always using the point character as the decimal separator. This is SQLite default behaviour. Use method wxSQLite3Table::GetDouble to apply correct conversion from string
to double
. bool wxSQLite3Table::GetBool | ( | const wxString & | columnName | ) | const |
Get a column as a boolean using the column name.
columnName | name of the column |
bool wxSQLite3Table::GetBool | ( | int | columnIndex | ) | const |
Get a column as a boolean using the column index.
columnIndex | index of the column. Indices start with 0. |
int wxSQLite3Table::GetColumnCount | ( | ) | const |
Get the number of columns in the result set.
wxString wxSQLite3Table::GetColumnName | ( | int | columnIndex | ) | const |
Get the name of a column.
columnIndex | index of the column. Indices start with 0. |
wxDateTime wxSQLite3Table::GetDate | ( | const wxString & | columnName | ) | const |
Get a column as a date value using the column name.
columnName | name of the column |
wxDateTime wxSQLite3Table::GetDate | ( | int | columnIndex | ) | const |
Get a column as a date value using the column index.
columnIndex | index of the column. Indices start with 0. |
wxDateTime wxSQLite3Table::GetDateTime | ( | const wxString & | columnName | ) | const |
Get a column as a date/time value using the column name.
columnName | name of the column |
wxDateTime wxSQLite3Table::GetDateTime | ( | int | columnIndex | ) | const |
Get a column as a date/time value using the column index.
columnIndex | index of the column. Indices start with 0. |
double wxSQLite3Table::GetDouble | ( | const wxString & | columnName, |
double | nullValue = 0.0 ) const |
Get a column as a double using the column name.
columnName | name of the column |
nullValue | value to be returned in case the column is NULL |
double wxSQLite3Table::GetDouble | ( | int | columnIndex, |
double | nullValue = 0.0 ) const |
Get a column as a double using the column index.
columnIndex | index of the column. Indices start with 0. |
nullValue | value to be returned in case the column is NULL |
int wxSQLite3Table::GetInt | ( | const wxString & | columnName, |
int | nullValue = 0 ) const |
Get a column as an integer using the column name.
columnName | name of the column |
nullValue | value to be returned in case the column is NULL |
int wxSQLite3Table::GetInt | ( | int | columnIndex, |
int | nullValue = 0 ) const |
Get a column as an integer using the column index.
columnIndex | index of the column. Indices start with 0. |
nullValue | value to be returned in case the column is NULL |
wxLongLong wxSQLite3Table::GetInt64 | ( | const wxString & | columnName, |
wxLongLong | nullValue = 0 ) const |
Get a column as an integer using the column name.
columnName | name of the column |
nullValue | value to be returned in case the column is NULL |
wxLongLong wxSQLite3Table::GetInt64 | ( | int | columnIndex, |
wxLongLong | nullValue = 0 ) const |
Get a column as a 64-bit integer using the column index.
columnIndex | index of the column. Indices start with 0. |
nullValue | value to be returned in case the column is NULL |
int wxSQLite3Table::GetRowCount | ( | ) | const |
Get the number of rows in the result set.
wxString wxSQLite3Table::GetString | ( | const wxString & | columnName, |
const wxString & | nullValue = wxEmptyString ) const |
Get a column as a string using the column name.
columnName | name of the column |
nullValue | value to be returned in case the column is NULL |
wxString wxSQLite3Table::GetString | ( | int | columnIndex, |
const wxString & | nullValue = wxEmptyString ) const |
Get a column as a string using the column index.
columnIndex | index of the column. Indices start with 0. |
nullValue | value to be returned in case the column is NULL |
wxDateTime wxSQLite3Table::GetTime | ( | const wxString & | columnName | ) | const |
Get a column as a time value using the column name.
columnName | name of the column |
wxDateTime wxSQLite3Table::GetTime | ( | int | columnIndex | ) | const |
Get a column as a time value using the column index.
columnIndex | index of the column. Indices start with 0. |
bool wxSQLite3Table::IsNull | ( | const wxString & | columnName | ) | const |
Check whether the column selected by name is a NULL value.
columnName | name of the column |
bool wxSQLite3Table::IsNull | ( | int | columnIndex | ) | const |
Check whether the column selected by index is a NULL value.
columnIndex | index of the column. Indices start with 0. |
bool wxSQLite3Table::IsOk | ( | ) | const |
Validate associated SQLite resultset.
wxSQLite3Table & wxSQLite3Table::operator= | ( | const wxSQLite3Table & | table | ) |
void wxSQLite3Table::SetRow | ( | int | row | ) |
Set the current row.
row | index of the requested row. Indices start with 0. |