summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2013-12-06 14:27:53 +0100
committerStephan Bergmann <sbergman@redhat.com>2013-12-06 14:28:37 +0100
commitf51877b147c456ecd8533b6958bfa798842e5c6b (patch)
tree6f932ee6d8cc3fdaa4f778e73075c39ebaeb18cc /include
parent02f9f422c79be3896d407f06e9cf8043d7e148f9 (diff)
Combine comphelper::UStringMixEqual, comphelper::TStringMixEqualFunctor
Change-Id: I3ab3777a65fd68f8cbaf17a8e2a989dc4ad7b1cc
Diffstat (limited to 'include')
-rw-r--r--include/comphelper/stl_types.hxx19
1 files changed, 2 insertions, 17 deletions
diff --git a/include/comphelper/stl_types.hxx b/include/comphelper/stl_types.hxx
index 10bcc2cb653e..52a558760a7b 100644
--- a/include/comphelper/stl_types.hxx
+++ b/include/comphelper/stl_types.hxx
@@ -58,30 +58,15 @@ public:
};
//------------------------------------------------------------------------
-class UStringMixEqual
+class UStringMixEqual: public std::binary_function<OUString, OUString, bool>
{
sal_Bool m_bCaseSensitive;
public:
UStringMixEqual(sal_Bool bCaseSensitive = sal_True):m_bCaseSensitive(bCaseSensitive){}
- sal_Bool operator() (const OUString& lhs, const OUString& rhs) const
- {
- return m_bCaseSensitive ? lhs.equals( rhs ) : lhs.equalsIgnoreAsciiCase( rhs );
- }
- sal_Bool isCaseSensitive() const {return m_bCaseSensitive;}
-};
-//------------------------------------------------------------------------
-class TStringMixEqualFunctor : public ::std::binary_function< OUString,OUString,bool>
-{
- sal_Bool m_bCaseSensitive;
-
-public:
- TStringMixEqualFunctor(sal_Bool bCaseSensitive = sal_True)
- :m_bCaseSensitive(bCaseSensitive)
- {}
bool operator() (const OUString& lhs, const OUString& rhs) const
{
- return !!(m_bCaseSensitive ? lhs.equals( rhs ) : lhs.equalsIgnoreAsciiCase( rhs ));
+ return m_bCaseSensitive ? lhs.equals( rhs ) : lhs.equalsIgnoreAsciiCase( rhs );
}
sal_Bool isCaseSensitive() const {return m_bCaseSensitive;}
};