1*96de5490SAndrew Rist /**************************************************************
2cdf0e10cSrcweir  *
3*96de5490SAndrew Rist  * Licensed to the Apache Software Foundation (ASF) under one
4*96de5490SAndrew Rist  * or more contributor license agreements.  See the NOTICE file
5*96de5490SAndrew Rist  * distributed with this work for additional information
6*96de5490SAndrew Rist  * regarding copyright ownership.  The ASF licenses this file
7*96de5490SAndrew Rist  * to you under the Apache License, Version 2.0 (the
8*96de5490SAndrew Rist  * "License"); you may not use this file except in compliance
9*96de5490SAndrew Rist  * with the License.  You may obtain a copy of the License at
10*96de5490SAndrew Rist  *
11*96de5490SAndrew Rist  *   http://www.apache.org/licenses/LICENSE-2.0
12*96de5490SAndrew Rist  *
13*96de5490SAndrew Rist  * Unless required by applicable law or agreed to in writing,
14*96de5490SAndrew Rist  * software distributed under the License is distributed on an
15*96de5490SAndrew Rist  * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
16*96de5490SAndrew Rist  * KIND, either express or implied.  See the License for the
17*96de5490SAndrew Rist  * specific language governing permissions and limitations
18*96de5490SAndrew Rist  * under the License.
19*96de5490SAndrew Rist  *
20*96de5490SAndrew Rist  *************************************************************/
21*96de5490SAndrew Rist 
22*96de5490SAndrew Rist 
23cdf0e10cSrcweir 
24cdf0e10cSrcweir // MARKER(update_precomp.py): autogen include statement, do not remove
25cdf0e10cSrcweir #include "precompiled_dbaccess.hxx"
26cdf0e10cSrcweir #ifndef _DBA_COREAPI_RESULTSET_HXX_
27cdf0e10cSrcweir #include <resultset.hxx>
28cdf0e10cSrcweir #endif
29cdf0e10cSrcweir #ifndef DBACCESS_SHARED_DBASTRINGS_HRC
30cdf0e10cSrcweir #include "dbastrings.hrc"
31cdf0e10cSrcweir #endif
32cdf0e10cSrcweir #ifndef _DBASHARED_APITOOLS_HXX_
33cdf0e10cSrcweir #include "apitools.hxx"
34cdf0e10cSrcweir #endif
35cdf0e10cSrcweir #ifndef _COM_SUN_STAR_LANG_DISPOSEDEXCEPTION_HPP_
36cdf0e10cSrcweir #include <com/sun/star/lang/DisposedException.hpp>
37cdf0e10cSrcweir #endif
38cdf0e10cSrcweir #ifndef _COM_SUN_STAR_SDBC_RESULTSETTYPE_HPP_
39cdf0e10cSrcweir #include <com/sun/star/sdbc/ResultSetType.hpp>
40cdf0e10cSrcweir #endif
41cdf0e10cSrcweir #ifndef _CPPUHELPER_TYPEPROVIDER_HXX_
42cdf0e10cSrcweir #include <cppuhelper/typeprovider.hxx>
43cdf0e10cSrcweir #endif
44cdf0e10cSrcweir #ifndef _COMPHELPER_PROPERTY_HXX_
45cdf0e10cSrcweir #include <comphelper/property.hxx>
46cdf0e10cSrcweir #endif
47cdf0e10cSrcweir #ifndef _COMPHELPER_SEQUENCE_HXX_
48cdf0e10cSrcweir #include <comphelper/sequence.hxx>
49cdf0e10cSrcweir #endif
50cdf0e10cSrcweir #ifndef _COMPHELPER_TYPES_HXX_
51cdf0e10cSrcweir #include <comphelper/types.hxx>
52cdf0e10cSrcweir #endif
53cdf0e10cSrcweir #ifndef _TOOLS_DEBUG_HXX //autogen
54cdf0e10cSrcweir #include <tools/debug.hxx>
55cdf0e10cSrcweir #endif
56cdf0e10cSrcweir #ifndef TOOLS_DIAGNOSE_EX_H
57cdf0e10cSrcweir #include <tools/diagnose_ex.h>
58cdf0e10cSrcweir #endif
59cdf0e10cSrcweir #ifndef _DBA_COREAPI_DATACOLUMN_HXX_
60cdf0e10cSrcweir #include <datacolumn.hxx>
61cdf0e10cSrcweir #endif
62cdf0e10cSrcweir #ifndef _COM_SUN_STAR_BEANS_PROPERTYATTRIBUTE_HPP_
63cdf0e10cSrcweir #include <com/sun/star/beans/PropertyAttribute.hpp>
64cdf0e10cSrcweir #endif
65cdf0e10cSrcweir #ifndef _DBHELPER_DBEXCEPTION_HXX_
66cdf0e10cSrcweir #include <connectivity/dbexception.hxx>
67cdf0e10cSrcweir #endif
68cdf0e10cSrcweir #ifndef _CONNECTIVITY_DBTOOLS_HXX_
69cdf0e10cSrcweir #include <connectivity/dbtools.hxx>
70cdf0e10cSrcweir #endif
71cdf0e10cSrcweir #ifndef _CPPUHELPER_EXC_HLP_HXX_
72cdf0e10cSrcweir #include <cppuhelper/exc_hlp.hxx>
73cdf0e10cSrcweir #endif
74cdf0e10cSrcweir #ifndef _OSL_THREAD_H_
75cdf0e10cSrcweir #include <osl/thread.h>
76cdf0e10cSrcweir #endif
77cdf0e10cSrcweir #include <rtl/logfile.hxx>
78cdf0e10cSrcweir 
79cdf0e10cSrcweir 
80cdf0e10cSrcweir using namespace ::com::sun::star::sdbc;
81cdf0e10cSrcweir using namespace ::com::sun::star::sdbcx;
82cdf0e10cSrcweir //using namespace ::com::sun::star::sdb;
83cdf0e10cSrcweir using namespace ::com::sun::star::beans;
84cdf0e10cSrcweir using namespace ::com::sun::star::uno;
85cdf0e10cSrcweir using namespace ::com::sun::star::lang;
86cdf0e10cSrcweir using namespace ::com::sun::star::container;
87cdf0e10cSrcweir using namespace ::cppu;
88cdf0e10cSrcweir using namespace ::osl;
89cdf0e10cSrcweir using namespace dbaccess;
90cdf0e10cSrcweir using namespace dbtools;
91cdf0e10cSrcweir 
DBG_NAME(OResultSet)92cdf0e10cSrcweir DBG_NAME(OResultSet)
93cdf0e10cSrcweir 
94cdf0e10cSrcweir //--------------------------------------------------------------------------
95cdf0e10cSrcweir OResultSet::OResultSet(const ::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XResultSet >& _xResultSet,
96cdf0e10cSrcweir 					   const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& _xStatement,
97cdf0e10cSrcweir 					   sal_Bool _bCaseSensitive)
98cdf0e10cSrcweir 		   :OResultSetBase(m_aMutex)
99cdf0e10cSrcweir 		   ,OPropertySetHelper(OResultSetBase::rBHelper)
100cdf0e10cSrcweir 		   ,m_xDelegatorResultSet(_xResultSet)
101cdf0e10cSrcweir            ,m_aWarnings( Reference< XWarningsSupplier >( _xResultSet, UNO_QUERY ) )
102cdf0e10cSrcweir 		   ,m_bIsBookmarkable(sal_False)
103cdf0e10cSrcweir {
104cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::OResultSet" );
105cdf0e10cSrcweir 	DBG_CTOR(OResultSet, NULL);
106cdf0e10cSrcweir 
107cdf0e10cSrcweir 	m_pColumns = new OColumns(*this, m_aMutex, _bCaseSensitive, ::std::vector< ::rtl::OUString>(), NULL,NULL);
108cdf0e10cSrcweir 
109cdf0e10cSrcweir 	try
110cdf0e10cSrcweir 	{
111cdf0e10cSrcweir 		m_aStatement = _xStatement;
112cdf0e10cSrcweir         m_xDelegatorResultSetUpdate = m_xDelegatorResultSetUpdate.query( m_xDelegatorResultSet );
113cdf0e10cSrcweir 		m_xDelegatorRow = m_xDelegatorRow.query( m_xDelegatorResultSet );
114cdf0e10cSrcweir 		m_xDelegatorRowUpdate = m_xDelegatorRowUpdate.query( m_xDelegatorResultSet );
115cdf0e10cSrcweir 
116cdf0e10cSrcweir 		Reference< XPropertySet > xSet(m_xDelegatorResultSet, UNO_QUERY);
117cdf0e10cSrcweir 		xSet->getPropertyValue(PROPERTY_RESULTSETTYPE) >>= m_nResultSetType;
118cdf0e10cSrcweir 		xSet->getPropertyValue(PROPERTY_RESULTSETCONCURRENCY) >>= m_nResultSetConcurrency;
119cdf0e10cSrcweir 
120cdf0e10cSrcweir 		// test for Bookmarks
121cdf0e10cSrcweir 		if (ResultSetType::FORWARD_ONLY != m_nResultSetType)
122cdf0e10cSrcweir 		{
123cdf0e10cSrcweir 			Reference <XPropertySetInfo > xInfo(xSet->getPropertySetInfo());
124cdf0e10cSrcweir 			if (xInfo->hasPropertyByName(PROPERTY_ISBOOKMARKABLE))
125cdf0e10cSrcweir             {
126cdf0e10cSrcweir 				m_bIsBookmarkable = ::comphelper::getBOOL(xSet->getPropertyValue(PROPERTY_ISBOOKMARKABLE));
127cdf0e10cSrcweir                 OSL_ENSURE( !m_bIsBookmarkable || Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY).is(),
128cdf0e10cSrcweir                     "OResultSet::OResultSet: aggregate is inconsistent in it's bookmarkable attribute!" );
129cdf0e10cSrcweir                 m_bIsBookmarkable = m_bIsBookmarkable && Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY).is();
130cdf0e10cSrcweir             }
131cdf0e10cSrcweir 		}
132cdf0e10cSrcweir 	}
133cdf0e10cSrcweir 	catch(Exception&)
134cdf0e10cSrcweir 	{
135cdf0e10cSrcweir 	}
136cdf0e10cSrcweir }
137cdf0e10cSrcweir 
138cdf0e10cSrcweir //--------------------------------------------------------------------------
~OResultSet()139cdf0e10cSrcweir OResultSet::~OResultSet()
140cdf0e10cSrcweir {
141cdf0e10cSrcweir     m_pColumns->acquire();
142cdf0e10cSrcweir 	m_pColumns->disposing();
143cdf0e10cSrcweir     delete m_pColumns;
144cdf0e10cSrcweir 
145cdf0e10cSrcweir     DBG_DTOR(OResultSet, NULL);
146cdf0e10cSrcweir }
147cdf0e10cSrcweir 
148cdf0e10cSrcweir // com::sun::star::lang::XTypeProvider
149cdf0e10cSrcweir //--------------------------------------------------------------------------
getTypes()150cdf0e10cSrcweir Sequence< Type > OResultSet::getTypes() throw (RuntimeException)
151cdf0e10cSrcweir {
152cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTypes" );
153cdf0e10cSrcweir 	OTypeCollection aTypes(::getCppuType( (const Reference< XPropertySet > *)0 ),
154cdf0e10cSrcweir 						   OResultSetBase::getTypes());
155cdf0e10cSrcweir 
156cdf0e10cSrcweir 	return aTypes.getTypes();
157cdf0e10cSrcweir }
158cdf0e10cSrcweir 
159cdf0e10cSrcweir //--------------------------------------------------------------------------
getImplementationId()160cdf0e10cSrcweir Sequence< sal_Int8 > OResultSet::getImplementationId() throw (RuntimeException)
161cdf0e10cSrcweir {
162cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getImplementationId" );
163cdf0e10cSrcweir 	static OImplementationId * pId = 0;
164cdf0e10cSrcweir 	if (! pId)
165cdf0e10cSrcweir 	{
166cdf0e10cSrcweir 		MutexGuard aGuard( Mutex::getGlobalMutex() );
167cdf0e10cSrcweir 		if (! pId)
168cdf0e10cSrcweir 		{
169cdf0e10cSrcweir 			static OImplementationId aId;
170cdf0e10cSrcweir 			pId = &aId;
171cdf0e10cSrcweir 		}
172cdf0e10cSrcweir 	}
173cdf0e10cSrcweir 	return pId->getImplementationId();
174cdf0e10cSrcweir }
175cdf0e10cSrcweir 
176cdf0e10cSrcweir // com::sun::star::uno::XInterface
177cdf0e10cSrcweir //--------------------------------------------------------------------------
queryInterface(const Type & rType)178cdf0e10cSrcweir Any OResultSet::queryInterface( const Type & rType ) throw (RuntimeException)
179cdf0e10cSrcweir {
180cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::queryInterface" );
181cdf0e10cSrcweir 	Any aIface = OResultSetBase::queryInterface( rType );
182cdf0e10cSrcweir 	if (!aIface.hasValue())
183cdf0e10cSrcweir 		aIface = ::cppu::queryInterface(
184cdf0e10cSrcweir 					rType,
185cdf0e10cSrcweir 					static_cast< XPropertySet * >( this ));
186cdf0e10cSrcweir 
187cdf0e10cSrcweir 	return aIface;
188cdf0e10cSrcweir }
189cdf0e10cSrcweir 
190cdf0e10cSrcweir //--------------------------------------------------------------------------
acquire()191cdf0e10cSrcweir void OResultSet::acquire() throw ()
192cdf0e10cSrcweir {
193cdf0e10cSrcweir 	OResultSetBase::acquire();
194cdf0e10cSrcweir }
195cdf0e10cSrcweir 
196cdf0e10cSrcweir //--------------------------------------------------------------------------
release()197cdf0e10cSrcweir void OResultSet::release() throw ()
198cdf0e10cSrcweir {
199cdf0e10cSrcweir 	OResultSetBase::release();
200cdf0e10cSrcweir }
201cdf0e10cSrcweir 
202cdf0e10cSrcweir 
203cdf0e10cSrcweir // OResultSetBase
204cdf0e10cSrcweir //------------------------------------------------------------------------------
disposing()205cdf0e10cSrcweir void OResultSet::disposing()
206cdf0e10cSrcweir {
207cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::disposing" );
208cdf0e10cSrcweir 	OPropertySetHelper::disposing();
209cdf0e10cSrcweir 
210cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
211cdf0e10cSrcweir 
212cdf0e10cSrcweir 	// free the columns
213cdf0e10cSrcweir 	m_pColumns->disposing();
214cdf0e10cSrcweir 
215cdf0e10cSrcweir 	// close the pending result set
216cdf0e10cSrcweir 	Reference< XCloseable > (m_xDelegatorResultSet, UNO_QUERY)->close();
217cdf0e10cSrcweir 
218cdf0e10cSrcweir 	m_xDelegatorResultSet = NULL;
219cdf0e10cSrcweir 	m_xDelegatorRow = NULL;
220cdf0e10cSrcweir 	m_xDelegatorRowUpdate = NULL;
221cdf0e10cSrcweir 
222cdf0e10cSrcweir 	m_aStatement = Reference< XInterface >();
223cdf0e10cSrcweir }
224cdf0e10cSrcweir 
225cdf0e10cSrcweir // XCloseable
226cdf0e10cSrcweir //------------------------------------------------------------------------------
close(void)227cdf0e10cSrcweir void OResultSet::close(void) throw( SQLException, RuntimeException )
228cdf0e10cSrcweir {
229cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::close" );
230cdf0e10cSrcweir 	{
231cdf0e10cSrcweir 		MutexGuard aGuard( m_aMutex );
232cdf0e10cSrcweir 		::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
233cdf0e10cSrcweir 	}
234cdf0e10cSrcweir 	dispose();
235cdf0e10cSrcweir }
236cdf0e10cSrcweir 
237cdf0e10cSrcweir // XServiceInfo
238cdf0e10cSrcweir //------------------------------------------------------------------------------
getImplementationName()239cdf0e10cSrcweir rtl::OUString OResultSet::getImplementationName(  ) throw(RuntimeException)
240cdf0e10cSrcweir {
241cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getImplementationName" );
242cdf0e10cSrcweir 	return rtl::OUString::createFromAscii("com.sun.star.sdb.OResultSet");
243cdf0e10cSrcweir }
244cdf0e10cSrcweir 
245cdf0e10cSrcweir //------------------------------------------------------------------------------
supportsService(const::rtl::OUString & _rServiceName)246cdf0e10cSrcweir sal_Bool OResultSet::supportsService( const ::rtl::OUString& _rServiceName ) throw (RuntimeException)
247cdf0e10cSrcweir {
248cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::supportsService" );
249cdf0e10cSrcweir 	return ::comphelper::findValue(getSupportedServiceNames(), _rServiceName, sal_True).getLength() != 0;
250cdf0e10cSrcweir }
251cdf0e10cSrcweir 
252cdf0e10cSrcweir //------------------------------------------------------------------------------
getSupportedServiceNames()253cdf0e10cSrcweir Sequence< ::rtl::OUString > OResultSet::getSupportedServiceNames(  ) throw (RuntimeException)
254cdf0e10cSrcweir {
255cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getSupportedServiceNames" );
256cdf0e10cSrcweir 	Sequence< ::rtl::OUString > aSNS( 2 );
257cdf0e10cSrcweir 	aSNS[0] = SERVICE_SDBC_RESULTSET;
258cdf0e10cSrcweir 	aSNS[1] = SERVICE_SDB_RESULTSET;
259cdf0e10cSrcweir 	return aSNS;
260cdf0e10cSrcweir }
261cdf0e10cSrcweir 
262cdf0e10cSrcweir // com::sun::star::beans::XPropertySet
263cdf0e10cSrcweir //------------------------------------------------------------------------------
getPropertySetInfo()264cdf0e10cSrcweir Reference< XPropertySetInfo > OResultSet::getPropertySetInfo() throw (RuntimeException)
265cdf0e10cSrcweir {
266cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getPropertySetInfo" );
267cdf0e10cSrcweir 	return createPropertySetInfo( getInfoHelper() ) ;
268cdf0e10cSrcweir }
269cdf0e10cSrcweir 
270cdf0e10cSrcweir // comphelper::OPropertyArrayUsageHelper
271cdf0e10cSrcweir //------------------------------------------------------------------------------
createArrayHelper() const272cdf0e10cSrcweir ::cppu::IPropertyArrayHelper* OResultSet::createArrayHelper( ) const
273cdf0e10cSrcweir {
274cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::createArrayHelper" );
275cdf0e10cSrcweir 	BEGIN_PROPERTY_HELPER(6)
276cdf0e10cSrcweir 		DECL_PROP1(CURSORNAME,				::rtl::OUString,	READONLY);
277cdf0e10cSrcweir 		DECL_PROP0(FETCHDIRECTION,			sal_Int32);
278cdf0e10cSrcweir 		DECL_PROP0(FETCHSIZE,				sal_Int32);
279cdf0e10cSrcweir 		DECL_PROP1_BOOL(ISBOOKMARKABLE,			READONLY);
280cdf0e10cSrcweir 		DECL_PROP1(RESULTSETCONCURRENCY,	sal_Int32,		READONLY);
281cdf0e10cSrcweir 		DECL_PROP1(RESULTSETTYPE,			sal_Int32,		READONLY);
282cdf0e10cSrcweir 	END_PROPERTY_HELPER();
283cdf0e10cSrcweir }
284cdf0e10cSrcweir 
285cdf0e10cSrcweir // cppu::OPropertySetHelper
286cdf0e10cSrcweir //------------------------------------------------------------------------------
getInfoHelper()287cdf0e10cSrcweir ::cppu::IPropertyArrayHelper& OResultSet::getInfoHelper()
288cdf0e10cSrcweir {
289cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getInfoHelper" );
290cdf0e10cSrcweir 	return *getArrayHelper();
291cdf0e10cSrcweir }
292cdf0e10cSrcweir 
293cdf0e10cSrcweir //------------------------------------------------------------------------------
convertFastPropertyValue(Any & rConvertedValue,Any & rOldValue,sal_Int32 nHandle,const Any & rValue)294cdf0e10cSrcweir sal_Bool OResultSet::convertFastPropertyValue(Any & rConvertedValue, Any & rOldValue, sal_Int32 nHandle, const Any& rValue ) throw( IllegalArgumentException  )
295cdf0e10cSrcweir {
296cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::convertFastPropertyValue" );
297cdf0e10cSrcweir     // be lazy ...
298cdf0e10cSrcweir     rConvertedValue = rValue;
299cdf0e10cSrcweir     getFastPropertyValue( rOldValue, nHandle );
300cdf0e10cSrcweir     return sal_True;
301cdf0e10cSrcweir }
302cdf0e10cSrcweir 
303cdf0e10cSrcweir //------------------------------------------------------------------------------
setFastPropertyValue_NoBroadcast(sal_Int32 nHandle,const Any & rValue)304cdf0e10cSrcweir void OResultSet::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, const Any& rValue ) throw (Exception)
305cdf0e10cSrcweir {
306cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::setFastPropertyValue_NoBroadcast" );
307cdf0e10cSrcweir 	// set it for the driver result set
308cdf0e10cSrcweir 	Reference< XPropertySet > xSet(m_xDelegatorResultSet, UNO_QUERY);
309cdf0e10cSrcweir 	switch (nHandle)
310cdf0e10cSrcweir 	{
311cdf0e10cSrcweir 		case PROPERTY_ID_FETCHDIRECTION:
312cdf0e10cSrcweir 			xSet->setPropertyValue(PROPERTY_FETCHDIRECTION, rValue);
313cdf0e10cSrcweir 			break;
314cdf0e10cSrcweir 		case PROPERTY_ID_FETCHSIZE:
315cdf0e10cSrcweir 			xSet->setPropertyValue(PROPERTY_FETCHSIZE, rValue);
316cdf0e10cSrcweir 			break;
317cdf0e10cSrcweir 		default:
318cdf0e10cSrcweir 			DBG_ERROR("unknown Property");
319cdf0e10cSrcweir 	}
320cdf0e10cSrcweir }
321cdf0e10cSrcweir 
322cdf0e10cSrcweir //------------------------------------------------------------------------------
getFastPropertyValue(Any & rValue,sal_Int32 nHandle) const323cdf0e10cSrcweir void OResultSet::getFastPropertyValue( Any& rValue, sal_Int32 nHandle ) const
324cdf0e10cSrcweir {
325cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getFastPropertyValue" );
326cdf0e10cSrcweir 	switch (nHandle)
327cdf0e10cSrcweir 	{
328cdf0e10cSrcweir 		case PROPERTY_ID_ISBOOKMARKABLE:
329cdf0e10cSrcweir 		{
330cdf0e10cSrcweir 			sal_Bool bVal = m_bIsBookmarkable;
331cdf0e10cSrcweir 			rValue.setValue(&bVal, getBooleanCppuType());
332cdf0e10cSrcweir 		}	break;
333cdf0e10cSrcweir 		default:
334cdf0e10cSrcweir 		{
335cdf0e10cSrcweir 			// get the property name
336cdf0e10cSrcweir 			::rtl::OUString aPropName;
337cdf0e10cSrcweir 			sal_Int16 nAttributes;
338cdf0e10cSrcweir 			const_cast<OResultSet*>(this)->getInfoHelper().
339cdf0e10cSrcweir 				fillPropertyMembersByHandle(&aPropName, &nAttributes, nHandle);
340cdf0e10cSrcweir 			OSL_ENSURE(aPropName.getLength(), "property not found?");
341cdf0e10cSrcweir 
342cdf0e10cSrcweir 			// now read the value
343cdf0e10cSrcweir 			rValue = Reference< XPropertySet >(m_xDelegatorResultSet, UNO_QUERY)->getPropertyValue(aPropName);
344cdf0e10cSrcweir 		}
345cdf0e10cSrcweir 	}
346cdf0e10cSrcweir }
347cdf0e10cSrcweir 
348cdf0e10cSrcweir // XWarningsSupplier
349cdf0e10cSrcweir //------------------------------------------------------------------------------
getWarnings(void)350cdf0e10cSrcweir Any OResultSet::getWarnings(void) throw( SQLException, RuntimeException )
351cdf0e10cSrcweir {
352cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getWarnings" );
353cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
354cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
355cdf0e10cSrcweir     return m_aWarnings.getWarnings();
356cdf0e10cSrcweir }
357cdf0e10cSrcweir 
358cdf0e10cSrcweir //------------------------------------------------------------------------------
clearWarnings(void)359cdf0e10cSrcweir void OResultSet::clearWarnings(void) throw( SQLException, RuntimeException )
360cdf0e10cSrcweir {
361cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::clearWarnings" );
362cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
363cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
364cdf0e10cSrcweir     m_aWarnings.clearWarnings();
365cdf0e10cSrcweir }
366cdf0e10cSrcweir 
367cdf0e10cSrcweir // ::com::sun::star::sdbc::XResultSetMetaDataSupplier
368cdf0e10cSrcweir //------------------------------------------------------------------------------
getMetaData(void)369cdf0e10cSrcweir Reference< XResultSetMetaData > OResultSet::getMetaData(void) throw( SQLException, RuntimeException )
370cdf0e10cSrcweir {
371cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getMetaData" );
372cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
373cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
374cdf0e10cSrcweir 
375cdf0e10cSrcweir 	return Reference< XResultSetMetaDataSupplier >(m_xDelegatorResultSet, UNO_QUERY)->getMetaData();
376cdf0e10cSrcweir }
377cdf0e10cSrcweir 
378cdf0e10cSrcweir // ::com::sun::star::sdbc::XColumnLocate
379cdf0e10cSrcweir //------------------------------------------------------------------------------
findColumn(const rtl::OUString & columnName)380cdf0e10cSrcweir sal_Int32 OResultSet::findColumn(const rtl::OUString& columnName) throw( SQLException, RuntimeException )
381cdf0e10cSrcweir {
382cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::findColumn" );
383cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
384cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
385cdf0e10cSrcweir 
386cdf0e10cSrcweir 	return Reference< XColumnLocate >(m_xDelegatorResultSet, UNO_QUERY)->findColumn(columnName);
387cdf0e10cSrcweir }
388cdf0e10cSrcweir 
389cdf0e10cSrcweir //------------------------------------------------------------------------------
390cdf0e10cSrcweir namespace
391cdf0e10cSrcweir {
lcl_getDBMetaDataFromStatement_nothrow(const Reference<XInterface> & _rxStatement)392cdf0e10cSrcweir     static Reference< XDatabaseMetaData > lcl_getDBMetaDataFromStatement_nothrow( const Reference< XInterface >& _rxStatement )
393cdf0e10cSrcweir     {
394cdf0e10cSrcweir         Reference< XDatabaseMetaData > xDBMetaData;
395cdf0e10cSrcweir         try
396cdf0e10cSrcweir         {
397cdf0e10cSrcweir             Reference< XStatement > xStatement( _rxStatement, UNO_QUERY );
398cdf0e10cSrcweir             Reference< XPreparedStatement > xPreparedStatement( _rxStatement, UNO_QUERY );
399cdf0e10cSrcweir             Reference< XConnection > xConn;
400cdf0e10cSrcweir             if ( xStatement.is() )
401cdf0e10cSrcweir                 xConn = xStatement->getConnection();
402cdf0e10cSrcweir             else if ( xPreparedStatement.is() )
403cdf0e10cSrcweir                 xConn = xPreparedStatement->getConnection();
404cdf0e10cSrcweir             if ( xConn.is() )
405cdf0e10cSrcweir                 xDBMetaData = xConn->getMetaData();
406cdf0e10cSrcweir         }
407cdf0e10cSrcweir         catch( const Exception& )
408cdf0e10cSrcweir         {
409cdf0e10cSrcweir             DBG_UNHANDLED_EXCEPTION();
410cdf0e10cSrcweir         }
411cdf0e10cSrcweir         return xDBMetaData;
412cdf0e10cSrcweir     }
413cdf0e10cSrcweir }
414cdf0e10cSrcweir // ::com::sun::star::sdbcx::XColumnsSupplier
415cdf0e10cSrcweir //------------------------------------------------------------------------------
getColumns(void)416cdf0e10cSrcweir Reference< ::com::sun::star::container::XNameAccess > OResultSet::getColumns(void) throw( RuntimeException )
417cdf0e10cSrcweir {
418cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getColumns" );
419cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
420cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
421cdf0e10cSrcweir 
422cdf0e10cSrcweir 	// do we have to populate the columns
423cdf0e10cSrcweir 	if (!m_pColumns->isInitialized())
424cdf0e10cSrcweir 	{
425cdf0e10cSrcweir 		// get the metadata
426cdf0e10cSrcweir 		Reference< XResultSetMetaData > xMetaData = Reference< XResultSetMetaDataSupplier >(m_xDelegatorResultSet, UNO_QUERY)->getMetaData();
427cdf0e10cSrcweir 
428cdf0e10cSrcweir         sal_Int32 nColCount = 0;
429cdf0e10cSrcweir 		// do we have columns
430cdf0e10cSrcweir 		try
431cdf0e10cSrcweir 		{
432cdf0e10cSrcweir             Reference< XDatabaseMetaData > xDBMetaData( lcl_getDBMetaDataFromStatement_nothrow( getStatement() ) );
433cdf0e10cSrcweir             nColCount = xMetaData->getColumnCount();
434cdf0e10cSrcweir 
435cdf0e10cSrcweir 			for ( sal_Int32 i = 0; i < nColCount; ++i)
436cdf0e10cSrcweir 			{
437cdf0e10cSrcweir 				// retrieve the name of the column
438cdf0e10cSrcweir 				rtl::OUString sName = xMetaData->getColumnName(i + 1);
439cdf0e10cSrcweir 				ODataColumn* pColumn = new ODataColumn(xMetaData, m_xDelegatorRow, m_xDelegatorRowUpdate, i + 1, xDBMetaData);
440cdf0e10cSrcweir 
441cdf0e10cSrcweir                 // don't silently assume that the name is unique - result set implementations
442cdf0e10cSrcweir                 // are allowed to return duplicate names, but we are required to have
443cdf0e10cSrcweir                 // unique column names
444cdf0e10cSrcweir                 if ( m_pColumns->hasByName( sName ) )
445cdf0e10cSrcweir                     sName = ::dbtools::createUniqueName( m_pColumns, sName );
446cdf0e10cSrcweir 
447cdf0e10cSrcweir 			    m_pColumns->append( sName, pColumn );
448cdf0e10cSrcweir 			}
449cdf0e10cSrcweir 		}
450cdf0e10cSrcweir 		catch ( const SQLException& )
451cdf0e10cSrcweir 		{
452cdf0e10cSrcweir             DBG_UNHANDLED_EXCEPTION();
453cdf0e10cSrcweir 		}
454cdf0e10cSrcweir 		m_pColumns->setInitialized();
455cdf0e10cSrcweir 
456cdf0e10cSrcweir     #if OSL_DEBUG_LEVEL > 0
457cdf0e10cSrcweir         // some sanity checks. Especially in case we auto-adjusted the column names above,
458cdf0e10cSrcweir         // this might be reasonable
459cdf0e10cSrcweir         try
460cdf0e10cSrcweir         {
461cdf0e10cSrcweir             const Reference< XNameAccess > xColNames( static_cast< XNameAccess* >( m_pColumns ), UNO_SET_THROW );
462cdf0e10cSrcweir             const Sequence< ::rtl::OUString > aNames( xColNames->getElementNames() );
463cdf0e10cSrcweir             OSL_POSTCOND( aNames.getLength() == nColCount,
464cdf0e10cSrcweir                 "OResultSet::getColumns: invalid column count!" );
465cdf0e10cSrcweir             for (   const ::rtl::OUString* pName = aNames.getConstArray();
466cdf0e10cSrcweir                     pName != aNames.getConstArray() + aNames.getLength();
467cdf0e10cSrcweir                     ++pName
468cdf0e10cSrcweir                 )
469cdf0e10cSrcweir             {
470cdf0e10cSrcweir                 Reference< XPropertySet > xColProps( xColNames->getByName( *pName ), UNO_QUERY_THROW );
471cdf0e10cSrcweir                 ::rtl::OUString sName;
472cdf0e10cSrcweir                 OSL_VERIFY( xColProps->getPropertyValue( PROPERTY_NAME ) >>= sName );
473cdf0e10cSrcweir                 OSL_POSTCOND( sName == *pName, "OResultSet::getColumns: invalid column name!" );
474cdf0e10cSrcweir             }
475cdf0e10cSrcweir 
476cdf0e10cSrcweir         }
477cdf0e10cSrcweir         catch( const Exception& )
478cdf0e10cSrcweir         {
479cdf0e10cSrcweir             DBG_UNHANDLED_EXCEPTION();
480cdf0e10cSrcweir         }
481cdf0e10cSrcweir     #endif
482cdf0e10cSrcweir 	}
483cdf0e10cSrcweir 	return m_pColumns;
484cdf0e10cSrcweir }
485cdf0e10cSrcweir 
486cdf0e10cSrcweir // ::com::sun::star::sdbc::XRow
487cdf0e10cSrcweir //------------------------------------------------------------------------------
wasNull(void)488cdf0e10cSrcweir sal_Bool OResultSet::wasNull(void) throw( SQLException, RuntimeException )
489cdf0e10cSrcweir {
490cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::wasNull" );
491cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
492cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
493cdf0e10cSrcweir 
494cdf0e10cSrcweir 	return m_xDelegatorRow->wasNull();
495cdf0e10cSrcweir }
496cdf0e10cSrcweir //------------------------------------------------------------------------------
getString(sal_Int32 columnIndex)497cdf0e10cSrcweir rtl::OUString OResultSet::getString(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
498cdf0e10cSrcweir {
499cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getString" );
500cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
501cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
502cdf0e10cSrcweir 
503cdf0e10cSrcweir 	return m_xDelegatorRow->getString(columnIndex);
504cdf0e10cSrcweir }
505cdf0e10cSrcweir //------------------------------------------------------------------------------
getBoolean(sal_Int32 columnIndex)506cdf0e10cSrcweir sal_Bool OResultSet::getBoolean(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
507cdf0e10cSrcweir {
508cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBoolean" );
509cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
510cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
511cdf0e10cSrcweir 
512cdf0e10cSrcweir 	return m_xDelegatorRow->getBoolean(columnIndex);
513cdf0e10cSrcweir }
514cdf0e10cSrcweir //------------------------------------------------------------------------------
getByte(sal_Int32 columnIndex)515cdf0e10cSrcweir sal_Int8 OResultSet::getByte(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
516cdf0e10cSrcweir {
517cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getByte" );
518cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
519cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
520cdf0e10cSrcweir 
521cdf0e10cSrcweir 	return m_xDelegatorRow->getByte(columnIndex);
522cdf0e10cSrcweir }
523cdf0e10cSrcweir //------------------------------------------------------------------------------
getShort(sal_Int32 columnIndex)524cdf0e10cSrcweir sal_Int16 OResultSet::getShort(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
525cdf0e10cSrcweir {
526cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getShort" );
527cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
528cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
529cdf0e10cSrcweir 
530cdf0e10cSrcweir 	return m_xDelegatorRow->getShort(columnIndex);
531cdf0e10cSrcweir }
532cdf0e10cSrcweir //------------------------------------------------------------------------------
getInt(sal_Int32 columnIndex)533cdf0e10cSrcweir sal_Int32 OResultSet::getInt(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
534cdf0e10cSrcweir {
535cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getInt" );
536cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
537cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
538cdf0e10cSrcweir 
539cdf0e10cSrcweir 	return m_xDelegatorRow->getInt(columnIndex);
540cdf0e10cSrcweir }
541cdf0e10cSrcweir //------------------------------------------------------------------------------
getLong(sal_Int32 columnIndex)542cdf0e10cSrcweir sal_Int64 OResultSet::getLong(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
543cdf0e10cSrcweir {
544cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getLong" );
545cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
546cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
547cdf0e10cSrcweir 
548cdf0e10cSrcweir 	return m_xDelegatorRow->getLong(columnIndex);
549cdf0e10cSrcweir }
550cdf0e10cSrcweir //------------------------------------------------------------------------------
getFloat(sal_Int32 columnIndex)551cdf0e10cSrcweir float OResultSet::getFloat(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
552cdf0e10cSrcweir {
553cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getFloat" );
554cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
555cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
556cdf0e10cSrcweir 
557cdf0e10cSrcweir 	return m_xDelegatorRow->getFloat(columnIndex);
558cdf0e10cSrcweir }
559cdf0e10cSrcweir //------------------------------------------------------------------------------
getDouble(sal_Int32 columnIndex)560cdf0e10cSrcweir double OResultSet::getDouble(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
561cdf0e10cSrcweir {
562cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getDouble" );
563cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
564cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
565cdf0e10cSrcweir 
566cdf0e10cSrcweir 	return m_xDelegatorRow->getDouble(columnIndex);
567cdf0e10cSrcweir }
568cdf0e10cSrcweir //------------------------------------------------------------------------------
getBytes(sal_Int32 columnIndex)569cdf0e10cSrcweir Sequence< sal_Int8 > OResultSet::getBytes(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
570cdf0e10cSrcweir {
571cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBytes" );
572cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
573cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
574cdf0e10cSrcweir 
575cdf0e10cSrcweir 	return m_xDelegatorRow->getBytes(columnIndex);
576cdf0e10cSrcweir }
577cdf0e10cSrcweir //------------------------------------------------------------------------------
getDate(sal_Int32 columnIndex)578cdf0e10cSrcweir ::com::sun::star::util::Date OResultSet::getDate(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
579cdf0e10cSrcweir {
580cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getDate" );
581cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
582cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
583cdf0e10cSrcweir 
584cdf0e10cSrcweir 	return m_xDelegatorRow->getDate(columnIndex);
585cdf0e10cSrcweir }
586cdf0e10cSrcweir //------------------------------------------------------------------------------
getTime(sal_Int32 columnIndex)587cdf0e10cSrcweir ::com::sun::star::util::Time OResultSet::getTime(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
588cdf0e10cSrcweir {
589cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTime" );
590cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
591cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
592cdf0e10cSrcweir 
593cdf0e10cSrcweir 	return m_xDelegatorRow->getTime(columnIndex);
594cdf0e10cSrcweir }
595cdf0e10cSrcweir //------------------------------------------------------------------------------
getTimestamp(sal_Int32 columnIndex)596cdf0e10cSrcweir ::com::sun::star::util::DateTime OResultSet::getTimestamp(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
597cdf0e10cSrcweir {
598cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getTimestamp" );
599cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
600cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
601cdf0e10cSrcweir 
602cdf0e10cSrcweir 	return m_xDelegatorRow->getTimestamp(columnIndex);
603cdf0e10cSrcweir }
604cdf0e10cSrcweir //------------------------------------------------------------------------------
getBinaryStream(sal_Int32 columnIndex)605cdf0e10cSrcweir Reference< ::com::sun::star::io::XInputStream >  OResultSet::getBinaryStream(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
606cdf0e10cSrcweir {
607cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBinaryStream" );
608cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
609cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
610cdf0e10cSrcweir 
611cdf0e10cSrcweir 	return m_xDelegatorRow->getBinaryStream(columnIndex);
612cdf0e10cSrcweir }
613cdf0e10cSrcweir //------------------------------------------------------------------------------
getCharacterStream(sal_Int32 columnIndex)614cdf0e10cSrcweir Reference< ::com::sun::star::io::XInputStream >  OResultSet::getCharacterStream(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
615cdf0e10cSrcweir {
616cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getCharacterStream" );
617cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
618cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
619cdf0e10cSrcweir 
620cdf0e10cSrcweir 	return m_xDelegatorRow->getCharacterStream(columnIndex);
621cdf0e10cSrcweir }
622cdf0e10cSrcweir //------------------------------------------------------------------------------
getObject(sal_Int32 columnIndex,const Reference<::com::sun::star::container::XNameAccess> & typeMap)623cdf0e10cSrcweir Any OResultSet::getObject(sal_Int32 columnIndex, const Reference< ::com::sun::star::container::XNameAccess > & typeMap) throw( SQLException, RuntimeException )
624cdf0e10cSrcweir {
625cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getObject" );
626cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
627cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
628cdf0e10cSrcweir 
629cdf0e10cSrcweir 	return m_xDelegatorRow->getObject(columnIndex, typeMap);
630cdf0e10cSrcweir }
631cdf0e10cSrcweir //------------------------------------------------------------------------------
getRef(sal_Int32 columnIndex)632cdf0e10cSrcweir Reference< XRef >  OResultSet::getRef(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
633cdf0e10cSrcweir {
634cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getRef" );
635cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
636cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
637cdf0e10cSrcweir 
638cdf0e10cSrcweir 	return m_xDelegatorRow->getRef(columnIndex);
639cdf0e10cSrcweir }
640cdf0e10cSrcweir //------------------------------------------------------------------------------
getBlob(sal_Int32 columnIndex)641cdf0e10cSrcweir Reference< XBlob >  OResultSet::getBlob(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
642cdf0e10cSrcweir {
643cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBlob" );
644cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
645cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
646cdf0e10cSrcweir 
647cdf0e10cSrcweir 	return m_xDelegatorRow->getBlob(columnIndex);
648cdf0e10cSrcweir }
649cdf0e10cSrcweir //------------------------------------------------------------------------------
getClob(sal_Int32 columnIndex)650cdf0e10cSrcweir Reference< XClob >  OResultSet::getClob(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
651cdf0e10cSrcweir {
652cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getClob" );
653cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
654cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
655cdf0e10cSrcweir 
656cdf0e10cSrcweir 	return m_xDelegatorRow->getClob(columnIndex);
657cdf0e10cSrcweir }
658cdf0e10cSrcweir //------------------------------------------------------------------------------
getArray(sal_Int32 columnIndex)659cdf0e10cSrcweir Reference< XArray >  OResultSet::getArray(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
660cdf0e10cSrcweir {
661cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getArray" );
662cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
663cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
664cdf0e10cSrcweir 
665cdf0e10cSrcweir 	return m_xDelegatorRow->getArray(columnIndex);
666cdf0e10cSrcweir }
667cdf0e10cSrcweir 
668cdf0e10cSrcweir // ::com::sun::star::sdbc::XRowUpdate
669cdf0e10cSrcweir //------------------------------------------------------------------------------
updateNull(sal_Int32 columnIndex)670cdf0e10cSrcweir void OResultSet::updateNull(sal_Int32 columnIndex) throw( SQLException, RuntimeException )
671cdf0e10cSrcweir {
672cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateNull" );
673cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
674cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
675cdf0e10cSrcweir 
676cdf0e10cSrcweir 	checkReadOnly();
677cdf0e10cSrcweir 
678cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateNull(columnIndex);
679cdf0e10cSrcweir }
680cdf0e10cSrcweir 
681cdf0e10cSrcweir //------------------------------------------------------------------------------
updateBoolean(sal_Int32 columnIndex,sal_Bool x)682cdf0e10cSrcweir void OResultSet::updateBoolean(sal_Int32 columnIndex, sal_Bool x) throw( SQLException, RuntimeException )
683cdf0e10cSrcweir {
684cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBoolean" );
685cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
686cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
687cdf0e10cSrcweir 
688cdf0e10cSrcweir 	checkReadOnly();
689cdf0e10cSrcweir 
690cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateBoolean(columnIndex, x);
691cdf0e10cSrcweir }
692cdf0e10cSrcweir //------------------------------------------------------------------------------
updateByte(sal_Int32 columnIndex,sal_Int8 x)693cdf0e10cSrcweir void OResultSet::updateByte(sal_Int32 columnIndex, sal_Int8 x) throw( SQLException, RuntimeException )
694cdf0e10cSrcweir {
695cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateByte" );
696cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
697cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
698cdf0e10cSrcweir 
699cdf0e10cSrcweir 	checkReadOnly();
700cdf0e10cSrcweir 
701cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateByte(columnIndex, x);
702cdf0e10cSrcweir }
703cdf0e10cSrcweir //------------------------------------------------------------------------------
updateShort(sal_Int32 columnIndex,sal_Int16 x)704cdf0e10cSrcweir void OResultSet::updateShort(sal_Int32 columnIndex, sal_Int16 x) throw( SQLException, RuntimeException )
705cdf0e10cSrcweir {
706cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateShort" );
707cdf0e10cSrcweir 		MutexGuard aGuard(m_aMutex);
708cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
709cdf0e10cSrcweir 
710cdf0e10cSrcweir 	checkReadOnly();
711cdf0e10cSrcweir 
712cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateShort(columnIndex, x);
713cdf0e10cSrcweir }
714cdf0e10cSrcweir //------------------------------------------------------------------------------
updateInt(sal_Int32 columnIndex,sal_Int32 x)715cdf0e10cSrcweir void OResultSet::updateInt(sal_Int32 columnIndex, sal_Int32 x) throw( SQLException, RuntimeException )
716cdf0e10cSrcweir {
717cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateInt" );
718cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
719cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
720cdf0e10cSrcweir 
721cdf0e10cSrcweir 	checkReadOnly();
722cdf0e10cSrcweir 
723cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateInt(columnIndex, x);
724cdf0e10cSrcweir }
725cdf0e10cSrcweir //------------------------------------------------------------------------------
updateLong(sal_Int32 columnIndex,sal_Int64 x)726cdf0e10cSrcweir void OResultSet::updateLong(sal_Int32 columnIndex, sal_Int64 x) throw( SQLException, RuntimeException )
727cdf0e10cSrcweir {
728cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateLong" );
729cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
730cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
731cdf0e10cSrcweir 
732cdf0e10cSrcweir 	checkReadOnly();
733cdf0e10cSrcweir 
734cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateLong(columnIndex, x);
735cdf0e10cSrcweir }
736cdf0e10cSrcweir //------------------------------------------------------------------------------
updateFloat(sal_Int32 columnIndex,float x)737cdf0e10cSrcweir void OResultSet::updateFloat(sal_Int32 columnIndex, float x) throw( SQLException, RuntimeException )
738cdf0e10cSrcweir {
739cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateFloat" );
740cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
741cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
742cdf0e10cSrcweir 
743cdf0e10cSrcweir 	checkReadOnly();
744cdf0e10cSrcweir 
745cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateFloat(columnIndex, x);
746cdf0e10cSrcweir }
747cdf0e10cSrcweir //------------------------------------------------------------------------------
updateDouble(sal_Int32 columnIndex,double x)748cdf0e10cSrcweir void OResultSet::updateDouble(sal_Int32 columnIndex, double x) throw( SQLException, RuntimeException )
749cdf0e10cSrcweir {
750cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateDouble" );
751cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
752cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
753cdf0e10cSrcweir 
754cdf0e10cSrcweir 	checkReadOnly();
755cdf0e10cSrcweir 
756cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateDouble(columnIndex, x);
757cdf0e10cSrcweir }
758cdf0e10cSrcweir //------------------------------------------------------------------------------
updateString(sal_Int32 columnIndex,const rtl::OUString & x)759cdf0e10cSrcweir void OResultSet::updateString(sal_Int32 columnIndex, const rtl::OUString& x) throw( SQLException, RuntimeException )
760cdf0e10cSrcweir {
761cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateString" );
762cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
763cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
764cdf0e10cSrcweir 
765cdf0e10cSrcweir 	checkReadOnly();
766cdf0e10cSrcweir 
767cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateString(columnIndex, x);
768cdf0e10cSrcweir }
769cdf0e10cSrcweir //------------------------------------------------------------------------------
updateBytes(sal_Int32 columnIndex,const Sequence<sal_Int8> & x)770cdf0e10cSrcweir void OResultSet::updateBytes(sal_Int32 columnIndex, const Sequence< sal_Int8 >& x) throw( SQLException, RuntimeException )
771cdf0e10cSrcweir {
772cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBytes" );
773cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
774cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
775cdf0e10cSrcweir 
776cdf0e10cSrcweir 	checkReadOnly();
777cdf0e10cSrcweir 
778cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateBytes(columnIndex, x);
779cdf0e10cSrcweir }
780cdf0e10cSrcweir //------------------------------------------------------------------------------
updateDate(sal_Int32 columnIndex,const::com::sun::star::util::Date & x)781cdf0e10cSrcweir void OResultSet::updateDate(sal_Int32 columnIndex, const ::com::sun::star::util::Date& x) throw( SQLException, RuntimeException )
782cdf0e10cSrcweir {
783cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateDate" );
784cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
785cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
786cdf0e10cSrcweir 
787cdf0e10cSrcweir 	checkReadOnly();
788cdf0e10cSrcweir 
789cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateDate(columnIndex, x);
790cdf0e10cSrcweir }
791cdf0e10cSrcweir //------------------------------------------------------------------------------
updateTime(sal_Int32 columnIndex,const::com::sun::star::util::Time & x)792cdf0e10cSrcweir void OResultSet::updateTime(sal_Int32 columnIndex, const ::com::sun::star::util::Time& x) throw( SQLException, RuntimeException )
793cdf0e10cSrcweir {
794cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateTime" );
795cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
796cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
797cdf0e10cSrcweir 
798cdf0e10cSrcweir 	checkReadOnly();
799cdf0e10cSrcweir 
800cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateTime(columnIndex, x);
801cdf0e10cSrcweir }
802cdf0e10cSrcweir //------------------------------------------------------------------------------
updateTimestamp(sal_Int32 columnIndex,const::com::sun::star::util::DateTime & x)803cdf0e10cSrcweir void OResultSet::updateTimestamp(sal_Int32 columnIndex, const ::com::sun::star::util::DateTime& x) throw( SQLException, RuntimeException )
804cdf0e10cSrcweir {
805cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateTimestamp" );
806cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
807cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
808cdf0e10cSrcweir 
809cdf0e10cSrcweir 	checkReadOnly();
810cdf0e10cSrcweir 
811cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateTimestamp(columnIndex, x);
812cdf0e10cSrcweir }
813cdf0e10cSrcweir //------------------------------------------------------------------------------
updateBinaryStream(sal_Int32 columnIndex,const Reference<::com::sun::star::io::XInputStream> & x,sal_Int32 length)814cdf0e10cSrcweir void OResultSet::updateBinaryStream(sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
815cdf0e10cSrcweir {
816cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateBinaryStream" );
817cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
818cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
819cdf0e10cSrcweir 
820cdf0e10cSrcweir 	checkReadOnly();
821cdf0e10cSrcweir 
822cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateBinaryStream(columnIndex, x, length);
823cdf0e10cSrcweir }
824cdf0e10cSrcweir //------------------------------------------------------------------------------
updateCharacterStream(sal_Int32 columnIndex,const Reference<::com::sun::star::io::XInputStream> & x,sal_Int32 length)825cdf0e10cSrcweir void OResultSet::updateCharacterStream(sal_Int32 columnIndex, const Reference< ::com::sun::star::io::XInputStream > & x, sal_Int32 length) throw( SQLException, RuntimeException )
826cdf0e10cSrcweir {
827cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateCharacterStream" );
828cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
829cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
830cdf0e10cSrcweir 
831cdf0e10cSrcweir 	checkReadOnly();
832cdf0e10cSrcweir 
833cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateCharacterStream(columnIndex, x, length);
834cdf0e10cSrcweir }
835cdf0e10cSrcweir //------------------------------------------------------------------------------
updateNumericObject(sal_Int32 columnIndex,const Any & x,sal_Int32 scale)836cdf0e10cSrcweir void OResultSet::updateNumericObject(sal_Int32 columnIndex, const Any& x, sal_Int32 scale) throw( SQLException, RuntimeException )
837cdf0e10cSrcweir {
838cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateNumericObject" );
839cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
840cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
841cdf0e10cSrcweir 
842cdf0e10cSrcweir 	checkReadOnly();
843cdf0e10cSrcweir 
844cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateNumericObject(columnIndex, x, scale);
845cdf0e10cSrcweir }
846cdf0e10cSrcweir 
847cdf0e10cSrcweir //------------------------------------------------------------------------------
updateObject(sal_Int32 columnIndex,const Any & x)848cdf0e10cSrcweir void OResultSet::updateObject(sal_Int32 columnIndex, const Any& x) throw( SQLException, RuntimeException )
849cdf0e10cSrcweir {
850cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateObject" );
851cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
852cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
853cdf0e10cSrcweir 
854cdf0e10cSrcweir 	checkReadOnly();
855cdf0e10cSrcweir 
856cdf0e10cSrcweir 	m_xDelegatorRowUpdate->updateObject(columnIndex, x);
857cdf0e10cSrcweir }
858cdf0e10cSrcweir 
859cdf0e10cSrcweir // ::com::sun::star::sdbc::XResultSet
860cdf0e10cSrcweir //------------------------------------------------------------------------------
next(void)861cdf0e10cSrcweir sal_Bool OResultSet::next(void) throw( SQLException, RuntimeException )
862cdf0e10cSrcweir {
863cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::next" );
864cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
865cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
866cdf0e10cSrcweir 
867cdf0e10cSrcweir 	return m_xDelegatorResultSet->next();
868cdf0e10cSrcweir }
869cdf0e10cSrcweir 
870cdf0e10cSrcweir //------------------------------------------------------------------------------
isBeforeFirst(void)871cdf0e10cSrcweir sal_Bool OResultSet::isBeforeFirst(void) throw( SQLException, RuntimeException )
872cdf0e10cSrcweir {
873cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isBeforeFirst" );
874cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
875cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
876cdf0e10cSrcweir 
877cdf0e10cSrcweir 	return m_xDelegatorResultSet->isBeforeFirst();
878cdf0e10cSrcweir }
879cdf0e10cSrcweir 
880cdf0e10cSrcweir //------------------------------------------------------------------------------
isAfterLast(void)881cdf0e10cSrcweir sal_Bool OResultSet::isAfterLast(void) throw( SQLException, RuntimeException )
882cdf0e10cSrcweir {
883cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isAfterLast" );
884cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
885cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
886cdf0e10cSrcweir 
887cdf0e10cSrcweir 	return m_xDelegatorResultSet->isAfterLast();
888cdf0e10cSrcweir }
889cdf0e10cSrcweir 
890cdf0e10cSrcweir //------------------------------------------------------------------------------
isFirst(void)891cdf0e10cSrcweir sal_Bool OResultSet::isFirst(void) throw( SQLException, RuntimeException )
892cdf0e10cSrcweir {
893cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isFirst" );
894cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
895cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
896cdf0e10cSrcweir 
897cdf0e10cSrcweir 	return m_xDelegatorResultSet->isFirst();
898cdf0e10cSrcweir }
899cdf0e10cSrcweir 
900cdf0e10cSrcweir //------------------------------------------------------------------------------
isLast(void)901cdf0e10cSrcweir sal_Bool OResultSet::isLast(void) throw( SQLException, RuntimeException )
902cdf0e10cSrcweir {
903cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::isLast" );
904cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
905cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
906cdf0e10cSrcweir 
907cdf0e10cSrcweir 	return m_xDelegatorResultSet->isLast();
908cdf0e10cSrcweir }
909cdf0e10cSrcweir 
910cdf0e10cSrcweir //------------------------------------------------------------------------------
beforeFirst(void)911cdf0e10cSrcweir void OResultSet::beforeFirst(void) throw( SQLException, RuntimeException )
912cdf0e10cSrcweir {
913cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::beforeFirst" );
914cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
915cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
916cdf0e10cSrcweir 
917cdf0e10cSrcweir 	m_xDelegatorResultSet->beforeFirst();
918cdf0e10cSrcweir }
919cdf0e10cSrcweir 
920cdf0e10cSrcweir //------------------------------------------------------------------------------
afterLast(void)921cdf0e10cSrcweir void OResultSet::afterLast(void) throw( SQLException, RuntimeException )
922cdf0e10cSrcweir {
923cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::afterLast" );
924cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
925cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
926cdf0e10cSrcweir 
927cdf0e10cSrcweir 	m_xDelegatorResultSet->afterLast();
928cdf0e10cSrcweir }
929cdf0e10cSrcweir 
930cdf0e10cSrcweir //------------------------------------------------------------------------------
first(void)931cdf0e10cSrcweir sal_Bool OResultSet::first(void) throw( SQLException, RuntimeException )
932cdf0e10cSrcweir {
933cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::first" );
934cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
935cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
936cdf0e10cSrcweir 
937cdf0e10cSrcweir 	return m_xDelegatorResultSet->first();
938cdf0e10cSrcweir }
939cdf0e10cSrcweir 
940cdf0e10cSrcweir //------------------------------------------------------------------------------
last(void)941cdf0e10cSrcweir sal_Bool OResultSet::last(void) throw( SQLException, RuntimeException )
942cdf0e10cSrcweir {
943cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::last" );
944cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
945cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
946cdf0e10cSrcweir 
947cdf0e10cSrcweir 	return m_xDelegatorResultSet->last();
948cdf0e10cSrcweir }
949cdf0e10cSrcweir 
950cdf0e10cSrcweir //------------------------------------------------------------------------------
getRow(void)951cdf0e10cSrcweir sal_Int32 OResultSet::getRow(void) throw( SQLException, RuntimeException )
952cdf0e10cSrcweir {
953cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getRow" );
954cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
955cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
956cdf0e10cSrcweir 
957cdf0e10cSrcweir 	return m_xDelegatorResultSet->getRow();
958cdf0e10cSrcweir }
959cdf0e10cSrcweir 
960cdf0e10cSrcweir //------------------------------------------------------------------------------
absolute(sal_Int32 row)961cdf0e10cSrcweir sal_Bool OResultSet::absolute(sal_Int32 row) throw( SQLException, RuntimeException )
962cdf0e10cSrcweir {
963cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::absolute" );
964cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
965cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
966cdf0e10cSrcweir 
967cdf0e10cSrcweir 	return m_xDelegatorResultSet->absolute(row);
968cdf0e10cSrcweir }
969cdf0e10cSrcweir 
970cdf0e10cSrcweir //------------------------------------------------------------------------------
relative(sal_Int32 rows)971cdf0e10cSrcweir sal_Bool OResultSet::relative(sal_Int32 rows) throw( SQLException, RuntimeException )
972cdf0e10cSrcweir {
973cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::relative" );
974cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
975cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
976cdf0e10cSrcweir 
977cdf0e10cSrcweir 	return m_xDelegatorResultSet->relative(rows);
978cdf0e10cSrcweir }
979cdf0e10cSrcweir 
980cdf0e10cSrcweir //------------------------------------------------------------------------------
previous(void)981cdf0e10cSrcweir sal_Bool OResultSet::previous(void) throw( SQLException, RuntimeException )
982cdf0e10cSrcweir {
983cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::previous" );
984cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
985cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
986cdf0e10cSrcweir 
987cdf0e10cSrcweir 	return m_xDelegatorResultSet->previous();
988cdf0e10cSrcweir }
989cdf0e10cSrcweir 
990cdf0e10cSrcweir //------------------------------------------------------------------------------
refreshRow(void)991cdf0e10cSrcweir void OResultSet::refreshRow(void) throw( SQLException, RuntimeException )
992cdf0e10cSrcweir {
993cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::refreshRow" );
994cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
995cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
996cdf0e10cSrcweir 
997cdf0e10cSrcweir 	m_xDelegatorResultSet->refreshRow();
998cdf0e10cSrcweir }
999cdf0e10cSrcweir 
1000cdf0e10cSrcweir //------------------------------------------------------------------------------
rowUpdated(void)1001cdf0e10cSrcweir sal_Bool OResultSet::rowUpdated(void) throw( SQLException, RuntimeException )
1002cdf0e10cSrcweir {
1003cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowUpdated" );
1004cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1005cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1006cdf0e10cSrcweir 
1007cdf0e10cSrcweir 	return m_xDelegatorResultSet->rowUpdated();
1008cdf0e10cSrcweir }
1009cdf0e10cSrcweir 
1010cdf0e10cSrcweir //------------------------------------------------------------------------------
rowInserted(void)1011cdf0e10cSrcweir sal_Bool OResultSet::rowInserted(void) throw( SQLException, RuntimeException )
1012cdf0e10cSrcweir {
1013cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowInserted" );
1014cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1015cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1016cdf0e10cSrcweir 
1017cdf0e10cSrcweir 	return m_xDelegatorResultSet->rowInserted();
1018cdf0e10cSrcweir }
1019cdf0e10cSrcweir 
1020cdf0e10cSrcweir //------------------------------------------------------------------------------
rowDeleted(void)1021cdf0e10cSrcweir sal_Bool OResultSet::rowDeleted(void) throw( SQLException, RuntimeException )
1022cdf0e10cSrcweir {
1023cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::rowDeleted" );
1024cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1025cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1026cdf0e10cSrcweir 
1027cdf0e10cSrcweir 	return m_xDelegatorResultSet->rowDeleted();
1028cdf0e10cSrcweir }
1029cdf0e10cSrcweir 
1030cdf0e10cSrcweir //------------------------------------------------------------------------------
getStatement(void)1031cdf0e10cSrcweir Reference< XInterface > OResultSet::getStatement(void) throw( SQLException, RuntimeException )
1032cdf0e10cSrcweir {
1033cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getStatement" );
1034cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1035cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1036cdf0e10cSrcweir 
1037cdf0e10cSrcweir 	return m_aStatement;
1038cdf0e10cSrcweir }
1039cdf0e10cSrcweir 
1040cdf0e10cSrcweir // ::com::sun::star::sdbcx::XRowLocate
1041cdf0e10cSrcweir //------------------------------------------------------------------------------
getBookmark(void)1042cdf0e10cSrcweir Any OResultSet::getBookmark(void) throw( SQLException, RuntimeException )
1043cdf0e10cSrcweir {
1044cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::getBookmark" );
1045cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1046cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1047cdf0e10cSrcweir 
1048cdf0e10cSrcweir 	checkBookmarkable();
1049cdf0e10cSrcweir 
1050cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->getBookmark();
1051cdf0e10cSrcweir }
1052cdf0e10cSrcweir 
1053cdf0e10cSrcweir //------------------------------------------------------------------------------
moveToBookmark(const Any & bookmark)1054cdf0e10cSrcweir sal_Bool OResultSet::moveToBookmark(const Any& bookmark) throw( SQLException, RuntimeException )
1055cdf0e10cSrcweir {
1056cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToBookmark" );
1057cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1058cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1059cdf0e10cSrcweir 
1060cdf0e10cSrcweir 	checkBookmarkable();
1061cdf0e10cSrcweir 
1062cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->moveToBookmark(bookmark);
1063cdf0e10cSrcweir }
1064cdf0e10cSrcweir 
1065cdf0e10cSrcweir //------------------------------------------------------------------------------
moveRelativeToBookmark(const Any & bookmark,sal_Int32 rows)1066cdf0e10cSrcweir sal_Bool OResultSet::moveRelativeToBookmark(const Any& bookmark, sal_Int32 rows) throw( SQLException, RuntimeException )
1067cdf0e10cSrcweir {
1068cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveRelativeToBookmark" );
1069cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1070cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1071cdf0e10cSrcweir 
1072cdf0e10cSrcweir 	checkBookmarkable();
1073cdf0e10cSrcweir 
1074cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->moveRelativeToBookmark(bookmark, rows);
1075cdf0e10cSrcweir }
1076cdf0e10cSrcweir 
1077cdf0e10cSrcweir //------------------------------------------------------------------------------
compareBookmarks(const Any & _first,const Any & _second)1078cdf0e10cSrcweir sal_Int32 OResultSet::compareBookmarks(const Any& _first, const Any& _second) throw( SQLException, RuntimeException )
1079cdf0e10cSrcweir {
1080cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::compareBookmarks" );
1081cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1082cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1083cdf0e10cSrcweir 
1084cdf0e10cSrcweir 	checkBookmarkable();
1085cdf0e10cSrcweir 
1086cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->compareBookmarks(_first, _second);
1087cdf0e10cSrcweir }
1088cdf0e10cSrcweir 
1089cdf0e10cSrcweir //------------------------------------------------------------------------------
hasOrderedBookmarks(void)1090cdf0e10cSrcweir sal_Bool OResultSet::hasOrderedBookmarks(void) throw( SQLException, RuntimeException )
1091cdf0e10cSrcweir {
1092cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::hasOrderedBookmarks" );
1093cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1094cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1095cdf0e10cSrcweir 
1096cdf0e10cSrcweir 	checkBookmarkable();
1097cdf0e10cSrcweir 
1098cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->hasOrderedBookmarks();
1099cdf0e10cSrcweir }
1100cdf0e10cSrcweir 
1101cdf0e10cSrcweir //------------------------------------------------------------------------------
hashBookmark(const Any & bookmark)1102cdf0e10cSrcweir sal_Int32 OResultSet::hashBookmark(const Any& bookmark) throw( SQLException, RuntimeException )
1103cdf0e10cSrcweir {
1104cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::hashBookmark" );
1105cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1106cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1107cdf0e10cSrcweir 
1108cdf0e10cSrcweir 	checkBookmarkable();
1109cdf0e10cSrcweir 
1110cdf0e10cSrcweir 	return Reference< XRowLocate >(m_xDelegatorResultSet, UNO_QUERY)->hashBookmark(bookmark);
1111cdf0e10cSrcweir }
1112cdf0e10cSrcweir 
1113cdf0e10cSrcweir // ::com::sun::star::sdbc::XResultSetUpdate
1114cdf0e10cSrcweir //------------------------------------------------------------------------------
insertRow(void)1115cdf0e10cSrcweir void OResultSet::insertRow(void) throw( SQLException, RuntimeException )
1116cdf0e10cSrcweir {
1117cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::insertRow" );
1118cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1119cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1120cdf0e10cSrcweir 
1121cdf0e10cSrcweir 	checkReadOnly();
1122cdf0e10cSrcweir 
1123cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->insertRow();
1124cdf0e10cSrcweir }
1125cdf0e10cSrcweir 
1126cdf0e10cSrcweir //------------------------------------------------------------------------------
updateRow(void)1127cdf0e10cSrcweir void OResultSet::updateRow(void) throw( SQLException, RuntimeException )
1128cdf0e10cSrcweir {
1129cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::updateRow" );
1130cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1131cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1132cdf0e10cSrcweir 
1133cdf0e10cSrcweir 	checkReadOnly();
1134cdf0e10cSrcweir 
1135cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->updateRow();
1136cdf0e10cSrcweir }
1137cdf0e10cSrcweir 
1138cdf0e10cSrcweir //------------------------------------------------------------------------------
deleteRow(void)1139cdf0e10cSrcweir void OResultSet::deleteRow(void) throw( SQLException, RuntimeException )
1140cdf0e10cSrcweir {
1141cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::deleteRow" );
1142cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1143cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1144cdf0e10cSrcweir 
1145cdf0e10cSrcweir 	checkReadOnly();
1146cdf0e10cSrcweir 
1147cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->deleteRow();
1148cdf0e10cSrcweir }
1149cdf0e10cSrcweir 
1150cdf0e10cSrcweir //------------------------------------------------------------------------------
cancelRowUpdates(void)1151cdf0e10cSrcweir void OResultSet::cancelRowUpdates(void) throw( SQLException, RuntimeException )
1152cdf0e10cSrcweir {
1153cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::cancelRowUpdates" );
1154cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1155cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1156cdf0e10cSrcweir 
1157cdf0e10cSrcweir 	checkReadOnly();
1158cdf0e10cSrcweir 
1159cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->cancelRowUpdates();
1160cdf0e10cSrcweir }
1161cdf0e10cSrcweir 
1162cdf0e10cSrcweir //------------------------------------------------------------------------------
moveToInsertRow(void)1163cdf0e10cSrcweir void OResultSet::moveToInsertRow(void) throw( SQLException, RuntimeException )
1164cdf0e10cSrcweir {
1165cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToInsertRow" );
1166cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1167cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1168cdf0e10cSrcweir 
1169cdf0e10cSrcweir 	checkReadOnly();
1170cdf0e10cSrcweir 
1171cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->moveToInsertRow();
1172cdf0e10cSrcweir }
1173cdf0e10cSrcweir 
1174cdf0e10cSrcweir //------------------------------------------------------------------------------
moveToCurrentRow(void)1175cdf0e10cSrcweir void OResultSet::moveToCurrentRow(void) throw( SQLException, RuntimeException )
1176cdf0e10cSrcweir {
1177cdf0e10cSrcweir     RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::moveToCurrentRow" );
1178cdf0e10cSrcweir 	MutexGuard aGuard(m_aMutex);
1179cdf0e10cSrcweir 	::connectivity::checkDisposed(OResultSetBase::rBHelper.bDisposed);
1180cdf0e10cSrcweir 
1181cdf0e10cSrcweir 	checkReadOnly();
1182cdf0e10cSrcweir 
1183cdf0e10cSrcweir 	m_xDelegatorResultSetUpdate->moveToCurrentRow();
1184cdf0e10cSrcweir }
1185cdf0e10cSrcweir 
1186cdf0e10cSrcweir // -----------------------------------------------------------------------------
checkReadOnly() const1187cdf0e10cSrcweir void OResultSet::checkReadOnly() const
1188cdf0e10cSrcweir {
1189cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::checkReadOnly" );
1190cdf0e10cSrcweir     if  (   ( m_nResultSetConcurrency == ResultSetConcurrency::READ_ONLY )
1191cdf0e10cSrcweir         ||  !m_xDelegatorResultSetUpdate.is()
1192cdf0e10cSrcweir         )
1193cdf0e10cSrcweir         throwSQLException( "The result set is read-only.", SQL_GENERAL_ERROR, *const_cast< OResultSet* >( this ) );
1194cdf0e10cSrcweir }
1195cdf0e10cSrcweir 
1196cdf0e10cSrcweir // -----------------------------------------------------------------------------
checkBookmarkable() const1197cdf0e10cSrcweir void OResultSet::checkBookmarkable() const
1198cdf0e10cSrcweir {
1199cdf0e10cSrcweir     //RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "dbaccess", "Ocke.Janssen@sun.com", "OResultSet::checkBookmarkable" );
1200cdf0e10cSrcweir 	if ( !m_bIsBookmarkable )
1201cdf0e10cSrcweir         throwSQLException( "The result set does not have bookmark support.", SQL_GENERAL_ERROR, *const_cast< OResultSet* >( this ) );
1202cdf0e10cSrcweir }
1203cdf0e10cSrcweir // -----------------------------------------------------------------------------
1204cdf0e10cSrcweir 
1205