cmCTestUpdateCommand.h 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. /* Distributed under the OSI-approved BSD 3-Clause License. See accompanying
  2. file Copyright.txt or https://cmake.org/licensing for details. */
  3. #ifndef cmCTestUpdateCommand_h
  4. #define cmCTestUpdateCommand_h
  5. #include "cmConfigure.h" // IWYU pragma: keep
  6. #include "cmCTestHandlerCommand.h"
  7. #include "cmCommand.h"
  8. #include <string>
  9. #include <utility>
  10. #include "cm_memory.hxx"
  11. class cmCTestGenericHandler;
  12. /** \class cmCTestUpdate
  13. * \brief Run a ctest script
  14. *
  15. * cmCTestUpdateCommand defineds the command to updates the repository.
  16. */
  17. class cmCTestUpdateCommand : public cmCTestHandlerCommand
  18. {
  19. public:
  20. cmCTestUpdateCommand() {}
  21. /**
  22. * This is a virtual constructor for the command.
  23. */
  24. std::unique_ptr<cmCommand> Clone() override
  25. {
  26. auto ni = cm::make_unique<cmCTestUpdateCommand>();
  27. ni->CTest = this->CTest;
  28. ni->CTestScriptHandler = this->CTestScriptHandler;
  29. return std::unique_ptr<cmCommand>(std::move(ni));
  30. }
  31. /**
  32. * The name of the command as specified in CMakeList.txt.
  33. */
  34. std::string GetName() const override { return "ctest_update"; }
  35. protected:
  36. cmCTestGenericHandler* InitializeHandler() override;
  37. };
  38. #endif