Class TimeoutManagerKt

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      final static Job startTimer(CoroutineScope coroutineScope, Long timeoutMillis, Function0<Unit> timeOutCallback) Starts a timer with the given timeoutMillis.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • startTimer

         final static Job startTimer(CoroutineScope coroutineScope, Long timeoutMillis, Function0<Unit> timeOutCallback)

        Starts a timer with the given timeoutMillis.

        Parameters:
        coroutineScope - The coroutine scope to run the timer in.
        timeoutMillis - The time in milliseconds for the timer.
        timeOutCallback - The lambda to invoke when the timer hits.
        Returns:

        The Job representing the timer, which can be canceled to stop the timer.