diff options
Diffstat (limited to 'src/libs/installer/repositorycategory.cpp')
-rw-r--r-- | src/libs/installer/repositorycategory.cpp | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/libs/installer/repositorycategory.cpp b/src/libs/installer/repositorycategory.cpp index 79b1cc6a8..d1a51e8b0 100644 --- a/src/libs/installer/repositorycategory.cpp +++ b/src/libs/installer/repositorycategory.cpp @@ -1,6 +1,6 @@ /************************************************************************** ** -** Copyright (C) 2018 The Qt Company Ltd. +** Copyright (C) 2020 The Qt Company Ltd. ** Contact: https://www.qt.io/licensing/ ** ** This file is part of the Qt Installer Framework. @@ -113,6 +113,18 @@ QSet<Repository> RepositoryCategory::repositories() const } /*! + Returns the list of repository URLs the category has. +*/ +QSet<QUrl> RepositoryCategory::repositoryUrls() const +{ + QSet<QUrl> repositoryUrls; + foreach (const Repository &repository, repositories()) + repositoryUrls.insert(repository.url()); + + return repositoryUrls; +} + +/*! Inserts a set of \a repositories to the category. Removes old \a repositories if \a replace is set to \c true. */ |