createRewardVideoExtraMap method

Map createRewardVideoExtraMap({
  1. String? userId,
  2. String? customData,
  3. Map? localParams,
  4. Map? customMap,
  5. bool openAutoLoadCallback = false,
  6. double maxWaitTime = 0,
})

构建ExtraMap:isAutoLoad 是否开启自动记载 默认开启, customMap 流量分组等自定义数据 userId customData 服务器奖励验证参数, 使用服务器奖励验证时 userId 必填

Implementation

Map createRewardVideoExtraMap({
  String? userId, //服务器奖励验证参数,如使用服务器奖励验证时此参数必填
  String? customData, //服务器奖励验证参数
  Map? localParams, //客户设置特殊参数数据
  Map? customMap, //流量分组Map
  bool openAutoLoadCallback = false,
  double maxWaitTime = 0,
}) {
  Map extraMap = {};
  if (localParams != null) {
    extraMap['localParams'] = localParams;
  }

  if (userId != null) {
    extraMap['userId'] = userId;
  }

  if (customData != null) {
    extraMap['customData'] = customData;
  }

  if (customMap != null) {
    extraMap['customMap'] = customMap;
  }
  extraMap['openAutoLoadCallback'] = openAutoLoadCallback;
  extraMap['maxWaitTime'] = maxWaitTime;
  return extraMap;
}