| 144 | *****************************************************************************************************************************************************/ |
| 145 | |
| 146 | bool mergeOutputTableSummaryReports(IdfObject& existingObject, const IdfObject& newObject) { |
| 147 | |
| 148 | bool added = false; |
| 149 | |
| 150 | // Merge |
| 151 | std::vector<std::string> reports; |
| 152 | { |
| 153 | auto existinEgs = existingObject.extensibleGroups(); |
| 154 | reports.reserve(existinEgs.size()); |
| 155 | std::transform(existinEgs.cbegin(), existinEgs.cend(), std::back_inserter(reports), [](const auto& eg) { return eg.getString(0).get(); }); |
| 156 | } |
| 157 | |
| 158 | std::vector<std::string> reportsToAdd; |
| 159 | { |
| 160 | auto newEgs = newObject.extensibleGroups(); |
| 161 | std::transform(newEgs.cbegin(), newEgs.cend(), std::back_inserter(reportsToAdd), [](const auto& eg) { return eg.getString(0).get(); }); |
| 162 | } |
| 163 | |
| 164 | for (const auto& newReport : reportsToAdd) { |
| 165 | if (std::find(reports.cbegin(), reports.cend(), newReport) == reports.cend()) { |
| 166 | existingObject.pushExtensibleGroup({newReport}); |
| 167 | added = true; |
| 168 | } |
| 169 | } |
| 170 | |
| 171 | return added; |
| 172 | } |
| 173 | |
| 174 | bool isEnergyPlusOutputRequestPotentiallyUnsafe(const IddObjectType& iddObjectType) { |
| 175 | std::string const valueName = iddObjectType.valueName(); |