Interface AUDestroyListener

  • All Implemented Interfaces:

    
    public interface AUDestroyListener
    
                        

    Listener interface for receiving ad unit destruction notifications.

    This interface provides a callback mechanism for handling ad unit cleanup and resource deallocation. Implementers should use this event to perform necessary cleanup operations, release resources, cancel ongoing operations, and ensure proper memory management during ad unit destruction.

    • 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
      abstract Unit onDestroy() Called when an ad unit is being destroyed and requires cleanup.
      • Methods inherited from class java.lang.Object

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

    • Method Detail

      • onDestroy

         abstract Unit onDestroy()

        Called when an ad unit is being destroyed and requires cleanup.

        This method is invoked when the ad unit lifecycle is ending and all associated resources should be released. The method is suspending to allow for asynchronous cleanup operations such as cancelling coroutines, releasing network connections, or performing database cleanup. Implementers should ensure all resources are properly cleaned up to prevent memory leaks.