Skip to content

Instantly share code, notes, and snippets.

View itsusmon's full-sized avatar
:shipit:
Working on side projects.

Usmon Abdurakhmanov itsusmon

:shipit:
Working on side projects.
  • Mimsoft
  • Tashkent, Uzbekistan
  • 10:12 (UTC +05:00)
  • LinkedIn in/itsusmon
View GitHub Profile
/**
* Inspired by Jaewoong Eum's flow-operators library (https://github.com/skydoves/flow-operators).
*/
class Restartable {
private val restartFlow = MutableSharedFlow<SharingCommand>(extraBufferCapacity = 2)
fun restart() {
restartFlow.tryEmit(SharingCommand.STOP_AND_RESET_REPLAY_CACHE)