private List<Item> setUniqueIDs(Item root) {
        List<Item> items = new ArrayList<>();
        collectTaggableItems(root, items);
        int id = 1;
        for (Item i : items) {
            TaggableItem t = (TaggableItem) i;
            t.setUniqueID(id++);
        }
        return items;
    }
Prepares this for binary serialization. For internal use.
container-search/src/main/java/com/yahoo/search/query/Model.java