Expose OnRun to Rust
Change-Id: I2760992cbb98b3bf3b99c7246c4ac1557cf54a0f
Signed-off-by: Brian Silverman <bsilver16384@gmail.com>
diff --git a/aos/events/event_loop_runtime.cc b/aos/events/event_loop_runtime.cc
new file mode 100644
index 0000000..727d806
--- /dev/null
+++ b/aos/events/event_loop_runtime.cc
@@ -0,0 +1,11 @@
+#include "aos/events/event_loop_runtime.h"
+
+namespace aos {
+
+OnRunForRust::OnRunForRust(EventLoopRuntime *runtime) : runtime_(runtime) {
+ ++runtime->child_count_;
+}
+OnRunForRust::~OnRunForRust() { --runtime_->child_count_; }
+bool OnRunForRust::is_running() const { return runtime_->is_running(); }
+
+} // namespace aos