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/CoilHeatingDXMultiSpeedStageData.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_COILHEATINGDXMULTISPEEDSTAGEDATA_HPP
7 #define MODEL_COILHEATINGDXMULTISPEEDSTAGEDATA_HPP
8
9 #include "ModelAPI.hpp"
10 #include "ParentObject.hpp"
11 #include "../model/CoilHeatingDXMultiSpeed.hpp"
12 #include "../utilities/core/Deprecated.hpp"
13
14 namespace openstudio {
15
16 namespace model {
17
18 class Curve;
19
20 namespace detail {
21
22 class CoilHeatingDXMultiSpeedStageData_Impl;
23
24 } // namespace detail
25
26 /** CoilHeatingDXMultiSpeedStageData is a ParentObject that wraps the OpenStudio IDD object 'OS:Coil:Heating:DX:MultiSpeed:StageData'. */
27 class MODEL_API CoilHeatingDXMultiSpeedStageData : public ParentObject
28 {
29 public:
30 /** @name Constructors and Destructors */
31 //@{
32
33 explicit CoilHeatingDXMultiSpeedStageData(const Model& model);
34
35 explicit CoilHeatingDXMultiSpeedStageData(const Model& model, const Curve& heatingCapacityFunctionofTemperature,
36 const Curve& heatingCapacityFunctionofFlowFraction, const Curve& energyInputRatioFunctionofTemperature,
37 const Curve& energyInputRatioFunctionofFlowFraction, const Curve& partLoadFractionCorrelation,
38 const Curve& wasteHeatFunctionofTemperature);
39
40 525 virtual ~CoilHeatingDXMultiSpeedStageData() override = default;
41 // Default the copy and move operators because the virtual dtor is explicit
42 144 CoilHeatingDXMultiSpeedStageData(const CoilHeatingDXMultiSpeedStageData& other) = default;
43 217 CoilHeatingDXMultiSpeedStageData(CoilHeatingDXMultiSpeedStageData&& other) = default;
44 ✗ CoilHeatingDXMultiSpeedStageData& operator=(const CoilHeatingDXMultiSpeedStageData&) = default;
45 4 CoilHeatingDXMultiSpeedStageData& operator=(CoilHeatingDXMultiSpeedStageData&&) = default;
46
47 //@}
48
49 static IddObjectType iddObjectType();
50
51 /** @name Getters */
52 //@{
53
54 boost::optional<double> grossRatedHeatingCapacity() const;
55
56 bool isGrossRatedHeatingCapacityAutosized() const;
57
58 double grossRatedHeatingCOP() const;
59
60 boost::optional<double> ratedAirFlowRate() const;
61
62 bool isRatedAirFlowRateAutosized() const;
63
64 OS_DEPRECATED(3, 5, 0) double ratedSupplyAirFanPowerPerVolumeFlowRate() const;
65
66 double ratedSupplyAirFanPowerPerVolumeFlowRate2017() const;
67
68 double ratedSupplyAirFanPowerPerVolumeFlowRate2023() const;
69
70 Curve heatingCapacityFunctionofTemperatureCurve() const;
71
72 Curve heatingCapacityFunctionofFlowFractionCurve() const;
73
74 Curve energyInputRatioFunctionofTemperatureCurve() const;
75
76 Curve energyInputRatioFunctionofFlowFractionCurve() const;
77
78 Curve partLoadFractionCorrelationCurve() const;
79
80 double ratedWasteHeatFractionofPowerInput() const;
81
82 Curve wasteHeatFunctionofTemperatureCurve() const;
83
84 //@}
85 /** @name Setters */
86 //@{
87
88 bool setGrossRatedHeatingCapacity(double grossRatedHeatingCapacity);
89
90 void autosizeGrossRatedHeatingCapacity();
91
92 bool setGrossRatedHeatingCOP(double grossRatedHeatingCOP);
93
94 bool setRatedAirFlowRate(double ratedAirFlowRate);
95
96 void autosizeRatedAirFlowRate();
97
98 OS_DEPRECATED(3, 5, 0) bool setRatedSupplyAirFanPowerPerVolumeFlowRate(double ratedSupplyAirFanPowerPerVolumeFlowRate);
99
100 bool setRatedSupplyAirFanPowerPerVolumeFlowRate2017(double ratedSupplyAirFanPowerPerVolumeFlowRate2017);
101
102 bool setRatedSupplyAirFanPowerPerVolumeFlowRate2023(double ratedSupplyAirFanPowerPerVolumeFlowRate2023);
103
104 bool setHeatingCapacityFunctionofTemperatureCurve(const Curve& curve);
105
106 bool setHeatingCapacityFunctionofFlowFractionCurve(const Curve& curve);
107
108 bool setEnergyInputRatioFunctionofTemperatureCurve(const Curve& curve);
109
110 bool setEnergyInputRatioFunctionofFlowFractionCurve(const Curve& curve);
111
112 bool setPartLoadFractionCorrelationCurve(const Curve& curve);
113
114 bool setRatedWasteHeatFractionofPowerInput(double ratedWasteHeatFractionofPowerInput);
115
116 bool setWasteHeatFunctionofTemperatureCurve(const Curve& curve);
117
118 //@}
119 /** @name Other */
120 //@{
121
122 // Returns the CoilHeatingDXMultiSpeed that references it if any
123 boost::optional<CoilHeatingDXMultiSpeed> parentCoil() const;
124
125 boost::optional<double> autosizedGrossRatedHeatingCapacity() const;
126
127 boost::optional<double> autosizedRatedAirFlowRate() const;
128
129 void autosize();
130
131 void applySizingValues();
132
133 //@}
134 protected:
135 /// @cond
136 using ImplType = detail::CoilHeatingDXMultiSpeedStageData_Impl;
137
138 explicit CoilHeatingDXMultiSpeedStageData(std::shared_ptr<detail::CoilHeatingDXMultiSpeedStageData_Impl> impl);
139
140 friend class detail::CoilHeatingDXMultiSpeedStageData_Impl;
141 friend class Model;
142 friend class IdfObject;
143 friend class openstudio::detail::IdfObject_Impl;
144 /// @endcond
145 private:
146 − REGISTER_LOGGER("openstudio.model.CoilHeatingDXMultiSpeedStageData");
147
148 // Used to determine the index of this performance data in the
149 // list of stages in the parent object.
150 boost::optional<std::tuple<int, CoilHeatingDXMultiSpeed>> stageIndexAndParentCoil() const;
151 };
152
153 /** \relates CoilHeatingDXMultiSpeedStageData*/
154 using OptionalCoilHeatingDXMultiSpeedStageData = boost::optional<CoilHeatingDXMultiSpeedStageData>;
155
156 /** \relates CoilHeatingDXMultiSpeedStageData*/
157 using CoilHeatingDXMultiSpeedStageDataVector = std::vector<CoilHeatingDXMultiSpeedStageData>;
158
159 } // namespace model
160 } // namespace openstudio
161
162 #endif // MODEL_COILHEATINGDXMULTISPEEDSTAGEDATA_HPP
163