OnEvent
A callback for dispatching event data.
Implementations of OnEvent should not throw exception, be fast, and non-blocking.
NOTE: If OnEvent is being utilized with TorRuntime
APIs, exceptions will be treated as an UncaughtException and dispatched to RuntimeEvent.ERROR.