1 /* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
2 file Copyright.txt or https://cmake.org/licensing for details. */
5 #include "cmConfigure.h" // IWYU pragma: keep
12 class cmCompiledGeneratorExpression;
15 /** \class cmInstalledFile
16 * \brief Represents a file intended for installation.
18 * cmInstalledFile represents a file intended for installation.
23 using CompiledGeneratorExpressionPtrType =
24 std::unique_ptr<cmCompiledGeneratorExpression>;
26 using ExpressionVectorType = std::vector<CompiledGeneratorExpressionPtrType>;
33 Property(const Property&) = delete;
34 Property& operator=(const Property&) = delete;
36 ExpressionVectorType ValueExpressions;
39 using PropertyMapType = std::map<std::string, Property>;
45 cmInstalledFile(const cmInstalledFile&) = delete;
46 cmInstalledFile& operator=(const cmInstalledFile&) = delete;
48 void RemoveProperty(const std::string& prop);
50 void SetProperty(cmMakefile const* mf, const std::string& prop,
51 const std::string& value);
53 void AppendProperty(cmMakefile const* mf, const std::string& prop,
54 const std::string& value, bool asString = false);
56 bool HasProperty(const std::string& prop) const;
58 bool GetProperty(const std::string& prop, std::string& value) const;
60 bool GetPropertyAsBool(const std::string& prop) const;
62 void GetPropertyAsList(const std::string& prop,
63 std::vector<std::string>& list) const;
65 void SetName(cmMakefile* mf, const std::string& name);
67 std::string const& GetName() const;
69 cmCompiledGeneratorExpression const& GetNameExpression() const;
71 PropertyMapType const& GetProperties() const { return this->Properties; }
75 CompiledGeneratorExpressionPtrType NameExpression;
76 PropertyMapType Properties;