summaryrefslogtreecommitdiffstats
path: root/connectivity
diff options
context:
space:
mode:
authorNoel Grandin <noelgrandin@gmail.com>2016-01-19 19:45:45 +0200
committerNoel Grandin <noel@peralex.com>2016-01-25 08:52:03 +0200
commit752cd07d085ac0aadc99bd512d49072843139032 (patch)
tree21ff2f55761b34bfdd721b5e1ed43333e8874e46 /connectivity
parenttdf#86567 Dropdown for conditional formatting (diff)
downloadcore-752cd07d085ac0aadc99bd512d49072843139032.tar.gz
core-752cd07d085ac0aadc99bd512d49072843139032.zip
InterfaceContainer2 with vector instead of Sequence
create an InterfaceContainer2 class to replace InterfaceContainer. It uses a std::vector instead of a Sequence for the mutable listener list, which provides far better performance. Switch all our internal use-sites to the new class. Change-Id: I6b56cfa511ded2395faa22e68fab3b2f16c3cb88
Diffstat (limited to 'connectivity')
-rw-r--r--connectivity/source/commontools/parameters.cxx2
-rw-r--r--connectivity/source/drivers/hsqldb/HTables.cxx2
-rw-r--r--connectivity/source/drivers/mysql/YTables.cxx2
-rw-r--r--connectivity/source/inc/hsqldb/HConnection.hxx4
-rw-r--r--connectivity/source/sdbcx/VCollection.cxx4
5 files changed, 7 insertions, 7 deletions
diff --git a/connectivity/source/commontools/parameters.cxx b/connectivity/source/commontools/parameters.cxx
index dd87288b6076..1a034ee2e57c 100644
--- a/connectivity/source/commontools/parameters.cxx
+++ b/connectivity/source/commontools/parameters.cxx
@@ -693,7 +693,7 @@ namespace dbtools
// TODO: shouldn't we subtract all the parameters which were already visited?
if ( nParamsLeft )
{
- ::cppu::OInterfaceIteratorHelper aIter( m_aParameterListeners );
+ ::comphelper::OInterfaceIteratorHelper2 aIter( m_aParameterListeners );
Reference< XPropertySet > xProp = m_xComponent;
OSL_ENSURE(xProp.is(),"Some already released my component!");
DatabaseParameterEvent aEvent( xProp.get(), m_pOuterParameters.get() );
diff --git a/connectivity/source/drivers/hsqldb/HTables.cxx b/connectivity/source/drivers/hsqldb/HTables.cxx
index 0a7c703509be..a519e926315f 100644
--- a/connectivity/source/drivers/hsqldb/HTables.cxx
+++ b/connectivity/source/drivers/hsqldb/HTables.cxx
@@ -175,7 +175,7 @@ void OTables::appendNew(const OUString& _rsNewTable)
// notify our container listeners
ContainerEvent aEvent(static_cast<XContainer*>(this), makeAny(_rsNewTable), Any(), Any());
- OInterfaceIteratorHelper aListenerLoop(m_aContainerListeners);
+ OInterfaceIteratorHelper2 aListenerLoop(m_aContainerListeners);
while (aListenerLoop.hasMoreElements())
static_cast<XContainerListener*>(aListenerLoop.next())->elementInserted(aEvent);
}
diff --git a/connectivity/source/drivers/mysql/YTables.cxx b/connectivity/source/drivers/mysql/YTables.cxx
index b8c3237e1211..5c1e2da0e958 100644
--- a/connectivity/source/drivers/mysql/YTables.cxx
+++ b/connectivity/source/drivers/mysql/YTables.cxx
@@ -196,7 +196,7 @@ void OTables::appendNew(const OUString& _rsNewTable)
// notify our container listeners
ContainerEvent aEvent(static_cast<XContainer*>(this), makeAny(_rsNewTable), Any(), Any());
- OInterfaceIteratorHelper aListenerLoop(m_aContainerListeners);
+ OInterfaceIteratorHelper2 aListenerLoop(m_aContainerListeners);
while (aListenerLoop.hasMoreElements())
static_cast<XContainerListener*>(aListenerLoop.next())->elementInserted(aEvent);
}
diff --git a/connectivity/source/inc/hsqldb/HConnection.hxx b/connectivity/source/inc/hsqldb/HConnection.hxx
index 1db8caf6fc0f..309c033d9dff 100644
--- a/connectivity/source/inc/hsqldb/HConnection.hxx
+++ b/connectivity/source/inc/hsqldb/HConnection.hxx
@@ -27,7 +27,7 @@
#include <com/sun/star/ui/dialogs/XExecutableDialog.hpp>
#include <cppuhelper/compbase.hxx>
#include <comphelper/uno3.hxx>
-#include <cppuhelper/interfacecontainer.hxx>
+#include <comphelper/interfacecontainer2.hxx>
namespace connectivity
{
@@ -57,7 +57,7 @@ namespace connectivity
,public IMethodGuardAccess
{
private:
- ::cppu::OInterfaceContainerHelper m_aFlushListeners;
+ ::comphelper::OInterfaceContainerHelper2 m_aFlushListeners;
::com::sun::star::uno::Reference< ::com::sun::star::sdbc::XDriver > m_xDriver;
::com::sun::star::uno::Reference< ::com::sun::star::uno::XComponentContext > m_xContext;
bool m_bIni;
diff --git a/connectivity/source/sdbcx/VCollection.cxx b/connectivity/source/sdbcx/VCollection.cxx
index f2be688a0963..5b4e96553b19 100644
--- a/connectivity/source/sdbcx/VCollection.cxx
+++ b/connectivity/source/sdbcx/VCollection.cxx
@@ -422,7 +422,7 @@ void OCollection::notifyElementRemoved(const OUString& _sName)
{
ContainerEvent aEvent(static_cast<XContainer*>(this), makeAny(_sName), Any(), Any());
// note that xExistent may be empty, in case somebody removed the data source while it is not alive at this moment
- OInterfaceIteratorHelper aListenerLoop(m_aContainerListeners);
+ OInterfaceIteratorHelper2 aListenerLoop(m_aContainerListeners);
while (aListenerLoop.hasMoreElements())
static_cast<XContainerListener*>(aListenerLoop.next())->elementRemoved(aEvent);
}
@@ -518,7 +518,7 @@ void OCollection::renameObject(const OUString& _sOldName, const OUString& _sNewN
{
ContainerEvent aEvent(static_cast<XContainer*>(this), makeAny(_sNewName), makeAny(m_pElements->getObject(_sNewName)),makeAny(_sOldName));
// note that xExistent may be empty, in case somebody removed the data source while it is not alive at this moment
- OInterfaceIteratorHelper aListenerLoop(m_aContainerListeners);
+ OInterfaceIteratorHelper2 aListenerLoop(m_aContainerListeners);
while (aListenerLoop.hasMoreElements())
static_cast<XContainerListener*>(aListenerLoop.next())->elementReplaced(aEvent);
}