Registers a cleanup function to be called upon object destruction. Registered functions are invoked in the reserve order of registration.
| 599 | // |
| 600 | // Registered functions are invoked in the reserve order of registration. |
| 601 | void AddCleanupFunction(std::function<void()>&& cleanup_fn) { |
| 602 | cleanup_fns_.push_back(std::move(cleanup_fn)); |
| 603 | } |
| 604 | |
| 605 | // Associates the given performance modeling `Node` with this iterator. |
| 606 | void SetNode(std::shared_ptr<model::Node> node) { node_ = node.get(); } |