GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 60.0% 3 / 1 / 6
Functions: 60.0% 3 / 1 / 6
Branches: -% 0 / 1 / 1

src/model/CentralHeatPumpSystem.hpp
Line Branch Exec Source
1 /***********************************************************************************************************************
2 * OpenStudio(R), Copyright (c) Alliance for Energy Innovation, LLC.
3 * See also https://openstudio.net/license
4 ***********************************************************************************************************************/
5
6 #ifndef MODEL_CENTRALHEATPUMPSYSTEM_HPP
7 #define MODEL_CENTRALHEATPUMPSYSTEM_HPP
8
9 #include "ModelAPI.hpp"
10 #include "WaterToWaterComponent.hpp"
11
12 #include "../utilities/core/Deprecated.hpp"
13
14 namespace openstudio {
15
16 namespace model {
17
18 class Schedule;
19 class ModelObjectList;
20 class CentralHeatPumpSystemModule;
21
22 namespace detail {
23
24 class CentralHeatPumpSystem_Impl;
25
26 } // namespace detail
27
28 /** CentralHeatPumpSystem is a WaterToWaterComponent that wraps the OpenStudio IDD object 'OS:CentralHeatPumpSystem'. */
29 class MODEL_API CentralHeatPumpSystem : public WaterToWaterComponent
30 {
31 public:
32 /** @name Constructors and Destructors */
33 //@{
34
35 /* This constructor adds a chiller heater module list to store your CentralHeatPumpSystemModules, but it doesn't add a CentralHeatPumpSystemModule
36 * At least one CentralHeatPumpSystemModule is needed for this object to work correctly (and be translated) to EnergyPlus.
37 */
38 explicit CentralHeatPumpSystem(const Model& model);
39
40 105 virtual ~CentralHeatPumpSystem() override = default;
41 // Default the copy and move operators because the virtual dtor is explicit
42 9 CentralHeatPumpSystem(const CentralHeatPumpSystem& other) = default;
43 27 CentralHeatPumpSystem(CentralHeatPumpSystem&& other) = default;
44 ✗ CentralHeatPumpSystem& operator=(const CentralHeatPumpSystem&) = default;
45 ✗ CentralHeatPumpSystem& operator=(CentralHeatPumpSystem&&) = default;
46
47 //@}
48
49 static IddObjectType iddObjectType();
50
51 OS_DEPRECATED(3, 12, 0) static std::vector<std::string> controlMethodValues();
52
53 /** @name Getters */
54 //@{
55
56 OS_DEPRECATED(3, 12, 0) std::string controlMethod() const;
57
58 double ancillaryPower() const;
59
60 boost::optional<Schedule> ancillaryOperationSchedule() const;
61
62 //@}
63 /** @name Setters */
64 //@{
65
66 OS_DEPRECATED(3, 12, 0) bool setControlMethod(const std::string& controlMethod);
67
68 bool setAncillaryPower(double ancillaryPower);
69
70 bool setAncillaryOperationSchedule(Schedule& schedule);
71
72 void resetAncillaryOperationSchedule();
73
74 //@}
75 /** @name Other */
76 //@{
77
78 bool addModule(const CentralHeatPumpSystemModule& centralHeatPumpSystemModule);
79
80 void removeModule(const CentralHeatPumpSystemModule& centralHeatPumpSystemModule);
81
82 void removeAllModules();
83
84 std::vector<CentralHeatPumpSystemModule> modules() const;
85
86 /** Convenience Function to return the Cooling Loop **/
87 boost::optional<PlantLoop> coolingPlantLoop() const;
88
89 /** Convenience Function to return the Source Loop **/
90 boost::optional<PlantLoop> sourcePlantLoop() const;
91
92 /** Convenience Function to return the Heating Loop **/
93 boost::optional<PlantLoop> heatingPlantLoop() const;
94
95 //@}
96 protected:
97 /// @cond
98 using ImplType = detail::CentralHeatPumpSystem_Impl;
99
100 explicit CentralHeatPumpSystem(std::shared_ptr<detail::CentralHeatPumpSystem_Impl> impl);
101
102 friend class detail::CentralHeatPumpSystem_Impl;
103 friend class Model;
104 friend class IdfObject;
105 friend class openstudio::detail::IdfObject_Impl;
106 /// @endcond
107 private:
108 − REGISTER_LOGGER("openstudio.model.CentralHeatPumpSystem");
109 };
110
111 /** \relates CentralHeatPumpSystem*/
112 using OptionalCentralHeatPumpSystem = boost::optional<CentralHeatPumpSystem>;
113
114 /** \relates CentralHeatPumpSystem*/
115 using CentralHeatPumpSystemVector = std::vector<CentralHeatPumpSystem>;
116
117 } // namespace model
118 } // namespace openstudio
119
120 #endif // MODEL_CENTRALHEATPUMPSYSTEM_HPP
121