28#include <com/sun/star/embed/XStorage.hpp>
30#include <com/sun/star/uno/XComponentContext.hpp>
71 css::uno::Reference< css::uno::XComponentContext >
m_xContext;
125 PresetHandler(css::uno::Reference< css::uno::XComponentContext > xContext);
210 std::u16string_view sResourceType ,
211 std::u16string_view sModule ,
212 const css::uno::Reference< css::embed::XStorage >& xDocumentRoot ,
236 std::u16string_view sTarget);
251 css::uno::Reference< css::io::XStream >
openPreset(std::u16string_view sPreset);
267 css::uno::Reference< css::io::XStream >
openTarget(
268 std::u16string_view sTarget, sal_Int32 nMode);
329 OUString& rLanguageTag ,
330 bool bAllowFallbacks );
362 OUString& rLanguageTag ,
363 bool bAllowFallback);
373 ::std::vector< OUString >
impl_getSubFolderNames(
const css::uno::Reference< css::embed::XStorage >& xFolder);
::std::vector< OUString > impl_getSubFolderNames(const css::uno::Reference< css::embed::XStorage > &xFolder)
returns the names of all sub storages of specified storage.
css::uno::Reference< css::io::XStream > openPreset(std::u16string_view sPreset)
open the specified preset as stream object and return it.
PresetHandler(css::uno::Reference< css::uno::XComponentContext > xContext)
does nothing real.
css::uno::Reference< css::embed::XStorage > m_xWorkingStorageUser
holds the folder storage of the user layer alive, where the current configuration set exists.
css::uno::Reference< css::embed::XStorage > getOrCreateRootStorageShare()
return access to the internally used and cached root storage.
css::uno::Reference< css::embed::XStorage > getParentStorageShare()
check if there is a parent storage well known for the specified child storage and return it.
css::uno::Reference< css::embed::XStorage > getWorkingStorageUser() const
provides access to the current working storages.
css::uno::Reference< css::uno::XComponentContext > m_xContext
can be used to create on needed uno resources.
void removeStorageListener(XMLBasedAcceleratorConfiguration *pListener)
css::uno::Reference< css::embed::XStorage > m_xWorkingStorageShare
holds the folder storage of the share layer alive, where the current configuration set exists.
void commitUserChanges()
do anything which is necessary to flush all changes back to disk.
StorageHolder m_lDocumentStorages
if we run in document mode, we can't use the global root storages! We have to use a special document ...
OUString m_sRelPathShare
knows the relative path from the root.
void copyPresetToTarget(std::u16string_view sPreset, std::u16string_view sTarget)
try to copy the specified preset from the share layer to the user layer and establish it as the speci...
EConfigType
this handler can provide different types of configuration.
css::uno::Reference< css::embed::XStorage > impl_openLocalizedPathIgnoringErrors(OUString &sPath, sal_Int32 eMode, bool bShare, OUString &rLanguageTag, bool bAllowFallback)
open a config path ignoring errors (catching exceptions).
~PresetHandler()
closes all open storages ... if user forgot that .
void forgetCachedStorages()
free all currently cache(!) storages.
css::uno::Reference< css::embed::XStorage > getOrCreateRootStorageUser()
void connectToResource(EConfigType eConfigType, std::u16string_view sResourceType, std::u16string_view sModule, const css::uno::Reference< css::embed::XStorage > &xDocumentRoot, const LanguageTag &rLanguageTag=LanguageTag(LANGUAGE_USER_PRIV_NOTRANSLATE))
free all internal structures and let this handler work on a new type of configuration sets.
css::uno::Reference< css::embed::XStorage > impl_openPathIgnoringErrors(const OUString &sPath, sal_Int32 eMode, bool bShare)
open a config path ignoring errors (catching exceptions).
EConfigType m_eConfigType
knows the type of provided configuration.
css::uno::Reference< css::embed::XStorage > getParentStorageUser()
void addStorageListener(XMLBasedAcceleratorConfiguration *pListener)
TODO.
::std::vector< OUString >::const_iterator impl_findMatchingLocalizedValue(const ::std::vector< OUString > &lLocalizedValues, OUString &rLanguageTag, bool bAllowFallbacks)
try to find the specified locale inside list of possible ones.
css::uno::Reference< css::io::XStream > openTarget(std::u16string_view sTarget, sal_Int32 nMode)
open the specified target as stream object and return it.
css::uno::Reference< css::embed::XStorage > m_xWorkingStorageNoLang
global language-independent storage
implements a read/write access to the accelerator configuration.