You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

60 lines
1007 B

2 years ago
  1. #include "../pch.h"
  2. class Ware {
  3. public:
  4. struct Size {
  5. double width;
  6. double height;
  7. };
  8. enum WareType {
  9. DefaultWare,
  10. CoolingWare,
  11. LargeWare
  12. };
  13. private:
  14. static int count;
  15. Id id;
  16. bool hasCooling;
  17. std::string name;
  18. Size size;
  19. WareType type;
  20. public:
  21. Ware();
  22. ~Ware();
  23. Ware(std::string name, bool hasCooling, double width, double height);
  24. Id getId() const;
  25. void setId(const Id id);
  26. bool getHasCooling() const;
  27. void setHasCooling(const bool isCoolable);
  28. std::string getName() const;
  29. void setName(const std::string name);
  30. Size getSize() const;
  31. void setSize(const double width, const double height);
  32. WareType getType() const;
  33. void setType(const WareType type);
  34. Id generateId();
  35. bool isLargeWare(Size s);
  36. };