Class WinLossBeaconHandlerKt
-
- All Implemented Interfaces:
public final class WinLossBeaconHandlerKt
-
-
Method Summary
Modifier and Type Method Description final static StringnotifyWin(AdComponent adComponent, Double minBidToWin)Notify that the bid for this ad was won. final static StringnotifyLoss(AdComponent adComponent, Integer lossReason, Double auctionPrice)Notify that the bid for this ad was lost. -
-
Method Detail
-
notifyWin
final static String notifyWin(AdComponent adComponent, Double minBidToWin)
Notify that the bid for this ad was won.
This top-level function:
Ensures it's called only once per AdComponent via atomic flag
Retrieves WIN_BEACON trackers from the AdComponent's AdContext
Replaces auction macros with actual values
Fires beacons via ClickManager
Validates parameters
- Parameters:
adComponent- The AdComponent containing the ad context and loggerminBidToWin- The minimum bid amount required to win the auction- Returns:
An error message string if the notification failed, null if successful
-
notifyLoss
final static String notifyLoss(AdComponent adComponent, Integer lossReason, Double auctionPrice)
Notify that the bid for this ad was lost.
This top-level function:
Ensures it's called only once per AdComponent via atomic flag
Retrieves LOSS_BEACON trackers from the AdComponent's AdContext
Replaces auction macros with actual values
Fires beacons via ClickManager
Validates parameters
- Parameters:
adComponent- The AdComponent containing the ad context and loggerlossReason- The reason code for losing the auctionauctionPrice- The price of the winning bid in the auction- Returns:
An error message string if the notification failed, null if successful
-
-
-
-