handleEvent method

Future handleEvent(
  1. MethodCall call
)

Implementation

Future<dynamic> handleEvent(MethodCall call) async {
  Map<String, dynamic> args = Map<String, dynamic>();
  if (call.arguments != null) {
      args = Map.from(call.arguments);
  }
  switch (call.method) {
    case 'loaded':
      _listener!(AdmostAdEvent.loaded, args);
      break;
    case 'opened':
      _listener!(AdmostAdEvent.opened, args);
      break;
    case 'failedToLoad':
      _listener!(AdmostAdEvent.failedToLoad, args);
      break;
    case 'failedToShow':
      _listener!(AdmostAdEvent.failedToShow, args);
      break;
    case 'clicked':
      _listener!(AdmostAdEvent.clicked, args);
      break;
    case 'dismissed':
      _listener!(AdmostAdEvent.dismissed, args);
      break;
    case 'completed':
      _listener!(AdmostAdEvent.completed, args);
      break;
    case 'statusChanged':
      _listener!(AdmostAdEvent.statusChanged, args);
      break;
  }

  return null;
}