private @NotNull Promise<Void> rebuild(boolean refilterOnly) {
    Object selection = JBIterable.of(myTree.getSelectionPaths())
                                 .filterMap(o -> StructureViewComponent.unwrapValue(o.getLastPathComponent())).first();
    return rebuildAndSelect(refilterOnly, selection, null).then(o -> null);
  }
private @NotNull Promise<Void> rebuild(boolean refilterOnly)