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/CurveQuadLinear.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_CURVEQUADLINEAR_HPP
7 #define MODEL_CURVEQUADLINEAR_HPP
8
9 #include <model/ModelAPI.hpp>
10 #include "Curve.hpp"
11
12 namespace openstudio {
13
14 namespace model {
15
16 namespace detail {
17
18 class CurveQuadLinear_Impl;
19
20 } // namespace detail
21
22 /** CurveQuadLinear is a Curve that wraps the OpenStudio IDD object 'OS:Curve:QuadLinear'.
23 * The functional form is \f$f(w, x, y, z) = c_1 + c_2 \cdot w + c_3 \cdot x + c_4 \cdot y +c_5 \cdot z\f$ */
24 class MODEL_API CurveQuadLinear : public Curve
25 {
26 public:
27 /** @name Constructors and Destructors */
28 //@{
29
30 explicit CurveQuadLinear(const Model& model);
31
32 187 virtual ~CurveQuadLinear() override = default;
33 // Default the copy and move operators because the virtual dtor is explicit
34 1 CurveQuadLinear(const CurveQuadLinear& other) = default;
35 33 CurveQuadLinear(CurveQuadLinear&& other) = default;
36 ✗ CurveQuadLinear& operator=(const CurveQuadLinear&) = default;
37 ✗ CurveQuadLinear& operator=(CurveQuadLinear&&) = default;
38
39 //@}
40
41 static IddObjectType iddObjectType();
42
43 static std::vector<std::string> inputUnitTypeforwValues();
44
45 static std::vector<std::string> inputUnitTypeforxValues();
46
47 static std::vector<std::string> inputUnitTypeforyValues();
48
49 static std::vector<std::string> inputUnitTypeforzValues();
50
51 /** @name Getters */
52 //@{
53
54 double coefficient1Constant() const;
55
56 double coefficient2w() const;
57
58 double coefficient3x() const;
59
60 double coefficient4y() const;
61
62 double coefficient5z() const;
63
64 double minimumValueofw() const;
65
66 double maximumValueofw() const;
67
68 double minimumValueofx() const;
69
70 double maximumValueofx() const;
71
72 double minimumValueofy() const;
73
74 double maximumValueofy() const;
75
76 double minimumValueofz() const;
77
78 double maximumValueofz() const;
79
80 boost::optional<double> minimumCurveOutput() const;
81
82 boost::optional<double> maximumCurveOutput() const;
83
84 std::string inputUnitTypeforw() const;
85
86 bool isInputUnitTypeforwDefaulted() const;
87
88 std::string inputUnitTypeforx() const;
89
90 bool isInputUnitTypeforxDefaulted() const;
91
92 std::string inputUnitTypefory() const;
93
94 bool isInputUnitTypeforyDefaulted() const;
95
96 std::string inputUnitTypeforz() const;
97
98 bool isInputUnitTypeforzDefaulted() const;
99
100 //@}
101 /** @name Setters */
102 //@{
103
104 bool setCoefficient1Constant(double coefficient1Constant);
105
106 bool setCoefficient2w(double coefficient2w);
107
108 bool setCoefficient3x(double coefficient3x);
109
110 bool setCoefficient4y(double coefficient4y);
111
112 bool setCoefficient5z(double coefficient5z);
113
114 bool setMinimumValueofw(double minimumValueofw);
115
116 bool setMaximumValueofw(double maximumValueofw);
117
118 bool setMinimumValueofx(double minimumValueofx);
119
120 bool setMaximumValueofx(double maximumValueofx);
121
122 bool setMinimumValueofy(double minimumValueofy);
123
124 bool setMaximumValueofy(double maximumValueofy);
125
126 bool setMinimumValueofz(double minimumValueofz);
127
128 bool setMaximumValueofz(double maximumValueofz);
129
130 bool setMinimumCurveOutput(double minimumCurveOutput);
131
132 void resetMinimumCurveOutput();
133
134 bool setMaximumCurveOutput(double maximumCurveOutput);
135
136 void resetMaximumCurveOutput();
137
138 bool setInputUnitTypeforw(const std::string& inputUnitTypeforw);
139
140 void resetInputUnitTypeforw();
141
142 bool setInputUnitTypeforx(const std::string& inputUnitTypeforx);
143
144 void resetInputUnitTypeforx();
145
146 bool setInputUnitTypefory(const std::string& inputUnitTypefory);
147
148 void resetInputUnitTypefory();
149
150 bool setInputUnitTypeforz(const std::string& inputUnitTypeforz);
151
152 void resetInputUnitTypeforz();
153
154 //@}
155 /** @name Other */
156 //@{
157
158 //@}
159 protected:
160 /// @cond
161 using ImplType = detail::CurveQuadLinear_Impl;
162
163 explicit CurveQuadLinear(std::shared_ptr<detail::CurveQuadLinear_Impl> impl);
164
165 friend class detail::CurveQuadLinear_Impl;
166 friend class Model;
167 friend class IdfObject;
168 friend class openstudio::detail::IdfObject_Impl;
169 /// @endcond
170 private:
171 REGISTER_LOGGER("openstudio.model.CurveQuadLinear");
172 };
173
174 /** \relates CurveQuadLinear*/
175 using OptionalCurveQuadLinear = boost::optional<CurveQuadLinear>;
176
177 /** \relates CurveQuadLinear*/
178 using CurveQuadLinearVector = std::vector<CurveQuadLinear>;
179
180 } // namespace model
181 } // namespace openstudio
182
183 #endif // MODEL_CURVEQUADLINEAR_HPP
184