public static LayoutHierarchyDumper createWithOnly(
      List<HierarchyPlugin> hierarchyPlugins, List<AttributePlugin> attributePlugins) {
    final List<HierarchyPlugin> allHierarchyPlugins = new ArrayList<>(hierarchyPlugins.size());
    allHierarchyPlugins.addAll(hierarchyPlugins);

    final List<AttributePlugin> allAttributePlugins = new ArrayList<>(attributePlugins.size());
    allAttributePlugins.addAll(attributePlugins);

    return new LayoutHierarchyDumper(allHierarchyPlugins, allAttributePlugins);
  }
Dumps information about a layout hierarchy into a JSON object
core/src/main/java/com/facebook/testing/screenshot/layouthierarchy/LayoutHierarchyDumper.java