1 /*=========================================================================
3 Program: CMake - Cross-Platform Makefile Generator
4 Module: $RCSfile: cmGetDirectoryPropertyCommand.h,v $
6 <<<<<<< cmGetDirectoryPropertyCommand.h
7 Date: $Date: 2008/01/23 15:27:59 $
8 Version: $Revision: 1.8 $
10 Date: $Date: 2008-06-26 14:58:44 $
11 Version: $Revision: 1.9 $
14 Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
15 See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
17 This software is distributed WITHOUT ANY WARRANTY; without even
18 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
19 PURPOSE. See the above copyright notices for more information.
21 =========================================================================*/
22 #ifndef cmGetDirectoryPropertyCommand_h
23 #define cmGetDirectoryPropertyCommand_h
25 #include "cmCommand.h"
27 class cmGetDirectoryPropertyCommand
: public cmCommand
30 virtual cmCommand
* Clone()
32 return new cmGetDirectoryPropertyCommand
;
36 * This is called when the command is first encountered in
39 virtual bool InitialPass(std::vector
<std::string
> const& args
,
40 cmExecutionStatus
&status
);
43 * This determines if the command is invoked when in script mode.
45 virtual bool IsScriptable() { return true; }
48 * The name of the command as specified in CMakeList.txt.
50 virtual const char* GetName() { return "get_directory_property";}
53 * Succinct documentation.
55 virtual const char* GetTerseDocumentation()
57 return "Get a property of DIRECTORY scope.";
61 * Longer documentation.
63 virtual const char* GetFullDocumentation()
66 " get_directory_property(<variable> [DIRECTORY <dir>] <prop-name>)\n"
67 "Store a property of directory scope in the named variable. "
68 "If the property is not defined the empty-string is returned. "
69 "The DIRECTORY argument specifies another directory from which "
70 "to retrieve the property value. "
71 "The specified directory must have already been traversed by "
74 " get_directory_property(<variable> [DIRECTORY <dir>]\n"
75 " DEFINITION <var-name>)\n"
76 "Get a variable definition from a directory. "
77 "This form is useful to get a variable definition from another "
82 cmTypeMacro(cmGetDirectoryPropertyCommand
, cmCommand
);