MCPcopy Create free account
hub / github.com/NatLabRockies/OpenStudio / getObjectsByReference

Method getObjectsByReference

src/utilities/idf/Workspace.cpp:383–394  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

381 }
382
383 std::vector<WorkspaceObject> Workspace_Impl::getObjectsByReference(const std::string& referenceName) const {
384 auto loc = m_idfReferencesMap.find(referenceName);
385 if (loc == m_idfReferencesMap.end()) {
386 return {};
387 }
388 std::vector<WorkspaceObject> result;
389 result.reserve(loc->second.size());
390 for (auto it = loc->second.begin(); it != loc->second.end(); ++it) {
391 result.push_back(it->second);
392 }
393 return result;
394 }
395
396 std::vector<WorkspaceObject> Workspace_Impl::getObjectsByReference(const std::vector<std::string>& referenceNames) const {
397 WorkspaceObjectMap objectMap;

Callers 5

TEST_FFunction · 0.80
TEST_FFunction · 0.80
TEST_FFunction · 0.80

Calls 6

beginMethod · 0.80
findMethod · 0.45
endMethod · 0.45
sizeMethod · 0.45
push_backMethod · 0.45
insertMethod · 0.45

Tested by 3

TEST_FFunction · 0.64
TEST_FFunction · 0.64
TEST_FFunction · 0.64