Kaydet (Commit) 18537be0 authored tarafından Julien Nabet's avatar Julien Nabet Kaydeden (comit) Noel Grandin

Replace some lists by vectors in deployment/registry (desktop)

Change-Id: I264a8b4d8fc90f647d5a6f1aef4a190353d494e5
Reviewed-on: https://gerrit.libreoffice.org/44143Reviewed-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
Tested-by: 's avatarNoel Grandin <noel.grandin@collabora.co.uk>
üst bbf1312b
......@@ -213,7 +213,7 @@ BackendImpl::BackendImpl(
//are still registers. Only after revoking and restarting OOo the folders
//can be removed. This works now, because the extension manager is a singleton
//and the backends are only create once per process.
std::list<OUString> folders = m_backendDb->getAllDataUrls();
std::vector<OUString> folders = m_backendDb->getAllDataUrls();
deleteUnusedFolders(folders);
configmgrini_verify_init( xCmdEnv );
......
......@@ -127,11 +127,11 @@ ConfigurationBackendDb::getEntry(OUString const & url)
}
}
std::list<OUString> ConfigurationBackendDb::getAllDataUrls()
std::vector<OUString> ConfigurationBackendDb::getAllDataUrls()
{
try
{
std::list<OUString> listRet;
std::vector<OUString> listRet;
Reference<css::xml::dom::XDocument> doc = getDocument();
Reference<css::xml::dom::XNode> root = doc->getFirstChild();
......
......@@ -22,7 +22,7 @@
#include <rtl/ustring.hxx>
#include <rtl/string.hxx>
#include <list>
#include <vector>
#include <boost/optional.hpp>
#include <dp_backenddb.hxx>
......@@ -70,7 +70,7 @@ public:
void addEntry(OUString const & url, Data const & data);
::boost::optional<Data> getEntry(OUString const & url);
std::list< OUString> getAllDataUrls();
std::vector< OUString> getAllDataUrls();
};
......
......@@ -248,7 +248,7 @@ void PackageRegistryBackend::deleteTempFolder(
//then created a Folder with a same name and a trailing '_'
//If the folderURL has no '_' then there is no corresponding tmp file.
void PackageRegistryBackend::deleteUnusedFolders(
std::list< OUString> const & usedFolders)
std::vector< OUString> const & usedFolders)
{
try
{
......
......@@ -565,12 +565,12 @@ std::list< OUString> BackendDb::readList(
}
}
std::list<OUString> BackendDb::getOneChildFromAllEntries(
std::vector<OUString> BackendDb::getOneChildFromAllEntries(
OUString const & name)
{
try
{
std::list<OUString> listRet;
std::vector<OUString> listRet;
Reference<css::xml::dom::XDocument> doc = getDocument();
Reference<css::xml::dom::XNode> root = doc->getFirstChild();
......
......@@ -144,7 +144,7 @@ BackendImpl::BackendImpl(
//are still registers. Only after revoking and restarting OOo the folders
//can be removed. This works now, because the extension manager is a singleton
//and the backends are only create once per process.
std::list<OUString> folders = m_backendDb->getAllDataUrls();
std::vector<OUString> folders = m_backendDb->getAllDataUrls();
deleteUnusedFolders(folders);
}
}
......
......@@ -123,7 +123,7 @@ HelpBackendDb::getEntry(OUString const & url)
}
}
std::list<OUString> HelpBackendDb::getAllDataUrls()
std::vector<OUString> HelpBackendDb::getAllDataUrls()
{
return getOneChildFromAllEntries("data-url");
}
......
......@@ -21,7 +21,6 @@
#define INCLUDED_DESKTOP_SOURCE_DEPLOYMENT_REGISTRY_HELP_DP_HELPBACKENDDB_HXX
#include <rtl/ustring.hxx>
#include <list>
#include <boost/optional.hpp>
#include <dp_backenddb.hxx>
......@@ -68,7 +67,7 @@ public:
::boost::optional<Data> getEntry(OUString const & url);
//must also return the data urls for entries with @activ="false". That is,
//those are currently revoked.
std::list< OUString> getAllDataUrls();
std::vector< OUString> getAllDataUrls();
};
......
......@@ -32,7 +32,6 @@
#include <com/sun/star/deployment/XPackageRegistry.hpp>
#include <com/sun/star/deployment/XPackageManager.hpp>
#include <com/sun/star/deployment/InvalidRemovedParameterException.hpp>
#include <list>
#include <unordered_map>
#include <strings.hrc>
......@@ -251,7 +250,7 @@ protected:
not used are deleted.
*/
void deleteUnusedFolders(
std::list< OUString> const & usedFolders);
std::vector< OUString> const & usedFolders);
/* deletes one folder with a "temporary" name and the corresponding
tmp file, which was used to derive the folder name.
*/
......
......@@ -109,7 +109,7 @@ protected:
/* returns the values of one particularly child element of all key elements.
*/
std::list< OUString> getOneChildFromAllEntries(
std::vector< OUString> getOneChildFromAllEntries(
OUString const & sElementName);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment