diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-10-07 15:08:24 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-10-08 08:29:04 +0200 |
commit | c5e9bc71c4803ccf7c1eaa23aed03bdaee31f001 (patch) | |
tree | 9273e2d7878bbd295e97fa37ced16964d7086066 /ucb | |
parent | 6a1485d4109ae5d0666d769406811d1918c90388 (diff) |
use cppu::WeakImplHelper in CachedDynamicResultSetFactory
Change-Id: Ia13306a3059678ef306835b8641a26200f9ae420
Reviewed-on: https://gerrit.libreoffice.org/80414
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'ucb')
-rw-r--r-- | ucb/source/cacher/cacheddynamicresultset.cxx | 32 | ||||
-rw-r--r-- | ucb/source/cacher/cacheddynamicresultset.hxx | 23 |
2 files changed, 5 insertions, 50 deletions
diff --git a/ucb/source/cacher/cacheddynamicresultset.cxx b/ucb/source/cacher/cacheddynamicresultset.cxx index 22f9bb46e8b3..074bf0cc431f 100644 --- a/ucb/source/cacher/cacheddynamicresultset.cxx +++ b/ucb/source/cacher/cacheddynamicresultset.cxx @@ -161,38 +161,6 @@ CachedDynamicResultSetFactory::~CachedDynamicResultSetFactory() } -// CachedDynamicResultSetFactory XInterface methods. -void SAL_CALL CachedDynamicResultSetFactory::acquire() - throw() -{ - OWeakObject::acquire(); -} - -void SAL_CALL CachedDynamicResultSetFactory::release() - throw() -{ - OWeakObject::release(); -} - -css::uno::Any SAL_CALL CachedDynamicResultSetFactory::queryInterface( const css::uno::Type & rType ) -{ - css::uno::Any aRet = cppu::queryInterface( rType, - static_cast< XTypeProvider* >(this), - static_cast< XServiceInfo* >(this), - static_cast< XCachedDynamicResultSetFactory* >(this) - ); - return aRet.hasValue() ? aRet : OWeakObject::queryInterface( rType ); -} - -// CachedDynamicResultSetFactory XTypeProvider methods. - - -XTYPEPROVIDER_IMPL_3( CachedDynamicResultSetFactory, - XTypeProvider, - XServiceInfo, - XCachedDynamicResultSetFactory ); - - // CachedDynamicResultSetFactory XServiceInfo methods. XSERVICEINFO_COMMOM_IMPL( CachedDynamicResultSetFactory, diff --git a/ucb/source/cacher/cacheddynamicresultset.hxx b/ucb/source/cacher/cacheddynamicresultset.hxx index a6816ba06cc9..e5cb903564af 100644 --- a/ucb/source/cacher/cacheddynamicresultset.hxx +++ b/ucb/source/cacher/cacheddynamicresultset.hxx @@ -27,6 +27,7 @@ #include <com/sun/star/lang/XTypeProvider.hpp> #include <com/sun/star/ucb/XContentIdentifierMapping.hpp> #include <com/sun/star/ucb/XCachedDynamicResultSetFactory.hpp> +#include <cppuhelper/implbase.hxx> #define CACHED_DRS_SERVICE_NAME "com.sun.star.ucb.CachedDynamicResultSet" #define CACHED_DRS_FACTORY_NAME "com.sun.star.ucb.CachedDynamicResultSetFactory" @@ -78,11 +79,10 @@ public: }; -class CachedDynamicResultSetFactory final - : public cppu::OWeakObject - , public css::lang::XTypeProvider - , public css::lang::XServiceInfo - , public css::ucb::XCachedDynamicResultSetFactory +class CachedDynamicResultSetFactory final : + public cppu::WeakImplHelper< + css::lang::XServiceInfo, + css::ucb::XCachedDynamicResultSetFactory> { css::uno::Reference< css::uno::XComponentContext > m_xContext; @@ -93,19 +93,6 @@ public: virtual ~CachedDynamicResultSetFactory() override; - - // XInterface - virtual css::uno::Any SAL_CALL queryInterface( const css::uno::Type & rType ) override; - virtual void SAL_CALL acquire() - throw() override; - virtual void SAL_CALL release() - throw() override; - - // XTypeProvider - virtual css::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() override; - virtual css::uno::Sequence< css::uno::Type > SAL_CALL getTypes() override; - - // XServiceInfo virtual OUString SAL_CALL getImplementationName() override; virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) override; |