Skip implicit link info for multiple OS X archs
[cmake.git] / Source / cmTest.h
blob003bfa3f3a5abc7fdf9327a1b1c32f84657aab79
1 /*=========================================================================
3 Program: CMake - Cross-Platform Makefile Generator
4 Module: $RCSfile: cmTest.h,v $
5 Language: C++
6 Date: $Date: 2009-08-11 13:07:28 $
7 Version: $Revision: 1.9 $
9 Copyright (c) 2002 Kitware, Inc., Insight Consortium. All rights reserved.
10 See Copyright.txt or http://www.cmake.org/HTML/Copyright.html for details.
12 This software is distributed WITHOUT ANY WARRANTY; without even
13 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 PURPOSE. See the above copyright notices for more information.
16 =========================================================================*/
17 #ifndef cmTest_h
18 #define cmTest_h
20 #include "cmCustomCommand.h"
21 #include "cmPropertyMap.h"
22 class cmMakefile;
23 class cmListFileBacktrace;
25 /** \class cmTest
26 * \brief Represent a test
28 * cmTest is representation of a test.
30 class cmTest
32 public:
33 /**
35 cmTest(cmMakefile* mf);
36 ~cmTest();
38 ///! Set the test name
39 void SetName(const char* name);
40 const char* GetName() const { return this->Name.c_str(); }
42 void SetCommand(std::vector<std::string> const& command);
43 std::vector<std::string> const& GetCommand() const
45 return this->Command;
48 /**
49 * Print the structure to std::cout.
51 void Print() const;
53 ///! Set/Get a property of this source file
54 void SetProperty(const char *prop, const char *value);
55 void AppendProperty(const char* prop, const char* value);
56 const char *GetProperty(const char *prop) const;
57 bool GetPropertyAsBool(const char *prop) const;
58 cmPropertyMap &GetProperties() { return this->Properties; };
60 // Define the properties
61 static void DefineProperties(cmake *cm);
63 /** Get the cmMakefile instance that owns this test. */
64 cmMakefile *GetMakefile() { return this->Makefile;};
66 /** Get the backtrace of the command that created this test. */
67 cmListFileBacktrace const& GetBacktrace() const;
69 /** Get/Set whether this is an old-style test. */
70 bool GetOldStyle() const { return this->OldStyle; }
71 void SetOldStyle(bool b) { this->OldStyle = b; }
73 private:
74 cmPropertyMap Properties;
75 cmStdString Name;
76 std::vector<std::string> Command;
78 bool OldStyle;
80 cmMakefile* Makefile;
81 cmListFileBacktrace* Backtrace;
84 #endif