GCC Code Coverage Report


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

src/model/LoadProfilePlant.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_LOADPROFILEPLANT_HPP
7 #define MODEL_LOADPROFILEPLANT_HPP
8
9 #include "ModelAPI.hpp"
10 #include "StraightComponent.hpp"
11
12 namespace openstudio {
13
14 namespace model {
15
16 class Schedule;
17
18 namespace detail {
19
20 class LoadProfilePlant_Impl;
21
22 } // namespace detail
23
24 /** LoadProfilePlant is a StraightComponent that wraps the OpenStudio IDD object 'OS:LoadProfile:Plant'. */
25 class MODEL_API LoadProfilePlant : public StraightComponent
26 {
27 public:
28 /** @name Constructors and Destructors */
29 //@{
30
31 explicit LoadProfilePlant(const Model& model);
32
33 explicit LoadProfilePlant(const Model& model, Schedule& loadSchedule, Schedule& flowRateFractionSchedule);
34
35 2 virtual ~LoadProfilePlant() override = default;
36 // Default the copy and move operators because the virtual dtor is explicit
37 ✗ LoadProfilePlant(const LoadProfilePlant& other) = default;
38 ✗ LoadProfilePlant(LoadProfilePlant&& other) = default;
39 ✗ LoadProfilePlant& operator=(const LoadProfilePlant&) = default;
40 ✗ LoadProfilePlant& operator=(LoadProfilePlant&&) = default;
41
42 //@}
43
44 static IddObjectType iddObjectType();
45
46 /** @name Getters */
47 //@{
48
49 Schedule loadSchedule() const;
50
51 double peakFlowRate() const;
52
53 Schedule flowRateFractionSchedule() const;
54
55 std::string plantLoopFluidType() const;
56
57 double degreeofSubCooling() const;
58
59 double degreeofLoopSubCooling() const;
60
61 //@}
62 /** @name Setters */
63 //@{
64
65 bool setLoadSchedule(Schedule& schedule);
66
67 bool setPeakFlowRate(double peakFlowRate);
68
69 bool setFlowRateFractionSchedule(Schedule& schedule);
70
71 bool setPlantLoopFluidType(const std::string& plantLoopFluidType);
72
73 bool setDegreeofSubCooling(double degreeofSubCooling);
74
75 bool setDegreeofLoopSubCooling(double degreeofLoopSubCooling);
76
77 //@}
78 /** @name Other */
79 //@{
80
81 //@}
82 protected:
83 /// @cond
84 using ImplType = detail::LoadProfilePlant_Impl;
85
86 explicit LoadProfilePlant(std::shared_ptr<detail::LoadProfilePlant_Impl> impl);
87
88 friend class detail::LoadProfilePlant_Impl;
89 friend class Model;
90 friend class IdfObject;
91 friend class openstudio::detail::IdfObject_Impl;
92 /// @endcond
93 private:
94 REGISTER_LOGGER("openstudio.model.LoadProfilePlant");
95 };
96
97 /** \relates LoadProfilePlant*/
98 using OptionalLoadProfilePlant = boost::optional<LoadProfilePlant>;
99
100 /** \relates LoadProfilePlant*/
101 using LoadProfilePlantVector = std::vector<LoadProfilePlant>;
102
103 } // namespace model
104 } // namespace openstudio
105
106 #endif // MODEL_LOADPROFILEPLANT_HPP
107