private static @NotNull Stream<@NotNull Usage> selectedUsages(@NotNull List<@NotNull TreeNode> selectedNodes) {
    return selectedNodes.stream()
      .filter(node -> node instanceof UsageNode)
      .map(node -> ((UsageNode)node).getUsage())
      .distinct();
  }
private static @NotNull Stream<@NotNull Usage> selectedUsages(@NotNull List<@NotNull TreeNode> selectedNodes)