summaryrefslogtreecommitdiff
path: root/filter/source/config/cache/filtercache.hxx
diff options
context:
space:
mode:
Diffstat (limited to 'filter/source/config/cache/filtercache.hxx')
-rw-r--r--filter/source/config/cache/filtercache.hxx29
1 files changed, 13 insertions, 16 deletions
diff --git a/filter/source/config/cache/filtercache.hxx b/filter/source/config/cache/filtercache.hxx
index 243c192a8072..8445efea8227 100644
--- a/filter/source/config/cache/filtercache.hxx
+++ b/filter/source/config/cache/filtercache.hxx
@@ -17,12 +17,12 @@
* the License at http://www.apache.org/licenses/LICENSE-2.0 .
*/
-#ifndef INCLUDED_FILTER_SOURCE_CONFIG_CACHE_FILTERCACHE_HXX
-#define INCLUDED_FILTER_SOURCE_CONFIG_CACHE_FILTERCACHE_HXX
+#pragma once
#include <memory>
#include "cacheitem.hxx"
+#include <com/sun/star/beans/NamedValue.hpp>
#include <com/sun/star/util/URL.hpp>
#include <com/sun/star/uno/XInterface.hpp>
#include <com/sun/star/container/XNameAccess.hpp>
@@ -30,7 +30,7 @@
#include <com/sun/star/uno/Reference.h>
#include <com/sun/star/uno/Any.h>
#include <comphelper/documentconstants.hxx>
-#include <rtl/instance.hxx>
+#include <cppuhelper/basemutex.hxx>
#include <rtl/ref.hxx>
#include <rtl/ustring.hxx>
@@ -56,7 +56,7 @@ class CacheUpdateListener;
Further we make it public. So any user of this class
can lock us from outside too.
*/
-class FilterCache : public BaseLock
+class FilterCache : public cppu::BaseMutex
{
// public types
@@ -362,9 +362,9 @@ class FilterCache : public BaseLock
if some input parameter are wrong or the cache itself is not valid
any longer, because any operation before damage it.
*/
- std::vector<OUString> getMatchingItemsByProps( EItemType eType ,
- const CacheItem& lIProps ,
- const CacheItem& lEProps = CacheItem()) const;
+ std::vector<OUString> getMatchingItemsByProps( EItemType eType,
+ std::span< const css::beans::NamedValue > lIProps,
+ std::span< const css::beans::NamedValue > lEProps = {}) const;
/** @short indicates if the requested sub container
@@ -525,10 +525,8 @@ class FilterCache : public BaseLock
was not migrated to the new one. So we can't provide write access
to such items...
*/
- void addStatePropsToItem( EItemType eType,
- const OUString& sItem,
- CacheItem& rItem);
-
+ css::uno::Any getItemWithStateProps( EItemType eType,
+ const OUString& sItem);
/** TODO document me
@@ -601,6 +599,7 @@ class FilterCache : public BaseLock
CacheItemList& impl_getItemList(EItemType eType);
+ CacheItem& impl_getItem( EItemType eType, const OUString& sItem);
/** @short return a valid configuration update access
to the underlying configuration package, which
@@ -666,7 +665,7 @@ class FilterCache : public BaseLock
Can be empty if an internal error occurred or if the requested
key does not exists!
*/
- css::uno::Any impl_getDirectCFGValue(const OUString& sDirectKey);
+ css::uno::Any impl_getDirectCFGValue(std::u16string_view sDirectKey);
/** @short load the underlying configuration into this cache.
@@ -892,7 +891,7 @@ class FilterCache : public BaseLock
/** TODO */
- static std::vector<OUString> impl_tokenizeString(const OUString& sData ,
+ static std::vector<OUString> impl_tokenizeString(std::u16string_view sData ,
sal_Unicode cSeparator);
@@ -934,10 +933,8 @@ class FilterCache : public BaseLock
static css::uno::Sequence< OUString > impl_convertFlagField2FlagNames(SfxFilterFlags nFlags);
};
-struct TheFilterCache: public rtl::Static<FilterCache, TheFilterCache> {};
+FilterCache& GetTheFilterCache();
} // namespace filter::config
-#endif // INCLUDED_FILTER_SOURCE_CONFIG_CACHE_FILTERCACHE_HXX
-
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */