05nelsonm / kmp-tor

Kotlin Multiplatform Library for embedding Tor into your applications
Apache License 2.0
33 stars 5 forks source link

Add scoped observers #451

Open 05nelsonm opened 3 months ago

05nelsonm commented 3 months ago

If library consumer is using coroutines, there should be an API for creating an Event.Observer that leverages the use of CoroutineScope to create its own OnEvent.Executor, as well as unsubscribe itself from any Processor via CoroutineScope.invokeOnCompletion handler.