lpw
2 days ago 1e5242aa56dd1c52c537335ee56d7127d09b24de
WAAdmobImpl/GoogleMobileAds.xcframework/ios-arm64_x86_64-simulator/GoogleMobileAds.framework/Headers/GADRewardedAd.h
@@ -26,6 +26,7 @@
/// A rewarded ad. Rewarded ads are ads that users have the option of interacting with in exchange
/// for in-app rewards.
NS_SWIFT_NAME(RewardedAd)
@interface GADRewardedAd : NSObject <GADAdMetadataProvider, GADFullScreenPresentingAd>
/// The ad unit ID.
@@ -48,6 +49,10 @@
/// Called when the ad is estimated to have earned money. Available for allowlisted accounts only.
@property(nonatomic, nullable, copy) GADPaidEventHandler paidEventHandler;
/// An identifier for a placement in reporting. This property must be set prior to presenting the
/// ad.
@property(nonatomic, readwrite) int64_t placementID;
/// Loads a rewarded ad.
///
/// @param adUnitID An ad unit ID created in the AdMob or Ad Manager UI.
@@ -55,14 +60,29 @@
/// @param completionHandler A handler to execute when the load operation finishes or times out.
+ (void)loadWithAdUnitID:(nonnull NSString *)adUnitID
                 request:(nullable GADRequest *)request
       completionHandler:(nonnull GADRewardedAdLoadCompletionHandler)completionHandler;
       completionHandler:(nonnull GADRewardedAdLoadCompletionHandler)completionHandler
    NS_SWIFT_NAME(load(with:request:completionHandler:));
/// Returns whether the rewarded ad can be presented from the provided root view
/// controller. Sets the error out parameter if the ad can't be presented. Must be called on the
/// main thread. If rootViewController is nil, uses the top view controller of the application's
/// main window.
/// Loads a rewarded ad.
///
/// @param adResponseString A server-to-server ad response string.
/// @param completionHandler A handler to execute when the load operation finishes or times out.
+ (void)loadWithAdResponseString:(nonnull NSString *)adResponseString
               completionHandler:(nonnull GADRewardedAdLoadCompletionHandler)completionHandler
    NS_SWIFT_NAME(load(with:completionHandler:));
/// Indicates whether the rewarded ad can be presented from the provided root view controller. Must
/// be called on the main thread.
///
/// - Parameters:
///   - rootViewController: The root view controller to present the ad from. If `rootViewController`
/// is `nil`, uses the top view controller of the application's main window.
///   - error: Sets the error out parameter if the ad can't be presented.
/// - Returns: `YES` if the rewarded ad can be presented from the provided root view controller,
/// `NO` otherwise.
- (BOOL)canPresentFromRootViewController:(nullable UIViewController *)rootViewController
                                   error:(NSError *_Nullable __autoreleasing *_Nullable)error;
                                   error:(NSError *_Nullable __autoreleasing *_Nullable)error
    NS_SWIFT_NAME(canPresent(from:)) NS_SWIFT_UI_ACTOR;
/// Presents the rewarded ad. Must be called on the main thread.
///
@@ -70,6 +90,7 @@
/// the top view controller of the application's main window.
/// @param userDidEarnRewardHandler A handler to execute when the user earns a reward.
- (void)presentFromRootViewController:(nullable UIViewController *)rootViewController
             userDidEarnRewardHandler:(nonnull GADUserDidEarnRewardHandler)userDidEarnRewardHandler;
             userDidEarnRewardHandler:(nonnull GADUserDidEarnRewardHandler)userDidEarnRewardHandler
    NS_SWIFT_NAME(present(from:userDidEarnRewardHandler:)) NS_SWIFT_UI_ACTOR;
@end