Songbird / Development / Songbird Add-Ons API Documentation

sbIDatabaseQueryCallback Interface Reference

A more complex callback object that can be used to read each row of the results in turn. More...

import "sbIDatabaseQuery.idl";

List of all members.

Public Member Functions

void onQueryError (in long dbError, in AString dbGUID, in AString strQuery)
 Called if the query has an error.
void onQueryStart (in AString dbGUID, in AString strQuery)
 Called for each query that executes.
void onQueryRow (in sbIDatabaseResult dbResultObject, in unsigned long dbRowResult, in unsigned long dbRowTotal)
 Called as each row is added to the result set.
void onQueryEnd (in sbIDatabaseResult dbResultObject, in AString dbGUID, in AString strQuery)
 Called when the query has completed.


Detailed Description

A more complex callback object that can be used to read each row of the results in turn.

This interface is meant to be implemented as a callback by client code.

Clients that simply need to be informed when a query has completed may implement this interface and pass it to sbIDatabaseQuery::addCallback().

NOTE: The callback methods are called from a database thread.

See also:
sbIDatabaseSimpleQueryCallback, sbIDatabaseQuery

Definition at line 84 of file sbIDatabaseQuery.idl.


Member Function Documentation

void sbIDatabaseQueryCallback::onQueryError ( in long  dbError,
in AString  dbGUID,
in AString  strQuery 
)

Called if the query has an error.

NOTE: The onQueryError() method is called from a database thread.

Parameters:
dbError The error code from SQLITE (equivalent to the return from sbIDatabaseQuery::execute)
dbGUID The guid of the database bring queried
strQuery The query string that executed
See also:
sbIDatabaseQuery

void sbIDatabaseQueryCallback::onQueryStart ( in AString  dbGUID,
in AString  strQuery 
)

Called for each query that executes.

NOTE: The onQueryStart() method is called from a database thread.

Parameters:
dbGUID The guid of the database bring queried
strQuery The query string that executed
See also:
sbIDatabaseQuery

void sbIDatabaseQueryCallback::onQueryRow ( in sbIDatabaseResult  dbResultObject,
in unsigned long  dbRowResult,
in unsigned long  dbRowTotal 
)

Called as each row is added to the result set.

NOTE: The onQueryRow() method is called from a database thread.

Parameters:
dbResultObject The result object of the completed query
dbRowResult The current row filled in the result object
dbRowTotal The total rows to be filled in the result object
See also:
sbIDatabaseQuery

void sbIDatabaseQueryCallback::onQueryEnd ( in sbIDatabaseResult  dbResultObject,
in AString  dbGUID,
in AString  strQuery 
)

Called when the query has completed.

NOTE: The onQueryEnd() method is called from a database thread.

Parameters:
dbResultObject The result object of the completed query
dbGUID The guid of the database bring queried
strQuery The query string that executed
See also:
sbIDatabaseQuery


The documentation for this interface was generated from the following file:
Generated on Tue Mar 10 14:28:57 2009 for Songbird by  doxygen 1.5.2