[Libreoffice-commits] core.git: comphelper/source

Stephan Bergmann sbergman at redhat.com
Mon Apr 7 04:49:33 PDT 2014


 comphelper/source/compare/AnyCompareFactory.cxx                   |    1 
 comphelper/source/container/IndexedPropertyValuesContainer.cxx    |    1 
 comphelper/source/container/NamedPropertyValuesContainer.cxx      |    1 
 comphelper/source/container/enumerablemap.cxx                     |   12 +--
 comphelper/source/eventattachermgr/eventattachermgr.cxx           |    6 -
 comphelper/source/inc/comphelper_services.hxx                     |   40 ++++++++++
 comphelper/source/misc/comphelper_services.cxx                    |   16 ----
 comphelper/source/misc/docpasswordrequest.cxx                     |   11 --
 comphelper/source/misc/documentiologring.cxx                      |    1 
 comphelper/source/misc/instancelocker.cxx                         |    1 
 comphelper/source/misc/logging.cxx                                |    1 
 comphelper/source/misc/officerestartmanager.cxx                   |    1 
 comphelper/source/officeinstdir/officeinstallationdirectories.cxx |    1 
 comphelper/source/property/opropertybag.cxx                       |    1 
 comphelper/source/streaming/memorystream.cxx                      |    1 
 comphelper/source/streaming/seqinputstreamserv.cxx                |   11 +-
 comphelper/source/streaming/seqoutputstreamserv.cxx               |   10 +-
 comphelper/source/xml/attributelist.cxx                           |    1 
 18 files changed, 66 insertions(+), 51 deletions(-)

New commits:
commit b8757ee8c7a024c36dda276bbe7dc69d5445e9c4
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Apr 7 13:48:53 2014 +0200

    Clean up function declarations and some unused functions
    
    Change-Id: I5817a5ad3966918cfb1920be568b7401dd6f948c

diff --git a/comphelper/source/compare/AnyCompareFactory.cxx b/comphelper/source/compare/AnyCompareFactory.cxx
index c500265..1f218a5 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 0de5913..1df9a1e 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 fd95d7e..c94efa6 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 e4273c5..4c22557 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 e9492bf..f28d6d3 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 0000000..77d4dd9
--- /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 af4e88e..e86055c 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 b57a405..4639273 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 91551e9..b08beac 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 d85f501..9fe7b5c 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 1ffea6b..e59c407 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 6d0e7f8..462b59c 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 24c3d34..0d6c6c7 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 03623eb..3ce5b48 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 6d7b117..c4379cd 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 51e6703..ffc5136 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 e40eeca..f1ef3c6 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 29d8d96..de5e58b 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 )
     {


More information about the Libreoffice-commits mailing list