| 265 | } |
| 266 | |
| 267 | std::vector<std::string> IddObject_Impl::references() const { |
| 268 | std::vector<std::string> result; |
| 269 | if (OptionalUnsigned index = nameFieldIndex()) { |
| 270 | result = m_fields[*index].properties().references; |
| 271 | // To ensure uniqueness of name within a given class, we add a fake reference by class |
| 272 | // https://github.com/NREL/OpenStudio/issues/3079 |
| 273 | //if (result.empty()) { |
| 274 | std::string ref = name(); |
| 275 | result.push_back(ref + "UniqueNames"); |
| 276 | //} |
| 277 | } else { |
| 278 | std::string n = name(); |
| 279 | if (n == "OS:PortList") { |
| 280 | result.push_back("ConnectionObject"); |
| 281 | result.push_back("PortLists"); |
| 282 | } else if (n == "OS:Connection") { |
| 283 | result.push_back("ConnectionNames"); |
| 284 | } |
| 285 | } |
| 286 | |
| 287 | return result; |
| 288 | } |
| 289 | |
| 290 | std::set<std::string> IddObject_Impl::objectLists() const { |
| 291 | std::set<std::string> result; |