public static void typeSelected(final @NotNull PsiType type, final @Nullable PsiType defaultType) {
    if (defaultType == null) return;
    ReadAction.nonBlocking(() -> DumbModeAccessType.RELIABLE_DATA_ONLY.ignoreDumbMode(() -> {
      return type.isValid() && defaultType.isValid() ? new StatisticsInfo(getStatsKey(defaultType), serialize(type)) : null;
    })).finishOnUiThread(ModalityState.nonModal(), stat -> {
      if (stat == null) return;
      StatisticsManager.getInstance().incUseCount(stat);
    }).submit(NonUrgentExecutor.getInstance());
  }
public static void typeSelected(final @NotNull PsiType type, final @Nullable PsiType defaultType)