cmCTestResourceSpec.h 881 B

12345678910111213141516171819202122232425262728293031323334353637383940
  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 cmCTestResourceSpec_h
  4. #define cmCTestResourceSpec_h
  5. #include <map>
  6. #include <string>
  7. #include <vector>
  8. class cmCTestResourceSpec
  9. {
  10. public:
  11. class Resource
  12. {
  13. public:
  14. std::string Id;
  15. unsigned int Capacity;
  16. bool operator==(const Resource& other) const;
  17. bool operator!=(const Resource& other) const;
  18. };
  19. class Socket
  20. {
  21. public:
  22. std::map<std::string, std::vector<Resource>> Resources;
  23. bool operator==(const Socket& other) const;
  24. bool operator!=(const Socket& other) const;
  25. };
  26. Socket LocalSocket;
  27. bool ReadFromJSONFile(const std::string& filename);
  28. bool operator==(const cmCTestResourceSpec& other) const;
  29. bool operator!=(const cmCTestResourceSpec& other) const;
  30. };
  31. #endif