Path: blob/master/Source/CPack/IFW/cmCPackIFWRepository.h
5020 views
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying1file LICENSE.rst or https://cmake.org/licensing for details. */2#pragma once34#include "cmConfigure.h" // IWYU pragma: keep56#include <string>7#include <vector>89#include "cmCPackIFWCommon.h"1011class cmXMLWriter;1213/** \class cmCPackIFWRepository14* \brief A remote repository to be created CPack IFW generator15*/16class cmCPackIFWRepository : public cmCPackIFWCommon17{18public:19// Types2021enum Action22{23None,24Add,25Remove,26Replace27};2829using RepositoriesVector = std::vector<cmCPackIFWRepository*>;3031public:32// Constructor3334/**35* Construct repository36*/37cmCPackIFWRepository();3839public:40// Configuration4142/// Internal repository name43std::string Name;4445/// Optional update action46Action Update;4748/// Is points to a list of available components49std::string Url;5051/// Is points to a list that will replaced52std::string OldUrl;5354/// Is points to a list that will replace to55std::string NewUrl;5657/// With "0" disabling this repository58std::string Enabled;5960/// Is used as user on a protected repository61std::string Username;6263/// Is password to use on a protected repository64std::string Password;6566/// Is optional string to display instead of the URL67std::string DisplayName;6869public:70// Internal implementation7172bool IsValid() const;7374bool ConfigureFromOptions();7576bool PatchUpdatesXml();7778void WriteRepositoryConfig(cmXMLWriter& xout) const;79void WriteRepositoryUpdate(cmXMLWriter& xout) const;80void WriteRepositoryUpdates(cmXMLWriter& xout);8182RepositoriesVector RepositoryUpdate;83std::string Directory;84};858687