setIOSBadgeNum method

  1. @override
Future<Map> setIOSBadgeNum(
  1. int num
)
override

iOS 设置角标数

Implementation

@override
Future<Map<dynamic, dynamic>> setIOSBadgeNum(int num) async {
  if (!Platform.isIOS) {
    return {
      'code': kAliyunPushOnlyIOS,
      'errorMsg': 'Only support iOS',
    };
  }

  Map<dynamic, dynamic> result =
      await methodChannel.invokeMethod('setBadgeNum', {'badgeNum': num});
  return result;
}