diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2014-04-07 13:48:53 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2014-04-07 13:48:53 +0200 |
commit | b8757ee8c7a024c36dda276bbe7dc69d5445e9c4 (patch) | |
tree | 7d22b6a80a53f31e7d4d8cd422495d0137af5167 /comphelper | |
parent | 732c19b8f39c9bf3c5a23affa27895e3dd3dccbf (diff) |
Clean up function declarations and some unused functions
Change-Id: I5817a5ad3966918cfb1920be568b7401dd6f948c
Diffstat (limited to 'comphelper')
18 files changed, 66 insertions, 51 deletions
diff --git a/comphelper/source/compare/AnyCompareFactory.cxx b/comphelper/source/compare/AnyCompareFactory.cxx index c5002651a102..1f218a5f303c 100644 --- a/comphelper/source/compare/AnyCompareFactory.cxx +++ b/comphelper/source/compare/AnyCompareFactory.cxx @@ -18,6 +18,7 @@ */ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <com/sun/star/ucb/XAnyCompareFactory.hpp> #include <com/sun/star/i18n/Collator.hpp> diff --git a/comphelper/source/container/IndexedPropertyValuesContainer.cxx b/comphelper/source/container/IndexedPropertyValuesContainer.cxx index 0de5913a42c2..1df9a1e9e778 100644 --- a/comphelper/source/container/IndexedPropertyValuesContainer.cxx +++ b/comphelper/source/container/IndexedPropertyValuesContainer.cxx @@ -18,6 +18,7 @@ */ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <com/sun/star/container/XIndexContainer.hpp> #include <com/sun/star/uno/Sequence.h> diff --git a/comphelper/source/container/NamedPropertyValuesContainer.cxx b/comphelper/source/container/NamedPropertyValuesContainer.cxx index fd95d7ec7fae..c94efa68a002 100644 --- a/comphelper/source/container/NamedPropertyValuesContainer.cxx +++ b/comphelper/source/container/NamedPropertyValuesContainer.cxx @@ -19,6 +19,7 @@ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <com/sun/star/container/XNameContainer.hpp> #include <com/sun/star/uno/Sequence.h> diff --git a/comphelper/source/container/enumerablemap.cxx b/comphelper/source/container/enumerablemap.cxx index e4273c508f67..4c225574e73b 100644 --- a/comphelper/source/container/enumerablemap.cxx +++ b/comphelper/source/container/enumerablemap.cxx @@ -19,6 +19,7 @@ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include "comphelper/anytostring.hxx" #include "comphelper/anycompare.hxx" #include "comphelper/componentbase.hxx" @@ -38,6 +39,7 @@ #include <typelib/typedescription.hxx> #include <map> +#include <boost/noncopyable.hpp> #include <boost/shared_ptr.hpp> @@ -111,7 +113,7 @@ namespace comphelper { } private: - MapData& operator=( const MapData& _source ); // not implemented + MapData& operator=( const MapData& _source ) SAL_DELETED_FUNCTION; }; @@ -252,7 +254,8 @@ namespace comphelper //= MapEnumerator - class MapEnumerator : public IMapModificationListener + class MapEnumerator: + public IMapModificationListener, private boost::noncopyable { public: MapEnumerator( ::cppu::OWeakObject& _rParent, MapData& _mapData, const EnumerationType _type ) @@ -292,11 +295,6 @@ namespace comphelper const EnumerationType m_eType; KeyedValues::const_iterator m_mapPos; bool m_disposed; - - private: - MapEnumerator(); // not implemented - MapEnumerator( const MapEnumerator& ); // not implemented - MapEnumerator& operator=( const MapEnumerator& ); // not implemented }; diff --git a/comphelper/source/eventattachermgr/eventattachermgr.cxx b/comphelper/source/eventattachermgr/eventattachermgr.cxx index e9492bfb0fac..f28d6d383a28 100644 --- a/comphelper/source/eventattachermgr/eventattachermgr.cxx +++ b/comphelper/source/eventattachermgr/eventattachermgr.cxx @@ -65,18 +65,12 @@ struct AttachedObject_Impl Reference< XInterface > xTarget; Sequence< Reference< XEventListener > > aAttachedListenerSeq; Any aHelper; - - bool operator<( const AttachedObject_Impl & ) const; - bool operator==( const AttachedObject_Impl & ) const; }; struct AttacherIndex_Impl { ::std::deque< ScriptEventDescriptor > aEventList; ::std::deque< AttachedObject_Impl > aObjList; - - bool operator<( const AttacherIndex_Impl & ) const; - bool operator==( const AttacherIndex_Impl & ) const; }; diff --git a/comphelper/source/inc/comphelper_services.hxx b/comphelper/source/inc/comphelper_services.hxx new file mode 100644 index 000000000000..77d4dd905492 --- /dev/null +++ b/comphelper/source/inc/comphelper_services.hxx @@ -0,0 +1,40 @@ +/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ +/* + * This file is part of the LibreOffice project. + * + * This Source Code Form is subject to the terms of the Mozilla Public + * License, v. 2.0. If a copy of the MPL was not distributed with this + * file, You can obtain one at http://mozilla.org/MPL/2.0/. + * + * This file incorporates work covered by the following license notice: + * + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed + * with this work for additional information regarding copyright + * ownership. The ASF licenses this file to you under the Apache + * License, Version 2.0 (the "License"); you may not use this file + * except in compliance with the License. You may obtain a copy of + * the License at http://www.apache.org/licenses/LICENSE-2.0 . + */ + +#ifndef INCLUDED_COMPHELPER_SOURCE_INC_COMPHELPER_SERVICES_HXX +#define INCLUDED_COMPHELPER_SOURCE_INC_COMPHELPER_SERVICES_HXX + +#include <sal/config.h> + +void createRegistryInfo_AnyCompareFactory(); +void createRegistryInfo_IndexedPropertyValuesContainer(); +void createRegistryInfo_Map(); +void createRegistryInfo_NamedPropertyValuesContainer(); +void createRegistryInfo_OInstanceLocker(); +void createRegistryInfo_OOfficeRestartManager(); +void createRegistryInfo_OPropertyBag(); +void createRegistryInfo_OSimpleLogRing(); +void createRegistryInfo_OfficeInstallationDirectories(); +void createRegistryInfo_SequenceInputStream(); +void createRegistryInfo_SequenceOutputStream(); +void createRegistryInfo_UNOMemoryStream(); + +#endif + +/* vim:set shiftwidth=4 softtabstop=4 expandtab: */ diff --git a/comphelper/source/misc/comphelper_services.cxx b/comphelper/source/misc/comphelper_services.cxx index af4e88e0874c..e86055cc836a 100644 --- a/comphelper/source/misc/comphelper_services.cxx +++ b/comphelper/source/misc/comphelper_services.cxx @@ -19,24 +19,10 @@ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <rtl/instance.hxx> - -extern void createRegistryInfo_OPropertyBag(); -extern void createRegistryInfo_SequenceOutputStream(); -extern void createRegistryInfo_SequenceInputStream(); -extern void createRegistryInfo_UNOMemoryStream(); -extern void createRegistryInfo_IndexedPropertyValuesContainer(); -extern void createRegistryInfo_NamedPropertyValuesContainer(); -extern void createRegistryInfo_AnyCompareFactory(); -extern void createRegistryInfo_OfficeInstallationDirectories(); -extern void createRegistryInfo_OInstanceLocker(); -extern void createRegistryInfo_Map(); -extern void createRegistryInfo_OSimpleLogRing(); -extern void createRegistryInfo_OOfficeRestartManager(); - - namespace comphelper { namespace module { diff --git a/comphelper/source/misc/docpasswordrequest.cxx b/comphelper/source/misc/docpasswordrequest.cxx index b57a4059682f..4639273fa5c9 100644 --- a/comphelper/source/misc/docpasswordrequest.cxx +++ b/comphelper/source/misc/docpasswordrequest.cxx @@ -48,15 +48,7 @@ namespace comphelper { class AbortContinuation : public ::cppu::WeakImplHelper1< XInteractionAbort > { public: - inline explicit AbortContinuation() : mbSelected( false ) {} - - inline bool isSelected() const { return mbSelected; } - inline void reset() { mbSelected = false; } - - virtual void SAL_CALL select() throw( RuntimeException, std::exception ) SAL_OVERRIDE { mbSelected = true; } - -private: - bool mbSelected; + virtual void SAL_CALL select() throw( RuntimeException, std::exception ) SAL_OVERRIDE {} }; @@ -67,7 +59,6 @@ public: inline explicit PasswordContinuation() : mbReadOnly( false ), mbSelected( false ) {} inline bool isSelected() const { return mbSelected; } - inline void reset() { mbSelected = false; } virtual void SAL_CALL select() throw( RuntimeException, std::exception ) SAL_OVERRIDE { mbSelected = true; } diff --git a/comphelper/source/misc/documentiologring.cxx b/comphelper/source/misc/documentiologring.cxx index 91551e9ead76..b08beac8ceef 100644 --- a/comphelper/source/misc/documentiologring.cxx +++ b/comphelper/source/misc/documentiologring.cxx @@ -22,6 +22,7 @@ #include <com/sun/star/lang/IllegalArgumentException.hpp> #include <comphelper_module.hxx> +#include <comphelper_services.hxx> #include <cppuhelper/supportsservice.hxx> #include "documentiologring.hxx" diff --git a/comphelper/source/misc/instancelocker.cxx b/comphelper/source/misc/instancelocker.cxx index d85f50150f08..9fe7b5c81cda 100644 --- a/comphelper/source/misc/instancelocker.cxx +++ b/comphelper/source/misc/instancelocker.cxx @@ -19,6 +19,7 @@ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <cppuhelper/supportsservice.hxx> #include <com/sun/star/util/XCloseBroadcaster.hpp> diff --git a/comphelper/source/misc/logging.cxx b/comphelper/source/misc/logging.cxx index 1ffea6be341b..e59c4079f73e 100644 --- a/comphelper/source/misc/logging.cxx +++ b/comphelper/source/misc/logging.cxx @@ -65,7 +65,6 @@ namespace comphelper } inline bool isValid() const { return m_xLogger.is(); } - inline const OUString& getName() const { return m_sLoggerName; } inline const Reference< XLogger >& getLogger() const { return m_xLogger; } inline Reference< XComponentContext > getContext() const { return m_aContext; } diff --git a/comphelper/source/misc/officerestartmanager.cxx b/comphelper/source/misc/officerestartmanager.cxx index 6d0e7f82cc38..462b59cd6f20 100644 --- a/comphelper/source/misc/officerestartmanager.cxx +++ b/comphelper/source/misc/officerestartmanager.cxx @@ -24,6 +24,7 @@ #include <com/sun/star/beans/XPropertySet.hpp> #include <comphelper_module.hxx> +#include <comphelper_services.hxx> #include <cppuhelper/supportsservice.hxx> #include "officerestartmanager.hxx" diff --git a/comphelper/source/officeinstdir/officeinstallationdirectories.cxx b/comphelper/source/officeinstdir/officeinstallationdirectories.cxx index 24c3d34f4370..0d6c6c77172e 100644 --- a/comphelper/source/officeinstdir/officeinstallationdirectories.cxx +++ b/comphelper/source/officeinstdir/officeinstallationdirectories.cxx @@ -20,6 +20,7 @@ #include <config_folders.h> #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <cppuhelper/supportsservice.hxx> /************************************************************************** diff --git a/comphelper/source/property/opropertybag.cxx b/comphelper/source/property/opropertybag.cxx index 03623eb8ab16..3ce5b48f191b 100644 --- a/comphelper/source/property/opropertybag.cxx +++ b/comphelper/source/property/opropertybag.cxx @@ -20,6 +20,7 @@ #include "opropertybag.hxx" #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <com/sun/star/beans/PropertyAttribute.hpp> #include <com/sun/star/beans/NamedValue.hpp> diff --git a/comphelper/source/streaming/memorystream.cxx b/comphelper/source/streaming/memorystream.cxx index 6d7b1179dbd9..c4379cdb46ba 100644 --- a/comphelper/source/streaming/memorystream.cxx +++ b/comphelper/source/streaming/memorystream.cxx @@ -19,6 +19,7 @@ #include "comphelper_module.hxx" +#include "comphelper_services.hxx" #include <com/sun/star/io/XStream.hpp> #include <com/sun/star/io/XSeekableInputStream.hpp> diff --git a/comphelper/source/streaming/seqinputstreamserv.cxx b/comphelper/source/streaming/seqinputstreamserv.cxx index 51e67037fd2d..ffc5136f804d 100644 --- a/comphelper/source/streaming/seqinputstreamserv.cxx +++ b/comphelper/source/streaming/seqinputstreamserv.cxx @@ -17,11 +17,12 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ -// MARKER( update_precomp.py ): autogen include statement, do not remove +#include <sal/config.h> #include "comphelper_module.hxx" +#include "comphelper_services.hxx" -#include <sal/config.h> +#include <boost/noncopyable.hpp> #include <osl/mutex.hxx> #include <cppuhelper/factory.hxx> #include <cppuhelper/implementationentry.hxx> @@ -43,7 +44,8 @@ class SequenceInputStreamService: public ::cppu::WeakImplHelper3< lang::XServiceInfo, io::XSeekableInputStream, - lang::XInitialization> + lang::XInitialization>, + private boost::noncopyable { public: explicit SequenceInputStreamService(); @@ -74,9 +76,6 @@ public: virtual void SAL_CALL initialize( const uno::Sequence< ::com::sun::star::uno::Any > & aArguments ) throw ( uno::RuntimeException, uno::Exception, std::exception ) SAL_OVERRIDE; private: - SequenceInputStreamService( SequenceInputStreamService & ); // not defined - void operator =( SequenceInputStreamService & ); // not defined - virtual ~SequenceInputStreamService() {} diff --git a/comphelper/source/streaming/seqoutputstreamserv.cxx b/comphelper/source/streaming/seqoutputstreamserv.cxx index e40eeca2a4fe..f1ef3c6ebb48 100644 --- a/comphelper/source/streaming/seqoutputstreamserv.cxx +++ b/comphelper/source/streaming/seqoutputstreamserv.cxx @@ -17,10 +17,12 @@ * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ +#include <sal/config.h> #include "comphelper_module.hxx" +#include "comphelper_services.hxx" -#include <sal/config.h> +#include <boost/noncopyable.hpp> #include <osl/mutex.hxx> #include <cppuhelper/factory.hxx> #include <cppuhelper/implementationentry.hxx> @@ -37,7 +39,8 @@ using namespace ::com::sun::star; namespace { class SequenceOutputStreamService: -public ::cppu::WeakImplHelper2 < lang::XServiceInfo, io::XSequenceOutputStream > + public cppu::WeakImplHelper2<lang::XServiceInfo, io::XSequenceOutputStream>, + private boost::noncopyable { public: explicit SequenceOutputStreamService(); @@ -61,9 +64,6 @@ public: virtual uno::Sequence< ::sal_Int8 > SAL_CALL getWrittenBytes( ) throw ( io::NotConnectedException, io::IOException, uno::RuntimeException, std::exception) SAL_OVERRIDE; private: - SequenceOutputStreamService( SequenceOutputStreamService & ); //not defined - void operator =( SequenceOutputStreamService & ); //not defined - virtual ~SequenceOutputStreamService() {}; diff --git a/comphelper/source/xml/attributelist.cxx b/comphelper/source/xml/attributelist.cxx index 29d8d9681c71..de5e58b3fadf 100644 --- a/comphelper/source/xml/attributelist.cxx +++ b/comphelper/source/xml/attributelist.cxx @@ -30,7 +30,6 @@ namespace comphelper { struct TagAttribute_Impl { - TagAttribute_Impl(){} TagAttribute_Impl( const OUString &aName, const OUString &aType, const OUString &aValue ) { |