void (final ProjectStructureElement element) { final List<ProjectStructureElementUsage> usages = ReadAction.compute(() -> { if (myStopped.get()) return null; if (LOG.isDebugEnabled()) { LOG.debug("collecting usages in " + element); } return getUsagesInElement(element); }); if (usages != null) { myResultsUpdateQueue.queue(new UsagesCollectedUpdate(element, usages)); } }