1 /*============================================================================
2 CMake - Cross Platform Makefile Generator
3 Copyright 2000-2009 Kitware, Inc., Insight Software Consortium
5 Distributed under the OSI-approved BSD License (the "License");
6 see accompanying file Copyright.txt for details.
8 This software is distributed WITHOUT ANY WARRANTY; without even the
9 implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
10 See the License for more information.
11 ============================================================================*/
12 #ifndef cmGetCMakePropertyCommand_h
13 #define cmGetCMakePropertyCommand_h
15 #include "cmCommand.h"
17 class cmGetCMakePropertyCommand : public cmCommand
20 virtual cmCommand* Clone()
22 return new cmGetCMakePropertyCommand;
26 * This is called when the command is first encountered in
29 virtual bool InitialPass(std::vector<std::string> const& args,
30 cmExecutionStatus &status);
33 * This determines if the command is invoked when in script mode.
35 virtual bool IsScriptable() const { return true; }
38 * The name of the command as specified in CMakeList.txt.
40 virtual const char* GetName() const { return "get_cmake_property";}
43 * Succinct documentation.
45 virtual const char* GetTerseDocumentation() const
47 return "Get a property of the CMake instance.";
51 * Longer documentation.
53 virtual const char* GetFullDocumentation() const
56 " get_cmake_property(VAR property)\n"
57 "Get a property from the CMake instance. "
58 "The value of the property is stored in the variable VAR. "
59 "If the property is not found, VAR will be set to \"NOTFOUND\". "
60 "Some supported properties "
61 "include: VARIABLES, CACHE_VARIABLES, COMMANDS, MACROS, and "
64 "See also the more general get_property() command.";
67 cmTypeMacro(cmGetCMakePropertyCommand, cmCommand);