class BazaarTagParser implements Executor.StreamHandler {

    /**
     * Store tag entries created by processStream.
     */
    private final NavigableSet<TagEntry> entries = new TreeSet<>();

    /**
     * Returns the set of entries that has been created.
     *
     * @return entries a set of tag entries
     */
    public NavigableSet<TagEntry> getEntries() {
        return entries;
    }

    @Override
    public void processStream(InputStream input) throws IOException {<FILL_FUNCTION_BODY>}
}

        try (BufferedReader in = new BufferedReader(new InputStreamReader(input))) {
            String line;
            while ((line = in.readLine()) != null) {
                String[] parts = line.split("  *");
                if (parts.length < 2) {
                    throw new IOException("Tag line contains more than 2 columns: " + line);
                }
                // Grrr, how to parse tags with spaces inside?
                // This solution will loose multiple spaces;-/
                var tag = String.join(" ", parts);
                TagEntry tagEntry = new BazaarTagEntry(Integer.parseInt(parts[parts.length - 1]), tag);
                // Bazaar lists multiple tags on more lines. We need to merge those into single TagEntry
                TagEntry higher = entries.ceiling(tagEntry);
                if (higher != null && higher.equals(tagEntry)) {
                    // Found in the tree, merge tags
                    entries.remove(higher);
                    tagEntry.setTags(higher.getTags() + TAGS_SEPARATOR + tag);
                }
                entries.add(tagEntry);
            }
        }
    
<no_super_class>