| 971 | } |
| 972 | |
| 973 | boost::optional<double> SqlFile_Impl::netSourceEnergy() const { |
| 974 | boost::optional<double> hours = hoursSimulated(); |
| 975 | if (!hours) { |
| 976 | LOG(Warn, "Reporting Net Source Energy with unknown number of simulation hours"); |
| 977 | } else if (*hours != 8760) { |
| 978 | LOG(Warn, "Reporting Net Source Energy with " << *hours << " hrs"); |
| 979 | } |
| 980 | |
| 981 | const std::string& s = R"(SELECT Value FROM TabularDataWithStrings |
| 982 | WHERE ReportName='AnnualBuildingUtilityPerformanceSummary' |
| 983 | AND ReportForString='Entire Facility' |
| 984 | AND TableName='Site and Source Energy' |
| 985 | AND RowName='Net Source Energy' |
| 986 | AND ColumnName='Total Energy' |
| 987 | AND Units='GJ')"; |
| 988 | return execAndReturnFirstDouble(s); |
| 989 | } |
| 990 | |
| 991 | boost::optional<double> SqlFile_Impl::totalSiteEnergy() const { |
| 992 | boost::optional<double> hours = hoursSimulated(); |
nothing calls this directly
no test coverage detected