GCC Code Coverage Report


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

src/model/HeatPumpAirToWaterCoolingSpeedData.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_HEATPUMPAIRTOWATERCOOLINGSPEEDDATA_HPP
7 #define MODEL_HEATPUMPAIRTOWATERCOOLINGSPEEDDATA_HPP
8
9 #include "ModelAPI.hpp"
10 #include "ResourceObject.hpp"
11
12 namespace openstudio {
13
14 namespace model {
15
16 class Curve;
17 class HeatPumpAirToWaterCooling;
18
19 namespace detail {
20
21 class HeatPumpAirToWaterCoolingSpeedData_Impl;
22
23 } // namespace detail
24
25 /** HeatPumpAirToWaterCoolingSpeedData is a ResourceObject that wraps the OpenStudio IDD object 'OS:HeatPump:AirToWater:Cooling:SpeedData'. */
26 class MODEL_API HeatPumpAirToWaterCoolingSpeedData : public ResourceObject
27 {
28 public:
29 /** @name Constructors and Destructors */
30 //@{
31
32 explicit HeatPumpAirToWaterCoolingSpeedData(const Model& model);
33
34 explicit HeatPumpAirToWaterCoolingSpeedData(const Model& model, const Curve& normalizedCoolingCapacityFunctionofTemperatureCurve,
35 const Curve& coolingEnergyInputRatioFunctionofTemperatureCurve,
36 const Curve& coolingEnergyInputRatioFunctionofPLRCurve);
37
38 2204 virtual ~HeatPumpAirToWaterCoolingSpeedData() = default;
39 // Default the copy and move operators because the virtual dtor is explicit
40 22 HeatPumpAirToWaterCoolingSpeedData(const HeatPumpAirToWaterCoolingSpeedData& other) = default;
41 1551 HeatPumpAirToWaterCoolingSpeedData(HeatPumpAirToWaterCoolingSpeedData&& other) = default;
42 ✗ HeatPumpAirToWaterCoolingSpeedData& operator=(const HeatPumpAirToWaterCoolingSpeedData&) = default;
43 5 HeatPumpAirToWaterCoolingSpeedData& operator=(HeatPumpAirToWaterCoolingSpeedData&&) = default;
44
45 //@}
46
47 static IddObjectType iddObjectType();
48
49 /** @name Getters */
50 //@{
51
52 boost::optional<double> ratedCoolingCapacity() const;
53
54 bool isRatedCoolingCapacityAutosized() const;
55
56 double ratedCOPforCooling() const;
57
58 Curve normalizedCoolingCapacityFunctionofTemperatureCurve() const;
59
60 Curve coolingEnergyInputRatioFunctionofTemperatureCurve() const;
61
62 Curve coolingEnergyInputRatioFunctionofPLRCurve() const;
63
64 //@}
65 /** @name Setters */
66 //@{
67
68 bool setRatedCoolingCapacity(double ratedCoolingCapacity);
69
70 void autosizeRatedCoolingCapacity();
71
72 bool setRatedCOPforCooling(double ratedCOPforCooling);
73
74 bool setNormalizedCoolingCapacityFunctionofTemperatureCurve(const Curve& bivariateFunctions);
75
76 bool setCoolingEnergyInputRatioFunctionofTemperatureCurve(const Curve& bivariateFunctions);
77
78 bool setCoolingEnergyInputRatioFunctionofPLRCurve(const Curve& univariateFunctions);
79
80 //@}
81 /** @name Other */
82 //@{
83
84 // convenience function that returns a vector of HeatPumpAirToWaterCooling that use this as their Speed Data (either regular speed or Booster)
85 std::vector<HeatPumpAirToWaterCooling> heatPumpAirToWaterCoolings() const;
86
87 boost::optional<double> autosizedRatedCoolingCapacity();
88
89 void autosize();
90
91 //@}
92 protected:
93 /// @cond
94 using ImplType = detail::HeatPumpAirToWaterCoolingSpeedData_Impl;
95
96 explicit HeatPumpAirToWaterCoolingSpeedData(std::shared_ptr<detail::HeatPumpAirToWaterCoolingSpeedData_Impl> impl);
97
98 friend class detail::HeatPumpAirToWaterCoolingSpeedData_Impl;
99 friend class Model;
100 friend class IdfObject;
101 friend class openstudio::detail::IdfObject_Impl;
102 /// @endcond
103 private:
104 − REGISTER_LOGGER("openstudio.model.HeatPumpAirToWaterCoolingSpeedData");
105 };
106
107 /** \relates HeatPumpAirToWaterCoolingSpeedData*/
108 using OptionalHeatPumpAirToWaterCoolingSpeedData = boost::optional<HeatPumpAirToWaterCoolingSpeedData>;
109
110 /** \relates HeatPumpAirToWaterCoolingSpeedData*/
111 using HeatPumpAirToWaterCoolingSpeedDataVector = std::vector<HeatPumpAirToWaterCoolingSpeedData>;
112
113 } // namespace model
114 } // namespace openstudio
115
116 #endif // MODEL_HEATPUMPAIRTOWATERCOOLINGSPEEDDATA_HPP
117