MCPcopy Create free account
hub / github.com/VCVRack/Rack / hasModule

Method hasModule

src/engine/Engine.cpp:847–852  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

845
846
847bool Engine::hasModule(Module* module) {
848 SharedLock<SharedMutex> lock(internal->mutex);
849 // TODO Performance could be improved by searching modulesCache, but more testing would be needed to make sure it's always valid.
850 auto it = std::find(internal->modules.begin(), internal->modules.end(), module);
851 return it != internal->modules.end();
852}
853
854
855Module* Engine::getModule(int64_t moduleId) {

Callers

nothing calls this directly

Calls 1

findFunction · 0.85

Tested by

no test coverage detected