GCC Code Coverage Report


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

src/model/RefrigerationSecondarySystem.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_REFRIGERATIONSECONDARYSYSTEM_HPP
7 #define MODEL_REFRIGERATIONSECONDARYSYSTEM_HPP
8
9 #include "ModelAPI.hpp"
10 #include "ParentObject.hpp"
11
12 namespace openstudio {
13
14 namespace model {
15
16 class CurveCubic;
17 class ThermalZone;
18 class RefrigerationSystem;
19 class RefrigerationAirChiller;
20 class RefrigerationCase;
21 class RefrigerationWalkIn;
22
23 namespace detail {
24
25 class RefrigerationSecondarySystem_Impl;
26
27 } // namespace detail
28
29 /** RefrigerationSecondarySystem is a ParentObject that wraps the OpenStudio IDD object 'OS:Refrigeration:SecondarySystem'. */
30 class MODEL_API RefrigerationSecondarySystem : public ParentObject
31 {
32 public:
33 /** @name Constructors and Destructors */
34 //@{
35
36 explicit RefrigerationSecondarySystem(const Model& model);
37
38 202 virtual ~RefrigerationSecondarySystem() override = default;
39 // Default the copy and move operators because the virtual dtor is explicit
40 15 RefrigerationSecondarySystem(const RefrigerationSecondarySystem& other) = default;
41 63 RefrigerationSecondarySystem(RefrigerationSecondarySystem&& other) = default;
42 ✗ RefrigerationSecondarySystem& operator=(const RefrigerationSecondarySystem&) = default;
43 ✗ RefrigerationSecondarySystem& operator=(RefrigerationSecondarySystem&&) = default;
44
45 //@}
46
47 static IddObjectType iddObjectType();
48
49 static std::vector<std::string> circulatingFluidNameValues();
50
51 static std::vector<std::string> pumpDriveTypeValues();
52
53 bool addCase(const RefrigerationCase& refrigerationCase);
54
55 void removeCase(const RefrigerationCase& refrigerationCase);
56
57 void removeAllCases();
58
59 std::vector<RefrigerationCase> cases() const;
60
61 bool addWalkin(const RefrigerationWalkIn& refrigerationWalkin);
62
63 void removeWalkin(const RefrigerationWalkIn& refrigerationWalkin);
64
65 void removeAllWalkins();
66
67 std::vector<RefrigerationWalkIn> walkins() const;
68
69 bool addAirChiller(const RefrigerationAirChiller& airChiller);
70
71 void removeAirChiller(const RefrigerationAirChiller& airChiller);
72
73 void removeAllAirChillers();
74
75 std::vector<RefrigerationAirChiller> airChillers() const;
76
77 /** @name Getters */
78 //@{
79
80 std::string circulatingFluidName() const;
81
82 boost::optional<int> glycolConcentration() const;
83
84 boost::optional<double> evaporatorCapacity() const;
85
86 boost::optional<double> evaporatorFlowRateforSecondaryFluid() const;
87
88 double evaporatorEvaporatingTemperature() const;
89
90 double evaporatorApproachTemperatureDifference() const;
91
92 boost::optional<double> evaporatorRangeTemperatureDifference() const;
93
94 int numberofPumpsinLoop() const;
95
96 bool isNumberofPumpsinLoopDefaulted() const;
97
98 boost::optional<double> totalPumpFlowRate() const;
99
100 boost::optional<double> totalPumpPower() const;
101
102 boost::optional<double> totalPumpHead() const;
103
104 double phaseChangeCirculatingRate() const;
105
106 bool isPhaseChangeCirculatingRateDefaulted() const;
107
108 std::string pumpDriveType() const;
109
110 bool isPumpDriveTypeDefaulted() const;
111
112 boost::optional<CurveCubic> variableSpeedPumpCubicCurve() const;
113
114 double pumpMotorHeattoFluid() const;
115
116 bool isPumpMotorHeattoFluidDefaulted() const;
117
118 double sumUADistributionPiping() const;
119
120 bool isSumUADistributionPipingDefaulted() const;
121
122 boost::optional<ThermalZone> distributionPipingZone() const;
123
124 double sumUAReceiverSeparatorShell() const;
125
126 bool isSumUAReceiverSeparatorShellDefaulted() const;
127
128 boost::optional<ThermalZone> receiverSeparatorZone() const;
129
130 double evaporatorRefrigerantInventory() const;
131
132 bool isEvaporatorRefrigerantInventoryDefaulted() const;
133
134 std::string endUseSubcategory() const;
135
136 bool isEndUseSubcategoryDefaulted() const;
137
138 // Returns the parent RefrigerationSystem if any
139 boost::optional<RefrigerationSystem> system() const;
140
141 //@}
142 /** @name Setters */
143 //@{
144
145 void resetRefrigeratedCaseAndWalkInList();
146
147 bool setCirculatingFluidName(const std::string& circulatingFluidName);
148
149 bool setGlycolConcentration(int glycolConcentration);
150
151 void resetGlycolConcentration();
152
153 bool setEvaporatorCapacity(double evaporatorCapacity);
154
155 void resetEvaporatorCapacity();
156
157 bool setEvaporatorFlowRateforSecondaryFluid(double evaporatorFlowRateforSecondaryFluid);
158
159 void resetEvaporatorFlowRateforSecondaryFluid();
160
161 bool setEvaporatorEvaporatingTemperature(double evaporatorEvaporatingTemperature);
162
163 bool setEvaporatorApproachTemperatureDifference(double evaporatorApproachTemperatureDifference);
164
165 bool setEvaporatorRangeTemperatureDifference(double evaporatorRangeTemperatureDifference);
166
167 void resetEvaporatorRangeTemperatureDifference();
168
169 bool setNumberofPumpsinLoop(int numberofPumpsinLoop);
170
171 void resetNumberofPumpsinLoop();
172
173 bool setTotalPumpFlowRate(double totalPumpFlowRate);
174
175 void resetTotalPumpFlowRate();
176
177 bool setTotalPumpPower(double totalPumpPower);
178
179 void resetTotalPumpPower();
180
181 bool setTotalPumpHead(double totalPumpHead);
182
183 void resetTotalPumpHead();
184
185 bool setPhaseChangeCirculatingRate(double phaseChangeCirculatingRate);
186
187 void resetPhaseChangeCirculatingRate();
188
189 bool setPumpDriveType(const std::string& pumpDriveType);
190
191 void resetPumpDriveType();
192
193 bool setVariableSpeedPumpCubicCurve(const CurveCubic& curveCubic);
194
195 void resetVariableSpeedPumpCubicCurve();
196
197 bool setPumpMotorHeattoFluid(double pumpMotorHeattoFluid);
198
199 void resetPumpMotorHeattoFluid();
200
201 bool setSumUADistributionPiping(double sumUADistributionPiping);
202
203 void resetSumUADistributionPiping();
204
205 bool setDistributionPipingZone(const ThermalZone& thermalZone);
206
207 void resetDistributionPipingZone();
208
209 bool setSumUAReceiverSeparatorShell(double sumUAReceiverSeparatorShell);
210
211 void resetSumUAReceiverSeparatorShell();
212
213 bool setReceiverSeparatorZone(const ThermalZone& thermalZone);
214
215 void resetReceiverSeparatorZone();
216
217 bool setEvaporatorRefrigerantInventory(double evaporatorRefrigerantInventory);
218
219 void resetEvaporatorRefrigerantInventory();
220
221 bool setEndUseSubcategory(const std::string& endUseSubcategory);
222
223 void resetEndUseSubcategory();
224
225 // Remove from parent system if any
226 void removeFromSystem();
227
228 //@}
229 /** @name Other */
230 //@{
231
232 //@}
233 protected:
234 /// @cond
235 using ImplType = detail::RefrigerationSecondarySystem_Impl;
236
237 explicit RefrigerationSecondarySystem(std::shared_ptr<detail::RefrigerationSecondarySystem_Impl> impl);
238
239 friend class detail::RefrigerationSecondarySystem_Impl;
240 friend class Model;
241 friend class IdfObject;
242 friend class openstudio::detail::IdfObject_Impl;
243 /// @endcond
244 private:
245 REGISTER_LOGGER("openstudio.model.RefrigerationSecondarySystem");
246 };
247
248 /** \relates RefrigerationSecondarySystem*/
249 using OptionalRefrigerationSecondarySystem = boost::optional<RefrigerationSecondarySystem>;
250
251 /** \relates RefrigerationSecondarySystem*/
252 using RefrigerationSecondarySystemVector = std::vector<RefrigerationSecondarySystem>;
253
254 } // namespace model
255 } // namespace openstudio
256
257 #endif // MODEL_REFRIGERATIONSECONDARYSYSTEM_HPP
258