initSDK static method

void initSDK(
  1. String appId,
  2. String url,
  3. String channel,
  4. bool isDebug,
  5. int logLevel, {
  6. JsonMap commonProperties = const {},
})

Implementation

static void initSDK(
    String appId,
    String url,
    String channel,
    bool isDebug,
    int logLevel,
    { JsonMap commonProperties = const {} }
) {
  var typeSuffix = "";
  if (Platform.isIOS) {
    typeSuffix = "-iOS";
  } else if (Platform.isAndroid) {
    typeSuffix = "-Android";
  }

  DTPigeon().initSDK(appId, url, channel, isDebug, logLevel, {
    ...commonProperties,
    "#sdk_type": "Flutter$typeSuffix",
    "#sdk_version_name": _versionName,
  });
}