FullscreenAdsDelegate

public protocol FullscreenAdsDelegate : AnyObject

Defines all fullscreen-related ad events.

Note

This protocol inherits from AnyObject so that the implementing objects are able to be referenced weakly.

  • didLoad(placementId:result:) Default implementation

    Notifies when an ad was loaded successfully.

    Default Implementation

    Declaration

    Swift

    func didLoad(placementId: String, result: LoadResult)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

    result

    A LoadResult object describing the result of a load call.

  • Notifies when an ad was presented to the user.

    Declaration

    Swift

    func didPresent(placementId: String)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

  • Notifies when an ad failed to be presented.

    Note

    You don’t need to reload an ad that failed to present, as this is handled automatically by the sdk.

    Declaration

    Swift

    func failedToPresent(placementId: String, error: PresentError)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

    error

    A PresentError object describing the error.

  • willDismiss(placementId:) Default implementation

    Notifies when an ad is about to be dismissed.

    Default Implementation

    Declaration

    Swift

    func willDismiss(placementId: String)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

  • Notifies when an ad was dismissed.

    Note

    You don’t need to reload an ad that was dismissed, as this is handled automatically by the sdk.

    Declaration

    Swift

    func didDismiss(placementId: String)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

  • didClick(placementId:) Default implementation

    Notifies when an ad was clicked.

    Default Implementation

    Declaration

    Swift

    func didClick(placementId: String)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

  • Notifies when an ad impression was recorded, returning an ImpressionData object.

    Declaration

    Swift

    func didRecordImpression(placementId: String, data: ImpressionData)

    Parameters

    placementId

    the placement id of the ad that triggered the event.

    data

    An ImpressionData object describing an ad impression.