LibreOffice Module connectivity (master) 1
|
#include <PreparedStatement.hxx>
Public Member Functions | |
DECLARE_SERVICE_INFO () | |
OPreparedStatement (Connection *_pConnection, const OUString &sql) | |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) override |
virtual void SAL_CALL | acquire () noexcept override |
virtual void SAL_CALL | release () noexcept override |
virtual css::uno::Sequence< css::uno::Type > SAL_CALL | getTypes () override |
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL | executeQuery () override |
virtual sal_Int32 SAL_CALL | executeUpdate () override |
virtual sal_Bool SAL_CALL | execute () override |
virtual css::uno::Reference< css::sdbc::XConnection > SAL_CALL | getConnection () override |
virtual void SAL_CALL | setNull (sal_Int32 nIndex, sal_Int32 nValue) override |
virtual void SAL_CALL | setObjectNull (sal_Int32 parameterIndex, sal_Int32 sqlType, const OUString &typeName) override |
virtual void SAL_CALL | setBoolean (sal_Int32 nIndex, sal_Bool nValue) override |
virtual void SAL_CALL | setByte (sal_Int32 nIndex, sal_Int8 nValue) override |
virtual void SAL_CALL | setShort (sal_Int32 nIndex, sal_Int16 nValue) override |
virtual void SAL_CALL | setInt (sal_Int32 nIndex, sal_Int32 nValue) override |
virtual void SAL_CALL | setLong (sal_Int32 nIndex, sal_Int64 nValue) override |
virtual void SAL_CALL | setFloat (sal_Int32 parameterIndex, float x) override |
virtual void SAL_CALL | setDouble (sal_Int32 parameterIndex, double x) override |
virtual void SAL_CALL | setString (sal_Int32 parameterIndex, const OUString &x) override |
virtual void SAL_CALL | setBytes (sal_Int32 parameterIndex, const css::uno::Sequence< sal_Int8 > &x) override |
virtual void SAL_CALL | setDate (sal_Int32 parameterIndex, const css::util::Date &x) override |
virtual void SAL_CALL | setTime (sal_Int32 parameterIndex, const css::util::Time &x) override |
virtual void SAL_CALL | setTimestamp (sal_Int32 parameterIndex, const css::util::DateTime &x) override |
virtual void SAL_CALL | setBinaryStream (sal_Int32 parameterIndex, const css::uno::Reference< css::io::XInputStream > &x, sal_Int32 length) override |
virtual void SAL_CALL | setCharacterStream (sal_Int32 parameterIndex, const css::uno::Reference< css::io::XInputStream > &x, sal_Int32 length) override |
virtual void SAL_CALL | setObject (sal_Int32 parameterIndex, const css::uno::Any &x) override |
virtual void SAL_CALL | setObjectWithInfo (sal_Int32 parameterIndex, const css::uno::Any &x, sal_Int32 targetSqlType, sal_Int32 scale) override |
virtual void SAL_CALL | setRef (sal_Int32 parameterIndex, const css::uno::Reference< css::sdbc::XRef > &x) override |
virtual void SAL_CALL | setBlob (sal_Int32 parameterIndex, const css::uno::Reference< css::sdbc::XBlob > &x) override |
virtual void SAL_CALL | setClob (sal_Int32 parameterIndex, const css::uno::Reference< css::sdbc::XClob > &x) override |
virtual void SAL_CALL | setArray (sal_Int32 parameterIndex, const css::uno::Reference< css::sdbc::XArray > &x) override |
virtual void SAL_CALL | clearParameters () override |
virtual void SAL_CALL | addBatch () override |
virtual void SAL_CALL | clearBatch () override |
virtual css::uno::Sequence< sal_Int32 > SAL_CALL | executeBatch () override |
virtual void SAL_CALL | close () override |
virtual void SAL_CALL | disposing () override |
virtual css::uno::Reference< css::sdbc::XResultSetMetaData > SAL_CALL | getMetaData () override |
Public Member Functions inherited from connectivity::firebird::OStatementCommonBase | |
OStatementCommonBase (Connection *_pConnection) | |
virtual void SAL_CALL | disposing () override |
virtual void SAL_CALL | release () noexcept override |
virtual void SAL_CALL | acquire () noexcept override |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) override |
virtual css::uno::Sequence< css::uno::Type > SAL_CALL | getTypes () override |
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL | getPropertySetInfo () override |
virtual css::uno::Any SAL_CALL | getWarnings () override |
virtual void SAL_CALL | clearWarnings () override |
virtual css::uno::Reference< css::sdbc::XResultSet > SAL_CALL | getResultSet () override |
virtual sal_Int32 SAL_CALL | getUpdateCount () override |
virtual sal_Bool SAL_CALL | getMoreResults () override |
virtual void SAL_CALL | cancel () override |
virtual void SAL_CALL | close () override |
Public Member Functions inherited from cppu::OPropertySetHelper | |
OPropertySetHelper (OBroadcastHelper &rBHelper) | |
OPropertySetHelper (OBroadcastHelper &rBHelper, bool bIgnoreRuntimeExceptionsWhileFiring) | |
OPropertySetHelper (OBroadcastHelper &rBHelper, IEventNotificationHook *i_pFireEvents, bool bIgnoreRuntimeExceptionsWhileFiring=false) | |
virtual css::uno::Any SAL_CALL | queryInterface (const css::uno::Type &rType) SAL_OVERRIDE |
css::uno::Sequence< css::uno::Type > | getTypes () |
void SAL_CALL | disposing () |
virtual void SAL_CALL | setPropertyValue (const ::rtl::OUString &rPropertyName, const css::uno::Any &aValue) SAL_OVERRIDE |
virtual css::uno::Any SAL_CALL | getPropertyValue (const ::rtl::OUString &aPropertyName) SAL_OVERRIDE |
virtual void SAL_CALL | addPropertyChangeListener (const ::rtl::OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &aListener) SAL_OVERRIDE |
virtual void SAL_CALL | removePropertyChangeListener (const ::rtl::OUString &aPropertyName, const css::uno::Reference< css::beans::XPropertyChangeListener > &aListener) SAL_OVERRIDE |
virtual void SAL_CALL | addVetoableChangeListener (const ::rtl::OUString &aPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) SAL_OVERRIDE |
virtual void SAL_CALL | removeVetoableChangeListener (const ::rtl::OUString &aPropertyName, const css::uno::Reference< css::beans::XVetoableChangeListener > &aListener) SAL_OVERRIDE |
virtual void SAL_CALL | setFastPropertyValue (sal_Int32 nHandle, const css::uno::Any &rValue) SAL_OVERRIDE |
virtual css::uno::Any SAL_CALL | getFastPropertyValue (sal_Int32 nHandle) SAL_OVERRIDE |
virtual void SAL_CALL | setPropertyValues (const css::uno::Sequence< ::rtl::OUString > &PropertyNames, const css::uno::Sequence< css::uno::Any > &Values) SAL_OVERRIDE |
virtual css::uno::Sequence< css::uno::Any > SAL_CALL | getPropertyValues (const css::uno::Sequence< ::rtl::OUString > &PropertyNames) SAL_OVERRIDE |
virtual void SAL_CALL | addPropertiesChangeListener (const css::uno::Sequence< ::rtl::OUString > &PropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &Listener) SAL_OVERRIDE |
virtual void SAL_CALL | removePropertiesChangeListener (const css::uno::Reference< css::beans::XPropertiesChangeListener > &Listener) SAL_OVERRIDE |
virtual void SAL_CALL | firePropertiesChangeEvent (const css::uno::Sequence< ::rtl::OUString > &PropertyNames, const css::uno::Reference< css::beans::XPropertiesChangeListener > &Listener) SAL_OVERRIDE |
Public Member Functions inherited from connectivity::firebird::OPropertyArrayUsageHelper< OStatementCommonBase > | |
OPropertyArrayUsageHelper () | |
virtual | ~OPropertyArrayUsageHelper () |
::cppu::IPropertyArrayHelper * | getArrayHelper () |
call this in the getInfoHelper method of your derived class. More... | |
Public Member Functions inherited from cppu::ImplHelper5< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5 > | |
virtual css::uno::Any SAL_CALL | queryInterface (css::uno::Type const &rType) SAL_OVERRIDE |
virtual css::uno::Sequence< css::uno::Type > SAL_CALL | getTypes () SAL_OVERRIDE |
virtual css::uno::Sequence< sal_Int8 > SAL_CALL | getImplementationId () SAL_OVERRIDE |
Protected Member Functions | |
void | checkParameterIndex (sal_Int32 nParameterIndex) |
template<typename T > | |
void | setValue (sal_Int32 nIndex, const T &nValue, ISC_SHORT nType) |
Set a numeric value in the input SQLDA. More... | |
void | setParameterNull (sal_Int32 nParameterIndex, bool bSetNull=true) |
void | ensurePrepared () |
void | openBlobForWriting (isc_blob_handle &rBlobHandle, ISC_QUAD &rBlobId) |
Assumes that all necessary mutexes have been taken. More... | |
void | closeBlobAfterWriting (isc_blob_handle &rBlobHandle) |
Assumes that all necessary mutexes have been taken. More... | |
void | setClob (sal_Int32 nParamIndex, const OUString &rStr) |
virtual void SAL_CALL | setFastPropertyValue_NoBroadcast (sal_Int32 nHandle, const css::uno::Any &rValue) override |
virtual | ~OPreparedStatement () override |
Protected Member Functions inherited from connectivity::firebird::OStatementCommonBase | |
virtual void | disposeResultSet () |
void | freeStatementHandle () |
virtual ::cppu::IPropertyArrayHelper * | createArrayHelper () const override |
used to implement the creation of the array helper which is shared amongst all instances of the class. More... | |
virtual ::cppu::IPropertyArrayHelper &SAL_CALL | getInfoHelper () override |
virtual sal_Bool SAL_CALL | convertFastPropertyValue (css::uno::Any &rConvertedValue, css::uno::Any &rOldValue, sal_Int32 nHandle, const css::uno::Any &rValue) override |
virtual void SAL_CALL | setFastPropertyValue_NoBroadcast (sal_Int32 nHandle, const css::uno::Any &rValue) override |
virtual void SAL_CALL | getFastPropertyValue (css::uno::Any &rValue, sal_Int32 nHandle) const override |
virtual | ~OStatementCommonBase () override |
void | prepareAndDescribeStatement (std::u16string_view sqlIn, XSQLDA *&pOutSqlda) |
short | getSqlInfoItem (char aInfoItem) |
bool | isDDLStatement () |
sal_Int32 | getStatementChangeCount () |
virtual css::uno::Any SAL_CALL | getFastPropertyValue (sal_Int32 nHandle) override final |
virtual void | getFastPropertyValue (std::unique_lock< std::mutex > &rGuard, css::uno::Any &rValue, sal_Int32 nHandle) const =0 |
Protected Member Functions inherited from cppu::OPropertySetHelper | |
void SAL_CALL | fire (sal_Int32 *pnHandles, const css::uno::Any *pNewValues, const css::uno::Any *pOldValues, sal_Int32 nCount, sal_Bool bVetoable) |
void SAL_CALL | setFastPropertyValues (sal_Int32 nSeqLen, sal_Int32 *pHandles, const css::uno::Any *pValues, sal_Int32 nHitCount) |
virtual IPropertyArrayHelper &SAL_CALL | getInfoHelper ()=0 |
virtual sal_Bool SAL_CALL | convertFastPropertyValue (css::uno::Any &rConvertedValue, css::uno::Any &rOldValue, sal_Int32 nHandle, const css::uno::Any &rValue)=0 |
virtual void SAL_CALL | setFastPropertyValue_NoBroadcast (sal_Int32 nHandle, const css::uno::Any &rValue)=0 |
virtual void SAL_CALL | getFastPropertyValue (css::uno::Any &rValue, sal_Int32 nHandle) const=0 |
void | setDependentFastPropertyValue (sal_Int32 i_handle, const css::uno::Any &i_value) |
~OPropertySetHelper () | |
virtual ::cppu::IPropertyArrayHelper * | createArrayHelper () const=0 |
used to implement the creation of the array helper which is shared amongst all instances of the class. More... | |
Protected Member Functions inherited from cppu::ImplHelper5< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5 > | |
~ImplHelper5 () SAL_NOEXCEPT | |
Protected Attributes | |
OUString | m_sSqlStatement |
css::uno::Reference< css::sdbc::XResultSetMetaData > | m_xMetaData |
XSQLDA * | m_pOutSqlda |
XSQLDA * | m_pInSqlda |
Protected Attributes inherited from connectivity::firebird::OStatementCommonBase | |
::osl::Mutex | m_aMutex |
css::uno::Reference< css::sdbc::XResultSet > | m_xResultSet |
::rtl::Reference< Connection > | m_pConnection |
ISC_STATUS_ARRAY | m_statusVector |
isc_stmt_handle | m_aStatementHandle |
Protected Attributes inherited from cppu::OPropertySetHelper | |
OBroadcastHelper & | rBHelper |
OMultiTypeInterfaceContainerHelperInt32 | aBoundLC |
OMultiTypeInterfaceContainerHelperInt32 | aVetoableLC |
Impl *const | m_pReserved |
Additional Inherited Members | |
Static Public Member Functions inherited from cppu::OPropertySetHelper | |
static css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL | createPropertySetInfo (IPropertyArrayHelper &rProperties) |
Static Protected Attributes inherited from connectivity::firebird::OPropertyArrayUsageHelper< OStatementCommonBase > | |
static sal_Int32 | s_nRefCount |
::cppu::IPropertyArrayHelper * | s_pProps |
::osl::Mutex | s_aMutex |
Definition at line 44 of file drivers/firebird/PreparedStatement.hxx.
|
overrideprotectedvirtual |
Definition at line 115 of file firebird/PreparedStatement.cxx.
OPreparedStatement::OPreparedStatement | ( | Connection * | _pConnection, |
const OUString & | sql | ||
) |
Definition at line 56 of file firebird/PreparedStatement.cxx.
References SAL_INFO.
|
overridevirtualnoexcept |
Reimplemented from connectivity::firebird::OStatementCommonBase.
Definition at line 119 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::OStatementCommonBase::acquire().
|
overridevirtual |
Definition at line 1002 of file firebird/PreparedStatement.cxx.
|
protected |
css::sdbc::SQLException | |
css::uno::RuntimeException |
Definition at line 1030 of file firebird/PreparedStatement.cxx.
References ensurePrepared(), m_pInSqlda, and dbtools::throwSQLException().
Referenced by setClob(), setNull(), setObjectNull(), setString(), and setValue().
|
overridevirtual |
Definition at line 997 of file firebird/PreparedStatement.cxx.
|
overridevirtual |
Definition at line 992 of file firebird/PreparedStatement.cxx.
|
overridevirtual |
Reimplemented from connectivity::firebird::OStatementCommonBase.
Definition at line 156 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), connectivity::firebird::OStatementCommonBase::close(), connectivity::firebird::freeSQLVAR(), connectivity::firebird::OStatementCommonBase::m_aMutex, m_pInSqlda, and m_pOutSqlda.
Referenced by disposing().
|
protected |
Assumes that all necessary mutexes have been taken.
Definition at line 576 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::evaluateStatusVector(), connectivity::firebird::OStatementCommonBase::m_statusVector, and u.
Referenced by setClob().
connectivity::firebird::OPreparedStatement::DECLARE_SERVICE_INFO | ( | ) |
|
overridevirtual |
Reimplemented from connectivity::firebird::OStatementCommonBase.
Definition at line 176 of file firebird/PreparedStatement.cxx.
References close().
|
protected |
css::sdbc::SQLException | |
css::uno::RuntimeException |
Definition at line 67 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), connectivity::firebird::evaluateStatusVector(), connectivity::firebird::OStatementCommonBase::m_aMutex, connectivity::firebird::OStatementCommonBase::m_aStatementHandle, m_pInSqlda, m_pOutSqlda, m_sSqlStatement, connectivity::firebird::OStatementCommonBase::m_statusVector, connectivity::firebird::mallocSQLVAR(), connectivity::firebird::OStatementCommonBase::prepareAndDescribeStatement(), SAL_WARN, and SAL_WARN_IF.
Referenced by checkParameterIndex(), execute(), getMetaData(), setDouble(), setNull(), setString(), and setValue().
|
overridevirtual |
Definition at line 288 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), connectivity::firebird::OStatementCommonBase::disposeResultSet(), ensurePrepared(), connectivity::firebird::evaluateStatusVector(), connectivity::firebird::OStatementCommonBase::m_aMutex, connectivity::firebird::OStatementCommonBase::m_aStatementHandle, connectivity::firebird::OStatementCommonBase::m_pConnection, m_pInSqlda, m_pOutSqlda, m_sSqlStatement, connectivity::firebird::OStatementCommonBase::m_statusVector, connectivity::firebird::OStatementCommonBase::m_xResultSet, SAL_INFO, SAL_WARN, connectivity::firebird::StatusVectorToString(), and u.
Referenced by executeQuery(), and executeUpdate().
|
overridevirtual |
Definition at line 1007 of file firebird/PreparedStatement.cxx.
|
overridevirtual |
Definition at line 347 of file firebird/PreparedStatement.cxx.
References execute(), and connectivity::firebird::OStatementCommonBase::m_xResultSet.
|
overridevirtual |
Definition at line 341 of file firebird/PreparedStatement.cxx.
References execute(), and connectivity::firebird::OStatementCommonBase::getStatementChangeCount().
|
overridevirtual |
Definition at line 280 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), connectivity::firebird::OStatementCommonBase::m_aMutex, and connectivity::firebird::OStatementCommonBase::m_pConnection.
|
overridevirtual |
Definition at line 143 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), ensurePrepared(), connectivity::firebird::OStatementCommonBase::m_aMutex, connectivity::firebird::OStatementCommonBase::m_pConnection, m_pOutSqlda, and m_xMetaData.
|
overridevirtual |
Reimplemented from cppu::ImplHelper5< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5 >.
Definition at line 137 of file firebird/PreparedStatement.cxx.
References concatSequences(), connectivity::firebird::OStatementCommonBase::getTypes(), and cppu::ImplHelper5< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5 >::getTypes().
|
protected |
Assumes that all necessary mutexes have been taken.
Definition at line 555 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::evaluateStatusVector(), connectivity::firebird::OStatementCommonBase::m_pConnection, m_sSqlStatement, and connectivity::firebird::OStatementCommonBase::m_statusVector.
Referenced by setClob().
|
overridevirtual |
Reimplemented from cppu::ImplHelper5< class Ifc1, class Ifc2, class Ifc3, class Ifc4, class Ifc5 >.
|
overridevirtualnoexcept |
Reimplemented from connectivity::firebird::OStatementCommonBase.
Definition at line 124 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::OStatementCommonBase::release().
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
Definition at line 399 of file firebird/PreparedStatement.cxx.
References nIndex.
Referenced by setString().
|
overridevirtual |
Definition at line 427 of file firebird/PreparedStatement.cxx.
|
overridevirtual |
|
overridevirtual |
|
protected |
Definition at line 645 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), checkParameterIndex(), closeBlobAfterWriting(), connectivity::firebird::evaluateStatusVector(), i, connectivity::firebird::OStatementCommonBase::m_aMutex, connectivity::firebird::OStatementCommonBase::m_statusVector, MAX_SIZE_SEGMENT, openBlobForWriting(), pq_sdbc_driver::OUStringToOString(), and u.
Referenced by setString().
|
overridevirtual |
|
overridevirtual |
|
overridevirtual |
Definition at line 454 of file firebird/PreparedStatement.cxx.
References Any, connectivity::firebird::checkDisposed(), ensurePrepared(), connectivity::firebird::OStatementCommonBase::m_aMutex, m_pInSqlda, nIndex, nValue, setObjectWithInfo(), and dbtools::throwSQLException().
|
overrideprotectedvirtual |
Reimplemented from connectivity::firebird::OStatementCommonBase.
|
overridevirtual |
Definition at line 449 of file firebird/PreparedStatement.cxx.
References nIndex, and nValue.
Referenced by setString().
|
overridevirtual |
Definition at line 439 of file firebird/PreparedStatement.cxx.
References nIndex, and nValue.
Referenced by setString().
|
overridevirtual |
Definition at line 444 of file firebird/PreparedStatement.cxx.
References nIndex, and nValue.
Referenced by setString().
|
overridevirtual |
Definition at line 389 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), checkParameterIndex(), ensurePrepared(), connectivity::firebird::OStatementCommonBase::m_aMutex, nIndex, and setParameterNull().
|
overridevirtual |
|
overridevirtual |
Definition at line 862 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), checkParameterIndex(), connectivity::firebird::OStatementCommonBase::m_aMutex, and nIndex.
|
overridevirtual |
Referenced by setDouble().
|
protected |
Definition at line 1042 of file firebird/PreparedStatement.cxx.
References m_pInSqlda.
Referenced by setNull(), setString(), and setValue().
|
overridevirtual |
|
overridevirtual |
Definition at line 434 of file firebird/PreparedStatement.cxx.
References nIndex, and nValue.
Referenced by setString().
|
overridevirtual |
Definition at line 181 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), checkParameterIndex(), connectivity::firebird::Clob, ensurePrepared(), connectivity::firebird::OStatementCommonBase::m_aMutex, m_pInSqlda, nLength, pq_sdbc_driver::OUStringToOString(), SAL_INFO, setBoolean(), setClob(), setFloat(), setInt(), setLong(), setParameterNull(), setShort(), and dbtools::throwSQLException().
|
overridevirtual |
Definition at line 517 of file firebird/PreparedStatement.cxx.
|
overridevirtual |
|
protected |
Set a numeric value in the input SQLDA.
If the destination parameter is not of nType then an Exception will be thrown.
css::sdbc::SQLException | |
css::uno::RuntimeException |
Definition at line 405 of file firebird/PreparedStatement.cxx.
References connectivity::firebird::checkDisposed(), checkParameterIndex(), ensurePrepared(), connectivity::firebird::OStatementCommonBase::m_aMutex, m_pInSqlda, nIndex, nType, nValue, setParameterNull(), and dbtools::throwSQLException().
|
protected |
Definition at line 52 of file drivers/firebird/PreparedStatement.hxx.
Referenced by checkParameterIndex(), close(), ensurePrepared(), execute(), setDouble(), setParameterNull(), setString(), and setValue().
|
protected |
Definition at line 51 of file drivers/firebird/PreparedStatement.hxx.
Referenced by close(), ensurePrepared(), execute(), and getMetaData().
|
protected |
Definition at line 48 of file drivers/firebird/PreparedStatement.hxx.
Referenced by ensurePrepared(), execute(), and openBlobForWriting().
|
protected |
Definition at line 49 of file drivers/firebird/PreparedStatement.hxx.
Referenced by getMetaData().