isAutoTrackEventTypeIgnored static method

Future<bool> isAutoTrackEventTypeIgnored(
  1. SAAutoTrackType type
)

判断全埋点类型是否被忽略

Implementation

static Future<bool> isAutoTrackEventTypeIgnored(SAAutoTrackType type) async {
  int result = 0;
  switch (type) {
    case SAAutoTrackType.NONE:
      result = 0;
      break;
    case SAAutoTrackType.APP_START:
      result = 1;
      break;
    case SAAutoTrackType.APP_END:
      result = 1 << 1;
      break;
    case SAAutoTrackType.APP_CLICK:
      result = 1 << 2;
      break;
    case SAAutoTrackType.APP_VIEW_SCREEN:
      result = 1 << 3;
      break;
  }
  return await _channel.invokeMethod("isAutoTrackEventTypeIgnored", [result]);
}