GCC Code Coverage Report


Directory: ./
Coverage: low: ≥ 0% medium: ≥ 75.0% high: ≥ 90.0%
Coverage Exec / Excl / Total
Lines: 85.7% 6 / 0 / 7
Functions: 100.0% 1 / 0 / 1
Branches: 85.7% 6 / 0 / 7

src/energyplus/ReverseTranslator/ReverseTranslateOutputEnvironmentalImpactFactors.cpp
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 #include "../ReverseTranslator.hpp"
7
8 #include "../../model/OutputEnvironmentalImpactFactors.hpp"
9
10 #include <utilities/idd/Output_EnvironmentalImpactFactors_FieldEnums.hxx>
11 #include <utilities/idd/IddEnums.hxx>
12
13 using namespace openstudio::model;
14
15 namespace openstudio {
16
17 namespace energyplus {
18
19 4 boost::optional<ModelObject> ReverseTranslator::translateOutputEnvironmentalImpactFactors(const WorkspaceObject& workspaceObject) {
20
21 // Reporting Frequency: Optional String
22
2/3
✓ Branch 1 taken 4 times.
✓ Branch 3 taken 4 times.
✗ Branch 4 not taken.
8 if (boost::optional<std::string> _reportingFrequency = workspaceObject.getString(Output_EnvironmentalImpactFactorsFields::ReportingFrequency)) {
23
1/1
✓ Branch 1 taken 4 times.
4 openstudio::model::OutputEnvironmentalImpactFactors modelObject(m_model);
24
2/2
✓ Branch 1 taken 4 times.
✓ Branch 4 taken 4 times.
4 modelObject.setReportingFrequency(_reportingFrequency.get());
25
1/1
✓ Branch 1 taken 4 times.
4 return modelObject;
26 8 }
27
28 ✗ return boost::none;
29 } // End of translate function
30
31 } // end namespace energyplus
32 } // end namespace openstudio
33