AdmostRewarded constructor

AdmostRewarded({
  1. required String zoneId,
  2. void listener(
    1. AdmostAdEvent,
    2. Map<String, dynamic>
    )?,
})

Implementation

AdmostRewarded({
  required this.zoneId,
  this.listener,
}) : super(listener) {
  if (zoneId == null) {
    print("zoneId cannot be null!");
  } else {
    id = hashCode;
    if (listener != null) {
      _adChannel = MethodChannel('admost_flutter/rewarded_$id');
      _adChannel.setMethodCallHandler(handleEvent);
    }
  }
}