MCPcopy Create free account
hub / github.com/colmap/colmap / AddCallback

Method AddCallback

src/colmap/util/base_controller.cc:38–42  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

36BaseController::BaseController() {}
37
38void BaseController::AddCallback(const int id, std::function<void()> func) {
39 CHECK(func);
40 CHECK_GT(callbacks_.count(id), 0) << "Callback not registered";
41 callbacks_.at(id).push_back(std::move(func));
42}
43
44void BaseController::RegisterCallback(const int id) {
45 callbacks_.emplace(id, std::list<std::function<void()>>());

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected