KDbPreparedStatementInterface
#include <KDbPreparedStatementInterface.h>
Protected Member Functions | |
virtual QSharedPointer< KDbSqlResult > | execute (KDbPreparedStatement::Type type, const KDbField::List &selectFieldList, KDbFieldList *insertFieldList, const KDbPreparedStatementParameters ¶meters)=0 |
virtual bool | prepare (const KDbEscapedString &sql)=0 |
Additional Inherited Members | |
Public Member Functions inherited from KDbResultable | |
KDbResultable (const KDbResultable &other) | |
void | clearResult () |
KDbMessageHandler * | messageHandler () const |
KDbResultable & | operator= (const KDbResultable &other) |
KDbResult | result () const |
virtual QString | serverResultName () const |
void | setMessageHandler (KDbMessageHandler *handler) |
void | showMessage () |
Protected Attributes inherited from KDbResultable | |
Private *const | d |
KDbResult | m_result |
Detailed Description
Prepared statement interface for backend-dependent implementations.
Definition at line 31 of file KDbPreparedStatementInterface.h.
Constructor & Destructor Documentation
◆ KDbPreparedStatementInterface()
|
inlineprotected |
Definition at line 34 of file KDbPreparedStatementInterface.h.
◆ ~KDbPreparedStatementInterface()
|
inlineoverrideprotected |
Definition at line 35 of file KDbPreparedStatementInterface.h.
Member Function Documentation
◆ execute()
|
protectedpure virtual |
For implementation, executes the prepared statement Type of statement is specified by the type parameter.
selectFieldList specifies fields for SELECT statement. insertFieldList is set to list of fields in INSERT statement. Parameters parameters are passed to the statement, usually using binding.
Implemented in SqlitePreparedStatement.
◆ prepare()
|
protectedpure virtual |
For implementation. Initializes the prepared statement in a backend-dependent way using recently generated sql statement. It should be guaranteed that sql is valid and not empty. For example sqlite3_prepare() is used for SQLite. This is called only when d->dirty == true is encountered on execute(), i.e. when attributes of the object (like WHERE field names) change.
Implemented in SqlitePreparedStatement.
The documentation for this class was generated from the following file:
Documentation copyright © 1996-2024 The KDE developers.
Generated on Sat Dec 21 2024 17:00:43 by doxygen 1.12.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.