diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2021-09-22 21:15:20 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2021-09-22 23:23:35 +0200 |
commit | 3b6dd54994ab1e624729cb007a8e3dc2b5f3b891 (patch) | |
tree | 487e284cc866fc16a7033e3dce569425aea13f50 /sc/source/ui/dataprovider/dataprovider.cxx | |
parent | fcdfdc21b197bb9af1a75348ce912c5d1d47dfba (diff) |
Extend loplugin:stringviewparam to starts/endsWith: sc
Change-Id: Ibda7acf66bd8382de25fae9b4385d655be6ab409
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/122490
Tested-by: Jenkins
Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'sc/source/ui/dataprovider/dataprovider.cxx')
-rw-r--r-- | sc/source/ui/dataprovider/dataprovider.cxx | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/sc/source/ui/dataprovider/dataprovider.cxx b/sc/source/ui/dataprovider/dataprovider.cxx index ff0ee8626fef..72f674a7b99d 100644 --- a/sc/source/ui/dataprovider/dataprovider.cxx +++ b/sc/source/ui/dataprovider/dataprovider.cxx @@ -11,6 +11,7 @@ #include <com/sun/star/ucb/XSimpleFileAccess3.hpp> #include <com/sun/star/ucb/SimpleFileAccess.hpp> #include <com/sun/star/io/XInputStream.hpp> +#include <o3tl/string_view.hxx> #include <rtl/strbuf.hxx> #include <sal/log.hxx> #include <unotools/charclass.hxx> @@ -266,9 +267,9 @@ ScDBData* ScDBDataManager::getDBData() return pDBData; } -bool DataProviderFactory::isInternalDataProvider(const OUString& rProvider) +bool DataProviderFactory::isInternalDataProvider(std::u16string_view rProvider) { - return rProvider.startsWith("org.libreoffice.calc"); + return o3tl::starts_with(rProvider, u"org.libreoffice.calc"); } std::shared_ptr<DataProvider> DataProviderFactory::getDataProvider(ScDocument* pDoc, |