123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899 |
- #ifndef cmCommand_h
- #define cmCommand_h
- #include "cmConfigure.h"
- #include <string>
- #include <vector>
- class cmExecutionStatus;
- class cmMakefile;
- struct cmListFileArgument;
- class cmCommand
- {
- CM_DISABLE_COPY(cmCommand)
- public:
-
- cmCommand()
- : Makefile(nullptr)
- {
- }
-
- virtual ~cmCommand() {}
-
- void SetMakefile(cmMakefile* m) { this->Makefile = m; }
- cmMakefile* GetMakefile() { return this->Makefile; }
-
- virtual bool InvokeInitialPass(const std::vector<cmListFileArgument>& args,
- cmExecutionStatus& status);
-
- virtual bool InitialPass(std::vector<std::string> const& args,
- cmExecutionStatus&) = 0;
-
- virtual void FinalPass() {}
-
- virtual bool HasFinalPass() const { return false; }
-
- virtual cmCommand* Clone() = 0;
-
- const char* GetError();
-
- void SetError(const std::string& e);
- protected:
- cmMakefile* Makefile;
- private:
- std::string Error;
- };
- #endif
|