void (long start, @NonNls @NotNull String name, @Nullable Activity parent) { if (!isEnabled) { return; } long end = System.nanoTime(); long duration = end - start; if (duration <= MEASURE_THRESHOLD) { return; } ActivityImpl item = new ActivityImpl(name, start, /* parent = */ (ActivityImpl)parent, null, ActivityCategory.DEFAULT); item.setEnd(end); items.add(item); }