LibreOffice Module dbaccess (master) 1
RowSetBase.hxx
Go to the documentation of this file.
1/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
2/*
3 * This file is part of the LibreOffice project.
4 *
5 * This Source Code Form is subject to the terms of the Mozilla Public
6 * License, v. 2.0. If a copy of the MPL was not distributed with this
7 * file, You can obtain one at http://mozilla.org/MPL/2.0/.
8 *
9 * This file incorporates work covered by the following license notice:
10 *
11 * Licensed to the Apache Software Foundation (ASF) under one or more
12 * contributor license agreements. See the NOTICE file distributed
13 * with this work for additional information regarding copyright
14 * ownership. The ASF licenses this file to you under the Apache
15 * License, Version 2.0 (the "License"); you may not use this file
16 * except in compliance with the License. You may obtain a copy of
17 * the License at http://www.apache.org/licenses/LICENSE-2.0 .
18 */
19#pragma once
20
21#include <memory>
23#include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
24#include <com/sun/star/sdbc/XRow.hpp>
25#include <com/sun/star/sdbc/XColumnLocate.hpp>
26#include <com/sun/star/sdbc/XCloseable.hpp>
27#include <com/sun/star/sdbcx/XRowLocate.hpp>
28#include <com/sun/star/sdbc/XResultSetMetaDataSupplier.hpp>
29#include <com/sun/star/sdbc/XWarningsSupplier.hpp>
30#include <com/sun/star/lang/XServiceInfo.hpp>
36#include <com/sun/star/sdbc/XRowSet.hpp>
37#include <com/sun/star/util/XNumberFormatTypes.hpp>
38#include <com/sun/star/container/XNameAccess.hpp>
39#include "RowSetRow.hxx"
41
42#include <functional>
43
44namespace com::sun::star {
45 namespace sdb { struct RowChangeEvent; }
46 namespace lang { struct Locale; }
47}
48
49namespace dbaccess
50{
51 class OEmptyCollection;
52
53 typedef ::cppu::ImplHelper9< css::sdbcx::XRowLocate,
54 css::sdbc::XRow,
55 css::sdbc::XResultSetMetaDataSupplier,
56 css::sdbc::XWarningsSupplier,
57 css::sdbc::XColumnLocate,
58 css::sdbcx::XColumnsSupplier,
59 css::lang::XServiceInfo,
60 css::sdbc::XRowSet,
61 css::sdbc::XCloseable> ORowSetBase_BASE;
62
63 class ORowSetCache;
69 public ::comphelper::OPropertyArrayUsageHelper<ORowSetBase> // this class hold the static property info
70 {
71 protected:
72 typedef std::vector<ORowSetDataColumn*> TDataColumns;
73 ::osl::Mutex* m_pMutex; // this is the mutex from the rowset itself
74 ::osl::Mutex // we need an extra mutex for columns to prevent deadlock when setting new values
75 // for a row
77
78 css::uno::Any m_aBookmark;
79 ORowSetCacheIterator m_aCurrentRow; // contains the actual fetched row
81 TDataColumns m_aDataColumns; // holds the columns as m_pColumns but know the implementation class
83
84 ::cppu::OWeakObject* m_pMySelf; // set by derived classes
85 std::shared_ptr<ORowSetCache> m_pCache; // the cache is used by the rowset and his clone (shared)
86 std::unique_ptr<ORowSetDataColumns> m_pColumns; // represent the select columns
87 ::cppu::OBroadcastHelper& m_rBHelper; // must be set from the derived classes
88 // is used when the formatkey for database types is set
89 css::uno::Reference< css::util::XNumberFormatTypes> m_xNumberFormatTypes;
90 std::unique_ptr<OEmptyCollection> m_pEmptyCollection;
91
92 css::uno::Reference< css::uno::XComponentContext> m_aContext;
94
95 sal_Int32 m_nLastColumnIndex; // the last column ask for, used for wasNull()
96 sal_Int32 m_nDeletedPosition; // is set only when a row was deleted
97 sal_Int32 m_nResultSetType; // fetch property
99 bool m_bClone; // I'm clone or not
102 bool m_bAfterLast : 1;
104
105 protected:
107 const css::uno::Reference<css::uno::XComponentContext>& _rContext,
108 ::cppu::OBroadcastHelper& _rBHelper,
109 ::osl::Mutex* _pMutex
110 );
111
112 // fire a notification for all that are listening on column::VALUE property
113 void firePropertyChange(const ORowSetRow& _rOldRow);
114 // fire a change for one column
115 // _nPos starts at zero
116 void firePropertyChange(sal_Int32 _nPos,const ::connectivity::ORowSetValue& _rNewValue);
117
118 // fire if rowcount changed
119 virtual void fireRowcount();
120 // notify row changed
121 virtual bool notifyAllListenersCursorBeforeMove(::osl::ResettableMutexGuard& _rGuard);
122 // notify cursor moved
123 virtual void notifyAllListenersCursorMoved(::osl::ResettableMutexGuard& _rGuard);
124
125 // cancel the insertion, if necessary (means if we're on the insert row)
126 virtual void doCancelModification( ) = 0;
127 // return <TRUE/> if and only if we're using the insert row (means: we're updating _or_ inserting)
128 virtual bool isModification( ) = 0;
129 // return <TRUE/> if and only if the current row is modified
130 // TODO: isn't this the same as isModification?
131 virtual bool isModified( ) = 0;
132 // return <TRUE/> if and only if the current row is the insert row
133 virtual bool isNew( ) = 0;
134 // return <TRUE/> if the property change notification should be fired
135 // upon property change.
136 virtual bool isPropertyChangeNotificationEnabled() const;
137 // notify the change of a boolean property
138 void fireProperty( sal_Int32 _nProperty, bool _bNew, bool _bOld );
139
140 // OPropertyStateContainer
141 virtual void getPropertyDefaultByHandle( sal_Int32 _nHandle, css::uno::Any& _rDefault ) const override;
142 virtual void SAL_CALL getFastPropertyValue(css::uno::Any& rValue,sal_Int32 nHandle) const override;
143
145 {
147 Forward,
149 Backward,
151 Current,
153 CurrentRefresh
154 };
171 void positionCache( CursorMoveDirection _ePrepareForDirection );
172
173 // returns a value of a column of the current row
174 const connectivity::ORowSetValue& getValue(sal_Int32 columnIndex);
175 // the cache has to be checked before calling this method
176 const connectivity::ORowSetValue& impl_getValue(sal_Int32 columnIndex);
177 // sets the current and the bookmark
178 void setCurrentRow( bool _bMoved, bool _bDoNotify, const ORowSetRow& _rOldValues, ::osl::ResettableMutexGuard& _rGuard);
182 // checks if the cache is null
183 void checkCache();
184 // sets the bookmark to Any()
185 // m_aCurrentRow to end of matrix
186 // m_aOldRow to NULL
187 void movementFailed();
188
189 ORowSetRow getOldRow(bool _bWasNew);
198 bool SAL_CALL move( std::function<bool(ORowSetBase *)> const & _aCheckFunctor,
199 std::function<bool(ORowSetCache *)> const & _aMovementFunctor);
200
205 bool isOnFirst();
210 bool isOnLast();
211
221 sal_Int32 impl_getRowCount() const;
222
223 // the checkCache has to be called before calling this methods
224 sal_Int32 impl_getRow();
225 bool impl_rowDeleted();
226
227 public:
228 virtual ~ORowSetBase() override;
229
230 // OComponentHelper
231 virtual void SAL_CALL disposing();
232
233 // css::beans::XPropertySet
234 virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) override
235 {
236 return ::cppu::OPropertySetHelper::createPropertySetInfo(getInfoHelper());
237 }
238
239 // comphelper::OPropertyArrayUsageHelper
240 virtual ::cppu::IPropertyArrayHelper* createArrayHelper( ) const override;
241
242 // cppu::OPropertySetHelper
243 virtual ::cppu::IPropertyArrayHelper& SAL_CALL getInfoHelper() override;
244
245 // css::lang::XTypeProvider
246 virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override;
247
248 // css::uno::XInterface
249 virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type & rType ) override;
250
251 // css::sdbc::XWarningsSupplier
252 virtual css::uno::Any SAL_CALL getWarnings( ) override;
253 virtual void SAL_CALL clearWarnings( ) override;
254
255 // css::sdbc::XResultSetMetaDataSupplier
256 virtual css::uno::Reference< css::sdbc::XResultSetMetaData > SAL_CALL getMetaData( ) override;
257
258 // css::sdbc::XColumnLocate
259 virtual sal_Int32 SAL_CALL findColumn( const OUString& columnName ) override;
260
261 // css::sdbcx::XColumnsSupplier
262 virtual css::uno::Reference< css::container::XNameAccess > SAL_CALL getColumns( ) override;
263
264 // css::sdbc::XRow
265 virtual sal_Bool SAL_CALL wasNull( ) override;
266 virtual OUString SAL_CALL getString( sal_Int32 columnIndex ) override;
267 virtual sal_Bool SAL_CALL getBoolean( sal_Int32 columnIndex ) override;
268 virtual sal_Int8 SAL_CALL getByte( sal_Int32 columnIndex ) override;
269 virtual sal_Int16 SAL_CALL getShort( sal_Int32 columnIndex ) override;
270 virtual sal_Int32 SAL_CALL getInt( sal_Int32 columnIndex ) override;
271 virtual sal_Int64 SAL_CALL getLong( sal_Int32 columnIndex ) override;
272 virtual float SAL_CALL getFloat( sal_Int32 columnIndex ) override;
273 virtual double SAL_CALL getDouble( sal_Int32 columnIndex ) override;
274 virtual css::uno::Sequence< sal_Int8 > SAL_CALL getBytes( sal_Int32 columnIndex ) override;
275 virtual css::util::Date SAL_CALL getDate( sal_Int32 columnIndex ) override;
276 virtual css::util::Time SAL_CALL getTime( sal_Int32 columnIndex ) override;
277 virtual css::util::DateTime SAL_CALL getTimestamp( sal_Int32 columnIndex ) override;
278 virtual css::uno::Reference< css::io::XInputStream > SAL_CALL getBinaryStream( sal_Int32 columnIndex ) override;
279 virtual css::uno::Reference< css::io::XInputStream > SAL_CALL getCharacterStream( sal_Int32 columnIndex ) override;
280 virtual css::uno::Any SAL_CALL getObject( sal_Int32 columnIndex, const css::uno::Reference< css::container::XNameAccess >& typeMap ) override;
281 virtual css::uno::Reference< css::sdbc::XRef > SAL_CALL getRef( sal_Int32 columnIndex ) override;
282 virtual css::uno::Reference< css::sdbc::XBlob > SAL_CALL getBlob( sal_Int32 columnIndex ) override;
283 virtual css::uno::Reference< css::sdbc::XClob > SAL_CALL getClob( sal_Int32 columnIndex ) override;
284 virtual css::uno::Reference< css::sdbc::XArray > SAL_CALL getArray( sal_Int32 columnIndex ) override;
285
286 // css::sdbcx::XRowLocate
287 virtual css::uno::Any SAL_CALL getBookmark( ) override;
288 virtual sal_Bool SAL_CALL moveToBookmark( const css::uno::Any& bookmark ) override;
289 virtual sal_Bool SAL_CALL moveRelativeToBookmark( const css::uno::Any& bookmark, sal_Int32 rows ) override;
290 virtual sal_Int32 SAL_CALL compareBookmarks( const css::uno::Any& first, const css::uno::Any& second ) override;
291 virtual sal_Bool SAL_CALL hasOrderedBookmarks( ) override;
292 virtual sal_Int32 SAL_CALL hashBookmark( const css::uno::Any& bookmark ) override;
293
294 // css::sdbc::XResultSet
295 virtual sal_Bool SAL_CALL next( ) override;
296 virtual sal_Bool SAL_CALL isBeforeFirst( ) override;
297 virtual sal_Bool SAL_CALL isAfterLast( ) override;
298 virtual sal_Bool SAL_CALL isFirst( ) override;
299 virtual sal_Bool SAL_CALL isLast( ) override;
300 virtual void SAL_CALL beforeFirst( ) override;
301 virtual void SAL_CALL afterLast( ) override;
302 virtual sal_Bool SAL_CALL first( ) override;
303 virtual sal_Bool SAL_CALL last( ) override;
304 virtual sal_Int32 SAL_CALL getRow( ) override;
305 virtual sal_Bool SAL_CALL absolute( sal_Int32 row ) override;
306 virtual sal_Bool SAL_CALL relative( sal_Int32 rows ) override;
307 virtual sal_Bool SAL_CALL previous( ) override;
308 virtual void SAL_CALL refreshRow( ) override;
309 virtual sal_Bool SAL_CALL rowUpdated( ) override;
310 virtual sal_Bool SAL_CALL rowInserted( ) override;
311 virtual sal_Bool SAL_CALL rowDeleted( ) override;
312 virtual css::uno::Reference< css::uno::XInterface > SAL_CALL getStatement( ) override;
313
314 // css::sdbc::XRowSet
315 virtual void SAL_CALL execute( ) override = 0;
316 virtual void SAL_CALL addRowSetListener( const css::uno::Reference< css::sdbc::XRowSetListener >& listener ) override = 0;
317 virtual void SAL_CALL removeRowSetListener( const css::uno::Reference< css::sdbc::XRowSetListener >& listener ) override = 0;
318
319 // is called when the rowset is going to delete this bookmark _rBookmark
320 void onDeleteRow( const css::uno::Any& _rBookmark );
321 // is called when the rowset has deleted this bookmark _rBookmark
322 void onDeletedRow( const css::uno::Any& _rBookmark, sal_Int32 _nPos );
323
324 // granular access control
325 struct GrantNotifierAccess { friend class ORowSetNotifier; private: GrantNotifierAccess () { } };
326
327 // cancel the insertion, if necessary (means if we're on the insert row)
330 bool isModified( const GrantNotifierAccess& ) { return isModified(); }
331 bool isNew( const GrantNotifierAccess& ) { return isNew(); }
332 bool isInsertRow() const { return m_bIsInsertRow; } // isNew() || isModified(); }
333 void fireProperty( sal_Int32 _nProperty, bool _bNew, bool _bOld, const GrantNotifierAccess& )
334 {
335 fireProperty( _nProperty, _bNew, _bOld );
336 }
337 void firePropertyChange(sal_Int32 _nPos,const ::connectivity::ORowSetValue& _rNewValue, const GrantNotifierAccess& )
338 {
339 firePropertyChange(_nPos,_rNewValue);
340 }
341 using ::comphelper::OPropertyStateContainer::getFastPropertyValue;
342 };
343
349 {
350 private:
351 std::vector<sal_Int32> aChangedColumns;
354 // not acquired! This is not necessary because this class here is to be used on the stack within
355 // a method of ORowSetBase (or derivees)
358
359 public:
365
369
370 // destructs the object. <member>fire</member> has to be called before.
372
383 void fire();
384
390 void firePropertyChange();
391
394 std::vector<sal_Int32>& getChangedColumns();
395
396 };
397
398} // end of namespace
399
400/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
std::vector< VectorVal > Vector
void doCancelModification(const GrantNotifierAccess &)
Definition: RowSetBase.hxx:328
virtual sal_Bool SAL_CALL absolute(sal_Int32 row) override
Definition: RowSetBase.cxx:874
virtual css::uno::Reference< css::sdbc::XClob > SAL_CALL getClob(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:383
ORowSetCacheIterator m_aCurrentRow
Definition: RowSetBase.hxx:79
virtual OUString SAL_CALL getString(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:250
bool isInsertRow() const
Definition: RowSetBase.hxx:332
virtual css::uno::Any SAL_CALL getWarnings() override
sal_Int32 m_nLastColumnIndex
Definition: RowSetBase.hxx:95
virtual void SAL_CALL getFastPropertyValue(css::uno::Any &rValue, sal_Int32 nHandle) const override
Definition: RowSetBase.cxx:126
const connectivity::ORowSetValue & getValue(sal_Int32 columnIndex)
Definition: RowSetBase.cxx:187
virtual sal_Int32 SAL_CALL compareBookmarks(const css::uno::Any &first, const css::uno::Any &second) override
Definition: RowSetBase.cxx:505
virtual css::util::Time SAL_CALL getTime(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:310
TORowSetOldRowHelperRef m_aOldRow
Definition: RowSetBase.hxx:80
virtual sal_Bool SAL_CALL rowDeleted() override
std::unique_ptr< ORowSetDataColumns > m_pColumns
Definition: RowSetBase.hxx:86
std::unique_ptr< OEmptyCollection > m_pEmptyCollection
Definition: RowSetBase.hxx:90
virtual sal_Bool SAL_CALL relative(sal_Int32 rows) override
Definition: RowSetBase.cxx:919
bool isModified(const GrantNotifierAccess &)
Definition: RowSetBase.hxx:330
::connectivity::SQLError m_aErrors
Definition: RowSetBase.hxx:93
virtual css::uno::Any SAL_CALL getObject(sal_Int32 columnIndex, const css::uno::Reference< css::container::XNameAccess > &typeMap) override
Definition: RowSetBase.cxx:364
::cppu::OBroadcastHelper & m_rBHelper
Definition: RowSetBase.hxx:87
virtual void notifyAllListenersCursorMoved(::osl::ResettableMutexGuard &_rGuard)
virtual sal_Int32 SAL_CALL hashBookmark(const css::uno::Any &bookmark) override
Definition: RowSetBase.cxx:519
virtual css::uno::Reference< css::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() override
Definition: RowSetBase.hxx:234
virtual css::uno::Reference< css::container::XNameAccess > SAL_CALL getColumns() override
Definition: RowSetBase.cxx:549
bool isModification(const GrantNotifierAccess &)
Definition: RowSetBase.hxx:329
virtual void fireRowcount()
virtual sal_Bool SAL_CALL moveToBookmark(const css::uno::Any &bookmark) override
Definition: RowSetBase.cxx:412
virtual sal_Int64 SAL_CALL getLong(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:280
virtual css::uno::Any SAL_CALL getBookmark() override
Definition: RowSetBase.cxx:395
virtual bool isPropertyChangeNotificationEnabled() const
TDataColumns m_aDataColumns
Definition: RowSetBase.hxx:81
virtual sal_Int32 SAL_CALL getInt(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:274
virtual sal_Bool SAL_CALL rowUpdated() override
virtual css::uno::Sequence< sal_Int8 > SAL_CALL getBytes(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:298
void fireProperty(sal_Int32 _nProperty, bool _bNew, bool _bOld)
virtual css::uno::Reference< css::sdbc::XBlob > SAL_CALL getBlob(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:378
virtual sal_Bool SAL_CALL last() override
Definition: RowSetBase.cxx:837
virtual bool isModified()=0
virtual css::uno::Reference< css::io::XInputStream > SAL_CALL getBinaryStream(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:322
void onDeleteRow(const css::uno::Any &_rBookmark)
virtual sal_Bool SAL_CALL next() override
Definition: RowSetBase.cxx:565
virtual css::uno::Reference< css::sdbc::XArray > SAL_CALL getArray(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:388
bool isNew(const GrantNotifierAccess &)
Definition: RowSetBase.hxx:331
virtual void SAL_CALL clearWarnings() override
virtual css::uno::Reference< css::sdbc::XResultSetMetaData > SAL_CALL getMetaData() override
Definition: RowSetBase.cxx:527
virtual void SAL_CALL beforeFirst() override
Definition: RowSetBase.cxx:702
virtual css::util::DateTime SAL_CALL getTimestamp(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:316
virtual css::uno::Reference< css::sdbc::XRef > SAL_CALL getRef(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:372
connectivity::ORowSetValue m_aEmptyValue
Definition: RowSetBase.hxx:82
virtual sal_Bool SAL_CALL isAfterLast() override
Definition: RowSetBase.cxx:636
bool isOnFirst()
same meaning as isFirst.
Definition: RowSetBase.cxx:646
::cppu::OWeakObject * m_pMySelf
Definition: RowSetBase.hxx:84
virtual void doCancelModification()=0
css::uno::Reference< css::uno::XComponentContext > m_aContext
Definition: RowSetBase.hxx:92
virtual sal_Bool SAL_CALL first() override
Definition: RowSetBase.cxx:829
virtual sal_Bool SAL_CALL moveRelativeToBookmark(const css::uno::Any &bookmark, sal_Int32 rows) override
Definition: RowSetBase.cxx:462
css::uno::Reference< css::util::XNumberFormatTypes > m_xNumberFormatTypes
Definition: RowSetBase.hxx:89
ORowSetRow getOldRow(bool _bWasNew)
::osl::Mutex m_aColumnsMutex
Definition: RowSetBase.hxx:76
sal_Int32 impl_getRow()
Definition: RowSetBase.cxx:854
sal_Int32 impl_getRowCount() const
returns the current row count
css::uno::Any m_aBookmark
Definition: RowSetBase.hxx:78
sal_Int32 m_nDeletedPosition
Definition: RowSetBase.hxx:96
virtual ::cppu::IPropertyArrayHelper * createArrayHelper() const override
Definition: RowSetBase.cxx:165
virtual ::cppu::IPropertyArrayHelper &SAL_CALL getInfoHelper() override
Definition: RowSetBase.cxx:173
virtual bool isModification()=0
const connectivity::ORowSetValue & impl_getValue(sal_Int32 columnIndex)
Definition: RowSetBase.cxx:193
virtual void SAL_CALL removeRowSetListener(const css::uno::Reference< css::sdbc::XRowSetListener > &listener) override=0
virtual sal_Bool SAL_CALL isBeforeFirst() override
Definition: RowSetBase.cxx:625
virtual bool notifyAllListenersCursorBeforeMove(::osl::ResettableMutexGuard &_rGuard)
void firePropertyChange(sal_Int32 _nPos, const ::connectivity::ORowSetValue &_rNewValue, const GrantNotifierAccess &)
Definition: RowSetBase.hxx:337
virtual float SAL_CALL getFloat(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:286
virtual bool isNew()=0
virtual sal_Bool SAL_CALL isFirst() override
Definition: RowSetBase.cxx:651
virtual css::util::Date SAL_CALL getDate(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:304
virtual sal_Int8 SAL_CALL getByte(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:262
void onDeletedRow(const css::uno::Any &_rBookmark, sal_Int32 _nPos)
virtual sal_Int32 SAL_CALL findColumn(const OUString &columnName) override
Definition: RowSetBase.cxx:539
virtual void SAL_CALL afterLast() override
Definition: RowSetBase.cxx:743
virtual void SAL_CALL execute() override=0
void setCurrentRow(bool _bMoved, bool _bDoNotify, const ORowSetRow &_rOldValues, ::osl::ResettableMutexGuard &_rGuard)
virtual sal_Bool SAL_CALL rowInserted() override
virtual css::uno::Reference< css::io::XInputStream > SAL_CALL getCharacterStream(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:359
virtual void getPropertyDefaultByHandle(sal_Int32 _nHandle, css::uno::Any &_rDefault) const override
virtual sal_Bool SAL_CALL hasOrderedBookmarks() override
Definition: RowSetBase.cxx:512
virtual void SAL_CALL addRowSetListener(const css::uno::Reference< css::sdbc::XRowSetListener > &listener) override=0
void positionCache(CursorMoveDirection _ePrepareForDirection)
positions the cache in preparation of a cursor move
virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override
Definition: RowSetBase.cxx:112
bool isOnLast()
same meaning as isLast.
Definition: RowSetBase.cxx:672
virtual css::uno::Any SAL_CALL queryInterface(const css::uno::Type &rType) override
Definition: RowSetBase.cxx:118
ORowSetBase(const css::uno::Reference< css::uno::XComponentContext > &_rContext, ::cppu::OBroadcastHelper &_rBHelper, ::osl::Mutex *_pMutex)
Definition: RowSetBase.cxx:79
virtual void SAL_CALL disposing()
Definition: RowSetBase.cxx:147
void firePropertyChange(const ORowSetRow &_rOldRow)
virtual sal_Bool SAL_CALL wasNull() override
Definition: RowSetBase.cxx:179
virtual css::uno::Reference< css::uno::XInterface > SAL_CALL getStatement() override
virtual sal_Bool SAL_CALL isLast() override
Definition: RowSetBase.cxx:677
virtual sal_Int32 SAL_CALL getRow() override
Definition: RowSetBase.cxx:845
void fireProperty(sal_Int32 _nProperty, bool _bNew, bool _bOld, const GrantNotifierAccess &)
Definition: RowSetBase.hxx:333
std::shared_ptr< ORowSetCache > m_pCache
Definition: RowSetBase.hxx:85
bool SAL_CALL move(std::function< bool(ORowSetBase *)> const &_aCheckFunctor, std::function< bool(ORowSetCache *)> const &_aMovementFunctor)
move the cache the position defined by the member functor
Definition: RowSetBase.cxx:782
sal_Int32 m_nResultSetType
Definition: RowSetBase.hxx:97
virtual sal_Int16 SAL_CALL getShort(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:268
std::vector< ORowSetDataColumn * > TDataColumns
Definition: RowSetBase.hxx:72
virtual sal_Bool SAL_CALL getBoolean(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:256
sal_Int32 m_nResultSetConcurrency
Definition: RowSetBase.hxx:98
virtual ~ORowSetBase() override
Definition: RowSetBase.cxx:101
virtual double SAL_CALL getDouble(sal_Int32 columnIndex) override
Definition: RowSetBase.cxx:292
virtual sal_Bool SAL_CALL previous() override
Definition: RowSetBase.cxx:974
::osl::Mutex * m_pMutex
Definition: RowSetBase.hxx:73
virtual void SAL_CALL refreshRow() override
eases the handling of the doCancelModification and notifyCancelInsert methods
Definition: RowSetBase.hxx:349
ORowSetNotifier(ORowSetBase *m_pRowSet)
constructs the object, and cancels the insertion
void firePropertyChange()
notifies value change events and notifies IsModified
void fire()
notifies the insertion
ORowSetValueVector::Vector aRow
Definition: RowSetBase.hxx:352
std::vector< sal_Int32 > aChangedColumns
Definition: RowSetBase.hxx:351
std::vector< sal_Int32 > & getChangedColumns()
use this one to store the index of the changed column values
::cppu::ImplHelper9< css::sdbcx::XRowLocate, css::sdbc::XRow, css::sdbc::XResultSetMetaDataSupplier, css::sdbc::XWarningsSupplier, css::sdbc::XColumnLocate, css::sdbcx::XColumnsSupplier, css::lang::XServiceInfo, css::sdbc::XRowSet, css::sdbc::XCloseable > ORowSetBase_BASE
Definition: RowSetBase.hxx:51
unsigned char sal_Bool
signed char sal_Int8
sal_Int32 _nPos