2016-10-30 18:24:19 +01:00
|
|
|
/* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
|
|
|
|
file Copyright.txt or https://cmake.org/licensing for details. */
|
2008-10-12 18:41:06 +02:00
|
|
|
#ifndef cmProperty_h
|
|
|
|
#define cmProperty_h
|
|
|
|
|
2017-07-20 19:35:53 +02:00
|
|
|
#include "cmConfigure.h" // IWYU pragma: keep
|
2016-10-30 18:24:19 +01:00
|
|
|
|
|
|
|
#include <string>
|
2008-10-12 18:41:06 +02:00
|
|
|
|
2013-03-16 19:13:01 +02:00
|
|
|
class cmProperty
|
2008-10-12 18:41:06 +02:00
|
|
|
{
|
|
|
|
public:
|
2016-07-09 11:21:54 +02:00
|
|
|
enum ScopeType
|
|
|
|
{
|
|
|
|
TARGET,
|
|
|
|
SOURCE_FILE,
|
|
|
|
DIRECTORY,
|
|
|
|
GLOBAL,
|
|
|
|
CACHE,
|
|
|
|
TEST,
|
|
|
|
VARIABLE,
|
|
|
|
CACHED_VARIABLE,
|
|
|
|
INSTALL
|
|
|
|
};
|
2008-10-12 18:41:06 +02:00
|
|
|
|
|
|
|
// set this property
|
2016-07-09 11:21:54 +02:00
|
|
|
void Set(const char* value);
|
2008-10-12 18:41:06 +02:00
|
|
|
|
|
|
|
// append to this property
|
2016-07-09 11:21:54 +02:00
|
|
|
void Append(const char* value, bool asString = false);
|
2008-10-12 18:41:06 +02:00
|
|
|
|
|
|
|
// get the value
|
2016-07-09 11:21:54 +02:00
|
|
|
const char* GetValue() const;
|
2008-10-12 18:41:06 +02:00
|
|
|
|
|
|
|
// construct with the value not set
|
2015-04-27 22:25:09 +02:00
|
|
|
cmProperty() { this->ValueHasBeenSet = false; }
|
2008-10-12 18:41:06 +02:00
|
|
|
|
|
|
|
protected:
|
|
|
|
std::string Value;
|
|
|
|
bool ValueHasBeenSet;
|
|
|
|
};
|
|
|
|
|
|
|
|
#endif
|