exposed function runLoopOnce.