setBannerExtraParameter static method

void setBannerExtraParameter({
  1. required String adUnitId,
  2. required String key,
  3. required Object? value,
})

Attaches an extra parameter to every future banner load for adUnitId.

The native ad keeps the value until the same key is set again or cleared, so it applies to later loads and auto-refresh auctions too, not only the next one. Pass a null value to clear the key. Values are read when a load runs, so set them before the load. A value may be null, a bool, an int, a double, a String, or a list or map of those.

Implementation

static void setBannerExtraParameter({
  required String adUnitId,
  required String key,
  required Object? value,
}) {
  _methodChannel.invokeMethod('setBannerExtraParameter', {
    'adUnitId': adUnitId,
    'key': key,
    'value': value,
  });
}