summaryrefslogtreecommitdiff
path: root/ucb
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-12-06 11:57:54 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-12-06 12:03:59 +0100
commit0fa31bed9a7a0666df26a1016d74df3ec15b40f9 (patch)
tree679aea468eef96285855e2a4b7316ee2f0de37d6 /ucb
parent4ae9b3ab10c882bd9c25b1f1303325a0ecd7fc06 (diff)
Default OMultiTypeInferfaceContainerHelperVar equalImpl parameter
...and assorted OUStringHash clean up Change-Id: I779904e1275e8df88f567beb388d1d11af9e9671
Diffstat (limited to 'ucb')
-rw-r--r--ucb/source/cacher/contentresultsetwrapper.hxx18
-rw-r--r--ucb/source/core/ucbstore.cxx24
-rw-r--r--ucb/source/ucp/file/bc.cxx2
-rw-r--r--ucb/source/ucp/file/filglob.hxx18
-rw-r--r--ucb/source/ucp/file/filnot.hxx3
-rw-r--r--ucb/source/ucp/file/shell.hxx6
6 files changed, 6 insertions, 65 deletions
diff --git a/ucb/source/cacher/contentresultsetwrapper.hxx b/ucb/source/cacher/contentresultsetwrapper.hxx
index 7d1b3bf65740..9874049d55e0 100644
--- a/ucb/source/cacher/contentresultsetwrapper.hxx
+++ b/ucb/source/cacher/contentresultsetwrapper.hxx
@@ -52,24 +52,8 @@ protected:
//--------------------------------------------------------------------------
//class PropertyChangeListenerContainer_Impl.
- struct equalStr_Impl
- {
- bool operator()( const OUString& s1, const OUString& s2 ) const
- {
- return !!( s1 == s2 );
- }
- };
-
- struct hashStr_Impl
- {
- size_t operator()( const OUString& rName ) const
- {
- return rName.hashCode();
- }
- };
-
typedef cppu::OMultiTypeInterfaceContainerHelperVar
- < OUString , hashStr_Impl , equalStr_Impl >
+ < OUString, OUStringHash >
PropertyChangeListenerContainer_Impl;
//--------------------------------------------------------------------------
// class ReacquireableGuard
diff --git a/ucb/source/core/ucbstore.cxx b/ucb/source/core/ucbstore.cxx
index 73b28354a93d..04a961fb4e6c 100644
--- a/ucb/source/core/ucbstore.cxx
+++ b/ucb/source/core/ucbstore.cxx
@@ -101,24 +101,6 @@ OUString makeHierarchalNameSegment( const OUString & rIn )
#define CFGPROPERTY_LAZYWRITE "lazywrite"
//=========================================================================
-
-struct equalString_Impl
-{
- bool operator()( const OUString& s1, const OUString& s2 ) const
- {
- return !!( s1 == s2 );
- }
-};
-
-struct hashString_Impl
-{
- size_t operator()( const OUString & rName ) const
- {
- return rName.hashCode();
- }
-};
-
-//=========================================================================
//
// PropertySetMap_Impl.
//
@@ -128,8 +110,7 @@ typedef boost::unordered_map
<
OUString,
PersistentPropertySet*,
- hashString_Impl,
- equalString_Impl
+ OUStringHash
>
PropertySetMap_Impl;
@@ -1207,8 +1188,7 @@ Reference< XInterface > PropertySetRegistry::getConfigWriteAccess(
typedef OMultiTypeInterfaceContainerHelperVar
<
OUString,
- hashString_Impl,
- equalString_Impl
+ OUStringHash
> PropertyListeners_Impl;
//=========================================================================
diff --git a/ucb/source/ucp/file/bc.cxx b/ucb/source/ucp/file/bc.cxx
index 73f734dff0f2..4658864ea9cd 100644
--- a/ucb/source/ucp/file/bc.cxx
+++ b/ucb/source/ucp/file/bc.cxx
@@ -51,7 +51,7 @@ using namespace com::sun::star::ucb;
// PropertyListeners
-typedef cppu::OMultiTypeInterfaceContainerHelperVar< OUString,hashOUString,equalOUString >
+typedef cppu::OMultiTypeInterfaceContainerHelperVar< OUString,OUStringHash >
PropertyListeners_impl;
class fileaccess::PropertyListeners
diff --git a/ucb/source/ucp/file/filglob.hxx b/ucb/source/ucp/file/filglob.hxx
index fbb6d8b266e3..ebf569adad40 100644
--- a/ucb/source/ucp/file/filglob.hxx
+++ b/ucb/source/ucp/file/filglob.hxx
@@ -28,24 +28,6 @@ namespace fileaccess {
class BaseContent;
- struct equalOUString
- {
- bool operator()( const OUString& rKey1, const OUString& rKey2 ) const
- {
- return !!( rKey1 == rKey2 );
- }
- };
-
-
- struct hashOUString
- {
- size_t operator()( const OUString& rName ) const
- {
- return rName.hashCode();
- }
- };
-
-
/******************************************************************************/
/* */
/* Helper functions */
diff --git a/ucb/source/ucp/file/filnot.hxx b/ucb/source/ucp/file/filnot.hxx
index 8bb76d1536a9..152773892d43 100644
--- a/ucb/source/ucp/file/filnot.hxx
+++ b/ucb/source/ucp/file/filnot.hxx
@@ -83,8 +83,7 @@ namespace fileaccess {
typedef boost::unordered_map< OUString,
com::sun::star::uno::Sequence< com::sun::star::uno::Reference< com::sun::star::uno::XInterface > >,
- hashOUString,
- equalOUString > ListenerMap;
+ OUStringHash > ListenerMap;
class PropertyChangeNotifier
{
diff --git a/ucb/source/ucp/file/shell.hxx b/ucb/source/ucp/file/shell.hxx
index 12a7b7edd773..7228fbba2d01 100644
--- a/ucb/source/ucp/file/shell.hxx
+++ b/ucb/source/ucp/file/shell.hxx
@@ -76,10 +76,6 @@ namespace fileaccess {
public:
// Type definitions
- typedef OUString UniquePath;
- typedef equalOUString eUniquePath;
- typedef hashOUString hUniquePath;
-
class MyProperty
{
private:
@@ -155,7 +151,7 @@ namespace fileaccess {
com::sun::star::uno::Reference< com::sun::star::beans::XPropertyAccess > xA;
};
- typedef boost::unordered_map< UniquePath,UnqPathData,hUniquePath,eUniquePath > ContentMap;
+ typedef boost::unordered_map< OUString,UnqPathData,OUStringHash > ContentMap;
public: