Class VisibilityTrackerImpl

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      StateFlow<VisibilityStatus> startTracking() Starts tracking the visibility of the view.
      Unit pause() Pauses the visibility tracking and sets the trackedFlow to VisibilityStatus.HIDDEN.
      abstract Unit onVisibilityCheck() Abstract method to be implemented by subclasses to perform the actual visibility check.
      • Methods inherited from class com.inmobi.media.ads.common.visibility.tracker.VisibilityTracker

        resume, stop
      • Methods inherited from class java.lang.Object

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

      • onVisibilityCheck

         abstract Unit onVisibilityCheck()

        Abstract method to be implemented by subclasses to perform the actual visibility check.

        This method is called when tracking starts and should contain the logic to periodically check the visibility of the view.