1*cdf0e10cSrcweir /************************************************************************* 2*cdf0e10cSrcweir * 3*cdf0e10cSrcweir * The Contents of this file are made available subject to the terms of 4*cdf0e10cSrcweir * the BSD license. 5*cdf0e10cSrcweir * 6*cdf0e10cSrcweir * Copyright 2000, 2010 Oracle and/or its affiliates. 7*cdf0e10cSrcweir * All rights reserved. 8*cdf0e10cSrcweir * 9*cdf0e10cSrcweir * Redistribution and use in source and binary forms, with or without 10*cdf0e10cSrcweir * modification, are permitted provided that the following conditions 11*cdf0e10cSrcweir * are met: 12*cdf0e10cSrcweir * 1. Redistributions of source code must retain the above copyright 13*cdf0e10cSrcweir * notice, this list of conditions and the following disclaimer. 14*cdf0e10cSrcweir * 2. Redistributions in binary form must reproduce the above copyright 15*cdf0e10cSrcweir * notice, this list of conditions and the following disclaimer in the 16*cdf0e10cSrcweir * documentation and/or other materials provided with the distribution. 17*cdf0e10cSrcweir * 3. Neither the name of Sun Microsystems, Inc. nor the names of its 18*cdf0e10cSrcweir * contributors may be used to endorse or promote products derived 19*cdf0e10cSrcweir * from this software without specific prior written permission. 20*cdf0e10cSrcweir * 21*cdf0e10cSrcweir * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22*cdf0e10cSrcweir * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23*cdf0e10cSrcweir * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24*cdf0e10cSrcweir * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25*cdf0e10cSrcweir * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26*cdf0e10cSrcweir * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27*cdf0e10cSrcweir * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS 28*cdf0e10cSrcweir * OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND 29*cdf0e10cSrcweir * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR 30*cdf0e10cSrcweir * TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE 31*cdf0e10cSrcweir * USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 32*cdf0e10cSrcweir * 33*cdf0e10cSrcweir *************************************************************************/ 34*cdf0e10cSrcweir 35*cdf0e10cSrcweir #include <stdio.h> 36*cdf0e10cSrcweir #include <osl/diagnose.h> 37*cdf0e10cSrcweir #include "SStatement.hxx" 38*cdf0e10cSrcweir #include "SConnection.hxx" 39*cdf0e10cSrcweir #include "SResultSet.hxx" 40*cdf0e10cSrcweir #include <osl/thread.h> 41*cdf0e10cSrcweir #include <com/sun/star/sdbc/ResultSetConcurrency.hpp> 42*cdf0e10cSrcweir #include <com/sun/star/sdbc/ResultSetType.hpp> 43*cdf0e10cSrcweir #include <com/sun/star/sdbc/FetchDirection.hpp> 44*cdf0e10cSrcweir #include <com/sun/star/lang/DisposedException.hpp> 45*cdf0e10cSrcweir #include <cppuhelper/typeprovider.hxx> 46*cdf0e10cSrcweir #include "propertyids.hxx" 47*cdf0e10cSrcweir 48*cdf0e10cSrcweir using namespace connectivity::skeleton; 49*cdf0e10cSrcweir //------------------------------------------------------------------------------ 50*cdf0e10cSrcweir using namespace com::sun::star::uno; 51*cdf0e10cSrcweir using namespace com::sun::star::lang; 52*cdf0e10cSrcweir using namespace com::sun::star::beans; 53*cdf0e10cSrcweir using namespace com::sun::star::sdbc; 54*cdf0e10cSrcweir using namespace com::sun::star::sdbcx; 55*cdf0e10cSrcweir using namespace com::sun::star::container; 56*cdf0e10cSrcweir using namespace com::sun::star::io; 57*cdf0e10cSrcweir using namespace com::sun::star::util; 58*cdf0e10cSrcweir //------------------------------------------------------------------------------ 59*cdf0e10cSrcweir OStatement_Base::OStatement_Base(OConnection* _pConnection ) 60*cdf0e10cSrcweir : OStatement_BASE(m_aMutex), 61*cdf0e10cSrcweir OPropertySetHelper(OStatement_BASE::rBHelper), 62*cdf0e10cSrcweir rBHelper(OStatement_BASE::rBHelper), 63*cdf0e10cSrcweir m_pConnection(_pConnection) 64*cdf0e10cSrcweir { 65*cdf0e10cSrcweir m_pConnection->acquire(); 66*cdf0e10cSrcweir } 67*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 68*cdf0e10cSrcweir OStatement_Base::~OStatement_Base() 69*cdf0e10cSrcweir { 70*cdf0e10cSrcweir } 71*cdf0e10cSrcweir //------------------------------------------------------------------------------ 72*cdf0e10cSrcweir void OStatement_Base::disposeResultSet() 73*cdf0e10cSrcweir { 74*cdf0e10cSrcweir // free the cursor if alive 75*cdf0e10cSrcweir Reference< XComponent > xComp(m_xResultSet.get(), UNO_QUERY); 76*cdf0e10cSrcweir if (xComp.is()) 77*cdf0e10cSrcweir xComp->dispose(); 78*cdf0e10cSrcweir m_xResultSet = Reference< XResultSet>(); 79*cdf0e10cSrcweir } 80*cdf0e10cSrcweir //------------------------------------------------------------------------------ 81*cdf0e10cSrcweir void OStatement_BASE2::disposing() 82*cdf0e10cSrcweir { 83*cdf0e10cSrcweir ::osl::MutexGuard aGuard(m_aMutex); 84*cdf0e10cSrcweir 85*cdf0e10cSrcweir disposeResultSet(); 86*cdf0e10cSrcweir 87*cdf0e10cSrcweir if (m_pConnection) 88*cdf0e10cSrcweir m_pConnection->release(); 89*cdf0e10cSrcweir m_pConnection = NULL; 90*cdf0e10cSrcweir 91*cdf0e10cSrcweir dispose_ChildImpl(); 92*cdf0e10cSrcweir OStatement_Base::disposing(); 93*cdf0e10cSrcweir } 94*cdf0e10cSrcweir //----------------------------------------------------------------------------- 95*cdf0e10cSrcweir void SAL_CALL OStatement_BASE2::release() throw() 96*cdf0e10cSrcweir { 97*cdf0e10cSrcweir relase_ChildImpl(); 98*cdf0e10cSrcweir } 99*cdf0e10cSrcweir //----------------------------------------------------------------------------- 100*cdf0e10cSrcweir Any SAL_CALL OStatement_Base::queryInterface( const Type & rType ) throw(RuntimeException) 101*cdf0e10cSrcweir { 102*cdf0e10cSrcweir Any aRet = OStatement_BASE::queryInterface(rType); 103*cdf0e10cSrcweir if(!aRet.hasValue()) 104*cdf0e10cSrcweir aRet = OPropertySetHelper::queryInterface(rType); 105*cdf0e10cSrcweir return aRet; 106*cdf0e10cSrcweir } 107*cdf0e10cSrcweir // ------------------------------------------------------------------------- 108*cdf0e10cSrcweir Sequence< Type > SAL_CALL OStatement_Base::getTypes( ) throw(RuntimeException) 109*cdf0e10cSrcweir { 110*cdf0e10cSrcweir ::cppu::OTypeCollection aTypes( 111*cdf0e10cSrcweir ::cppu::UnoType< Reference< XMultiPropertySet > >::get(), 112*cdf0e10cSrcweir ::cppu::UnoType< Reference< XFastPropertySet > >::get(), 113*cdf0e10cSrcweir ::cppu::UnoType< Reference< XPropertySet > >::get()); 114*cdf0e10cSrcweir 115*cdf0e10cSrcweir return concatSequences(aTypes.getTypes(),OStatement_BASE::getTypes()); 116*cdf0e10cSrcweir } 117*cdf0e10cSrcweir // ------------------------------------------------------------------------- 118*cdf0e10cSrcweir 119*cdf0e10cSrcweir void SAL_CALL OStatement_Base::cancel( ) throw(RuntimeException) 120*cdf0e10cSrcweir { 121*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 122*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 123*cdf0e10cSrcweir // cancel the current sql statement 124*cdf0e10cSrcweir } 125*cdf0e10cSrcweir // ------------------------------------------------------------------------- 126*cdf0e10cSrcweir 127*cdf0e10cSrcweir void SAL_CALL OStatement_Base::close( ) throw(SQLException, RuntimeException) 128*cdf0e10cSrcweir { 129*cdf0e10cSrcweir { 130*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 131*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 132*cdf0e10cSrcweir 133*cdf0e10cSrcweir } 134*cdf0e10cSrcweir dispose(); 135*cdf0e10cSrcweir } 136*cdf0e10cSrcweir // ------------------------------------------------------------------------- 137*cdf0e10cSrcweir 138*cdf0e10cSrcweir void SAL_CALL OStatement::clearBatch( ) throw(SQLException, RuntimeException) 139*cdf0e10cSrcweir { 140*cdf0e10cSrcweir // if you support batches clear it here 141*cdf0e10cSrcweir } 142*cdf0e10cSrcweir // ------------------------------------------------------------------------- 143*cdf0e10cSrcweir sal_Bool SAL_CALL OStatement_Base::execute( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) 144*cdf0e10cSrcweir { 145*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 146*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 147*cdf0e10cSrcweir 148*cdf0e10cSrcweir // returns true when a resultset is available 149*cdf0e10cSrcweir return sal_False; 150*cdf0e10cSrcweir } 151*cdf0e10cSrcweir // ------------------------------------------------------------------------- 152*cdf0e10cSrcweir 153*cdf0e10cSrcweir Reference< XResultSet > SAL_CALL OStatement_Base::executeQuery( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) 154*cdf0e10cSrcweir { 155*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 156*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 157*cdf0e10cSrcweir 158*cdf0e10cSrcweir 159*cdf0e10cSrcweir Reference< XResultSet > xRS = NULL; 160*cdf0e10cSrcweir // create a resultset as result of executing the sql statement 161*cdf0e10cSrcweir // you have to here something :-) 162*cdf0e10cSrcweir m_xResultSet = xRS; // we nedd a reference to it for later use 163*cdf0e10cSrcweir return xRS; 164*cdf0e10cSrcweir } 165*cdf0e10cSrcweir // ------------------------------------------------------------------------- 166*cdf0e10cSrcweir 167*cdf0e10cSrcweir Reference< XConnection > SAL_CALL OStatement_Base::getConnection( ) throw(SQLException, RuntimeException) 168*cdf0e10cSrcweir { 169*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 170*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 171*cdf0e10cSrcweir 172*cdf0e10cSrcweir // just return our connection here 173*cdf0e10cSrcweir return (Reference< XConnection >)m_pConnection; 174*cdf0e10cSrcweir } 175*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 176*cdf0e10cSrcweir sal_Int32 SAL_CALL OStatement_Base::getUpdateCount( ) throw(::com::sun::star::sdbc::SQLException, ::com::sun::star::uno::RuntimeException) 177*cdf0e10cSrcweir { 178*cdf0e10cSrcweir return 0; 179*cdf0e10cSrcweir } 180*cdf0e10cSrcweir // ------------------------------------------------------------------------- 181*cdf0e10cSrcweir 182*cdf0e10cSrcweir Any SAL_CALL OStatement::queryInterface( const Type & rType ) throw(RuntimeException) 183*cdf0e10cSrcweir { 184*cdf0e10cSrcweir Any aRet = ::cppu::queryInterface(rType,static_cast< XBatchExecution*> (this)); 185*cdf0e10cSrcweir if(!aRet.hasValue()) 186*cdf0e10cSrcweir aRet = OStatement_Base::queryInterface(rType); 187*cdf0e10cSrcweir return aRet; 188*cdf0e10cSrcweir } 189*cdf0e10cSrcweir // ------------------------------------------------------------------------- 190*cdf0e10cSrcweir 191*cdf0e10cSrcweir void SAL_CALL OStatement::addBatch( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) 192*cdf0e10cSrcweir { 193*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 194*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 195*cdf0e10cSrcweir 196*cdf0e10cSrcweir 197*cdf0e10cSrcweir m_aBatchList.push_back(sql); 198*cdf0e10cSrcweir } 199*cdf0e10cSrcweir // ------------------------------------------------------------------------- 200*cdf0e10cSrcweir Sequence< sal_Int32 > SAL_CALL OStatement::executeBatch( ) throw(SQLException, RuntimeException) 201*cdf0e10cSrcweir { 202*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 203*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 204*cdf0e10cSrcweir 205*cdf0e10cSrcweir return Sequence< sal_Int32 >(); 206*cdf0e10cSrcweir } 207*cdf0e10cSrcweir // ------------------------------------------------------------------------- 208*cdf0e10cSrcweir 209*cdf0e10cSrcweir 210*cdf0e10cSrcweir sal_Int32 SAL_CALL OStatement_Base::executeUpdate( const ::rtl::OUString& sql ) throw(SQLException, RuntimeException) 211*cdf0e10cSrcweir { 212*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 213*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 214*cdf0e10cSrcweir 215*cdf0e10cSrcweir // the return values gives information about how many rows are affected by executing the sql statement 216*cdf0e10cSrcweir return 0; 217*cdf0e10cSrcweir 218*cdf0e10cSrcweir } 219*cdf0e10cSrcweir // ------------------------------------------------------------------------- 220*cdf0e10cSrcweir 221*cdf0e10cSrcweir Reference< XResultSet > SAL_CALL OStatement_Base::getResultSet( ) throw(SQLException, RuntimeException) 222*cdf0e10cSrcweir { 223*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 224*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 225*cdf0e10cSrcweir 226*cdf0e10cSrcweir // return our save resultset here 227*cdf0e10cSrcweir return m_xResultSet; 228*cdf0e10cSrcweir } 229*cdf0e10cSrcweir // ------------------------------------------------------------------------- 230*cdf0e10cSrcweir 231*cdf0e10cSrcweir sal_Bool SAL_CALL OStatement_Base::getMoreResults( ) throw(SQLException, RuntimeException) 232*cdf0e10cSrcweir { 233*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 234*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 235*cdf0e10cSrcweir 236*cdf0e10cSrcweir // if your driver supports more than only one resultset 237*cdf0e10cSrcweir // and has one more at this moment return true 238*cdf0e10cSrcweir return sal_False; 239*cdf0e10cSrcweir } 240*cdf0e10cSrcweir // ------------------------------------------------------------------------- 241*cdf0e10cSrcweir 242*cdf0e10cSrcweir // ------------------------------------------------------------------------- 243*cdf0e10cSrcweir Any SAL_CALL OStatement_Base::getWarnings( ) throw(SQLException, RuntimeException) 244*cdf0e10cSrcweir { 245*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 246*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 247*cdf0e10cSrcweir 248*cdf0e10cSrcweir 249*cdf0e10cSrcweir return makeAny(m_aLastWarning); 250*cdf0e10cSrcweir } 251*cdf0e10cSrcweir // ------------------------------------------------------------------------- 252*cdf0e10cSrcweir 253*cdf0e10cSrcweir // ------------------------------------------------------------------------- 254*cdf0e10cSrcweir void SAL_CALL OStatement_Base::clearWarnings( ) throw(SQLException, RuntimeException) 255*cdf0e10cSrcweir { 256*cdf0e10cSrcweir ::osl::MutexGuard aGuard( m_aMutex ); 257*cdf0e10cSrcweir checkDisposed(OStatement_BASE::rBHelper.bDisposed); 258*cdf0e10cSrcweir 259*cdf0e10cSrcweir 260*cdf0e10cSrcweir m_aLastWarning = SQLWarning(); 261*cdf0e10cSrcweir } 262*cdf0e10cSrcweir // ------------------------------------------------------------------------- 263*cdf0e10cSrcweir ::cppu::IPropertyArrayHelper* OStatement_Base::createArrayHelper( ) const 264*cdf0e10cSrcweir { 265*cdf0e10cSrcweir // this properties are define by the service statement 266*cdf0e10cSrcweir // they must in alphabetic order 267*cdf0e10cSrcweir Sequence< Property > aProps(10); 268*cdf0e10cSrcweir Property* pProperties = aProps.getArray(); 269*cdf0e10cSrcweir sal_Int32 nPos = 0; 270*cdf0e10cSrcweir DECL_PROP0(CURSORNAME, ::rtl::OUString); 271*cdf0e10cSrcweir DECL_BOOL_PROP0(ESCAPEPROCESSING); 272*cdf0e10cSrcweir DECL_PROP0(FETCHDIRECTION,sal_Int32); 273*cdf0e10cSrcweir DECL_PROP0(FETCHSIZE, sal_Int32); 274*cdf0e10cSrcweir DECL_PROP0(MAXFIELDSIZE,sal_Int32); 275*cdf0e10cSrcweir DECL_PROP0(MAXROWS, sal_Int32); 276*cdf0e10cSrcweir DECL_PROP0(QUERYTIMEOUT,sal_Int32); 277*cdf0e10cSrcweir DECL_PROP0(RESULTSETCONCURRENCY,sal_Int32); 278*cdf0e10cSrcweir DECL_PROP0(RESULTSETTYPE,sal_Int32); 279*cdf0e10cSrcweir DECL_BOOL_PROP0(USEBOOKMARKS); 280*cdf0e10cSrcweir 281*cdf0e10cSrcweir return new ::cppu::OPropertyArrayHelper(aProps); 282*cdf0e10cSrcweir } 283*cdf0e10cSrcweir 284*cdf0e10cSrcweir // ------------------------------------------------------------------------- 285*cdf0e10cSrcweir ::cppu::IPropertyArrayHelper & OStatement_Base::getInfoHelper() 286*cdf0e10cSrcweir { 287*cdf0e10cSrcweir return *const_cast<OStatement_Base*>(this)->getArrayHelper(); 288*cdf0e10cSrcweir } 289*cdf0e10cSrcweir // ------------------------------------------------------------------------- 290*cdf0e10cSrcweir sal_Bool OStatement_Base::convertFastPropertyValue( 291*cdf0e10cSrcweir Any & rConvertedValue, 292*cdf0e10cSrcweir Any & rOldValue, 293*cdf0e10cSrcweir sal_Int32 nHandle, 294*cdf0e10cSrcweir const Any& rValue ) 295*cdf0e10cSrcweir throw (::com::sun::star::lang::IllegalArgumentException) 296*cdf0e10cSrcweir { 297*cdf0e10cSrcweir sal_Bool bConverted = sal_False; 298*cdf0e10cSrcweir // here we have to try to convert 299*cdf0e10cSrcweir return bConverted; 300*cdf0e10cSrcweir } 301*cdf0e10cSrcweir // ------------------------------------------------------------------------- 302*cdf0e10cSrcweir void OStatement_Base::setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any& rValue) throw (Exception) 303*cdf0e10cSrcweir { 304*cdf0e10cSrcweir // set the value to what ever is nescessary 305*cdf0e10cSrcweir switch(nHandle) 306*cdf0e10cSrcweir { 307*cdf0e10cSrcweir case PROPERTY_ID_QUERYTIMEOUT: 308*cdf0e10cSrcweir case PROPERTY_ID_MAXFIELDSIZE: 309*cdf0e10cSrcweir case PROPERTY_ID_MAXROWS: 310*cdf0e10cSrcweir case PROPERTY_ID_CURSORNAME: 311*cdf0e10cSrcweir case PROPERTY_ID_RESULTSETCONCURRENCY: 312*cdf0e10cSrcweir case PROPERTY_ID_RESULTSETTYPE: 313*cdf0e10cSrcweir case PROPERTY_ID_FETCHDIRECTION: 314*cdf0e10cSrcweir case PROPERTY_ID_FETCHSIZE: 315*cdf0e10cSrcweir case PROPERTY_ID_ESCAPEPROCESSING: 316*cdf0e10cSrcweir case PROPERTY_ID_USEBOOKMARKS: 317*cdf0e10cSrcweir default: 318*cdf0e10cSrcweir ; 319*cdf0e10cSrcweir } 320*cdf0e10cSrcweir } 321*cdf0e10cSrcweir // ------------------------------------------------------------------------- 322*cdf0e10cSrcweir void OStatement_Base::getFastPropertyValue(Any& rValue,sal_Int32 nHandle) const 323*cdf0e10cSrcweir { 324*cdf0e10cSrcweir switch(nHandle) 325*cdf0e10cSrcweir { 326*cdf0e10cSrcweir case PROPERTY_ID_QUERYTIMEOUT: 327*cdf0e10cSrcweir case PROPERTY_ID_MAXFIELDSIZE: 328*cdf0e10cSrcweir case PROPERTY_ID_MAXROWS: 329*cdf0e10cSrcweir case PROPERTY_ID_CURSORNAME: 330*cdf0e10cSrcweir case PROPERTY_ID_RESULTSETCONCURRENCY: 331*cdf0e10cSrcweir case PROPERTY_ID_RESULTSETTYPE: 332*cdf0e10cSrcweir case PROPERTY_ID_FETCHDIRECTION: 333*cdf0e10cSrcweir case PROPERTY_ID_FETCHSIZE: 334*cdf0e10cSrcweir case PROPERTY_ID_ESCAPEPROCESSING: 335*cdf0e10cSrcweir case PROPERTY_ID_USEBOOKMARKS: 336*cdf0e10cSrcweir default: 337*cdf0e10cSrcweir ; 338*cdf0e10cSrcweir } 339*cdf0e10cSrcweir } 340*cdf0e10cSrcweir // ------------------------------------------------------------------------- 341*cdf0e10cSrcweir IMPLEMENT_SERVICE_INFO(OStatement,"com.sun.star.sdbcx.OStatement","com.sun.star.sdbc.Statement"); 342*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 343*cdf0e10cSrcweir void SAL_CALL OStatement_Base::acquire() throw() 344*cdf0e10cSrcweir { 345*cdf0e10cSrcweir OStatement_BASE::acquire(); 346*cdf0e10cSrcweir } 347*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 348*cdf0e10cSrcweir void SAL_CALL OStatement_Base::release() throw() 349*cdf0e10cSrcweir { 350*cdf0e10cSrcweir OStatement_BASE::release(); 351*cdf0e10cSrcweir } 352*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 353*cdf0e10cSrcweir void SAL_CALL OStatement::acquire() throw() 354*cdf0e10cSrcweir { 355*cdf0e10cSrcweir OStatement_BASE2::acquire(); 356*cdf0e10cSrcweir } 357*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 358*cdf0e10cSrcweir void SAL_CALL OStatement::release() throw() 359*cdf0e10cSrcweir { 360*cdf0e10cSrcweir OStatement_BASE2::release(); 361*cdf0e10cSrcweir } 362*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 363*cdf0e10cSrcweir Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL OStatement_Base::getPropertySetInfo( ) throw(RuntimeException) 364*cdf0e10cSrcweir { 365*cdf0e10cSrcweir return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper()); 366*cdf0e10cSrcweir } 367*cdf0e10cSrcweir // ----------------------------------------------------------------------------- 368*cdf0e10cSrcweir 369