create static method
Future<InterstitialAdLoader>
create({
- void onAdLoaded(
- InterstitialAd interstitialAd
- void onAdFailedToLoad(
- AdRequestError error
Implementation
static Future<InterstitialAdLoader> create({
void Function(InterstitialAd interstitialAd)? onAdLoaded,
void Function(AdRequestError error)? onAdFailedToLoad,
}) async {
int? id = await _createChannel.invokeMethod('interstitialAdLoader');
if (id == null) {
throw ArgumentError(
'something went wrong while creating interstitial ad loader');
}
return InterstitialAdLoader._(
id: id,
onAdLoaded: onAdLoaded,
onAdFailedToLoad: onAdFailedToLoad,
);
}