[Libreoffice-commits] core.git: connectivity/source dbaccess/source include/connectivity

Stephan Bergmann sbergman at redhat.com
Mon Mar 5 18:50:07 UTC 2018


 connectivity/source/commontools/dbcharset.cxx    |    2 +-
 connectivity/source/drivers/file/FConnection.cxx |    2 +-
 connectivity/source/drivers/mysql/YDriver.cxx    |    2 +-
 connectivity/source/drivers/odbc/OConnection.cxx |    2 +-
 dbaccess/source/ui/misc/charsets.cxx             |    2 +-
 include/connectivity/dbcharset.hxx               |    4 +---
 6 files changed, 6 insertions(+), 8 deletions(-)

New commits:
commit ebb41767f3669cd2ad3f8208f012f70654bbceb7
Author: Stephan Bergmann <sbergman at redhat.com>
Date:   Mon Mar 5 17:42:40 2018 +0100

    Rename OCharsetMap::find overload to findIanaName
    
    Change-Id: Id3fe81b41b92d6ad4e3f7127331d859a7b3c7f54
    Reviewed-on: https://gerrit.libreoffice.org/50779
    Reviewed-by: Stephan Bergmann <sbergman at redhat.com>
    Tested-by: Stephan Bergmann <sbergman at redhat.com>

diff --git a/connectivity/source/commontools/dbcharset.cxx b/connectivity/source/commontools/dbcharset.cxx
index 48a7c6817c89..9fc7923dbc70 100644
--- a/connectivity/source/commontools/dbcharset.cxx
+++ b/connectivity/source/commontools/dbcharset.cxx
@@ -92,7 +92,7 @@ namespace dbtools
     }
 
 
-    OCharsetMap::CharsetIterator    OCharsetMap::find(const OUString& _rIanaName, const IANA&) const
+    OCharsetMap::CharsetIterator    OCharsetMap::findIanaName(const OUString& _rIanaName) const
     {
         ensureConstructed( );
 
diff --git a/connectivity/source/drivers/file/FConnection.cxx b/connectivity/source/drivers/file/FConnection.cxx
index a0b5884e1ca2..a109c6fa6645 100644
--- a/connectivity/source/drivers/file/FConnection.cxx
+++ b/connectivity/source/drivers/file/FConnection.cxx
@@ -109,7 +109,7 @@ void OConnection::construct(const OUString& url,const Sequence< PropertyValue >&
                 OSL_VERIFY( pIter->Value >>= sIanaName );
 
                 ::dbtools::OCharsetMap aLookupIanaName;
-                ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.find(sIanaName, ::dbtools::OCharsetMap::IANA());
+                ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.findIanaName(sIanaName);
                 if (aLookup != aLookupIanaName.end())
                     m_nTextEncoding = (*aLookup).getEncoding();
                 else
diff --git a/connectivity/source/drivers/mysql/YDriver.cxx b/connectivity/source/drivers/mysql/YDriver.cxx
index 25f436d5ac32..95094265e508 100644
--- a/connectivity/source/drivers/mysql/YDriver.cxx
+++ b/connectivity/source/drivers/mysql/YDriver.cxx
@@ -265,7 +265,7 @@ namespace connectivity
                     if ( !sIanaName.isEmpty() )
                     {
                         ::dbtools::OCharsetMap aLookupIanaName;
-                        ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.find(sIanaName, ::dbtools::OCharsetMap::IANA());
+                        ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.findIanaName(sIanaName);
                         if (aLookup != aLookupIanaName.end() )
                         {
                             OUString sAdd;
diff --git a/connectivity/source/drivers/odbc/OConnection.cxx b/connectivity/source/drivers/odbc/OConnection.cxx
index d2fbcb436693..cc474837bb52 100644
--- a/connectivity/source/drivers/odbc/OConnection.cxx
+++ b/connectivity/source/drivers/odbc/OConnection.cxx
@@ -231,7 +231,7 @@ SQLRETURN OConnection::Construct(const OUString& url,const Sequence< PropertyVal
             OSL_VERIFY( pBegin->Value >>= sIanaName );
 
             ::dbtools::OCharsetMap aLookupIanaName;
-            ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.find(sIanaName, ::dbtools::OCharsetMap::IANA());
+            ::dbtools::OCharsetMap::const_iterator aLookup = aLookupIanaName.findIanaName(sIanaName);
             if (aLookup != aLookupIanaName.end())
                 m_nTextEncoding = (*aLookup).getEncoding();
             else
diff --git a/dbaccess/source/ui/misc/charsets.cxx b/dbaccess/source/ui/misc/charsets.cxx
index 9cf2789ce1bf..3fe9316042ab 100644
--- a/dbaccess/source/ui/misc/charsets.cxx
+++ b/dbaccess/source/ui/misc/charsets.cxx
@@ -63,7 +63,7 @@ namespace dbaui
 
     OCharsetDisplay::const_iterator OCharsetDisplay::findIanaName(const OUString& _rIanaName) const
     {
-        OCharsetMap::const_iterator aBaseIter = OCharsetMap::find(_rIanaName, OCharsetMap::IANA());
+        OCharsetMap::const_iterator aBaseIter = OCharsetMap::findIanaName(_rIanaName);
         return const_iterator( this, aBaseIter );
     }
 
diff --git a/include/connectivity/dbcharset.hxx b/include/connectivity/dbcharset.hxx
index f2a2ca171014..0830c1d00862 100644
--- a/include/connectivity/dbcharset.hxx
+++ b/include/connectivity/dbcharset.hxx
@@ -67,8 +67,6 @@ namespace dbtools
         OCharsetMap();
         virtual ~OCharsetMap();
 
-        struct IANA { };
-
         /** find the given text encoding in the map.
             @return the <em>end</em> iterator if the encoding could not be found.
         */
@@ -76,7 +74,7 @@ namespace dbtools
         /** find the given IANA name in the map.
             @return the <em>end</em> iterator if the IANA name could not be found.
         */
-        CharsetIterator find(const OUString& _rIanaName, const IANA&) const;
+        CharsetIterator findIanaName(const OUString& _rIanaName) const;
 
         /// get access to the first element of the charset collection
         CharsetIterator begin() const;


More information about the Libreoffice-commits mailing list