<commit_before>package edu.teco.dnd.module.config;

import java.util.Collection;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.Queue;

/**
 * Does a depth first walk over a BlockTypeHolder.
 *
 * @author <NAME>
 */
class BlockTypeHolderIterator implements Iterator<BlockTypeHolder>, Iterable<BlockTypeHolder> {
	/**
	 * Queue for BlockTypeHolders that have not yet been visited.
	 */
	private final Queue<BlockTypeHolder> holders = new LinkedList<BlockTypeHolder>();
	
	/**
	 * Creates a new iterator with a given root.
	 * 
	 * @param root the root BlockTypeHolder
	 */
	public BlockTypeHolderIterator(final BlockTypeHolder root) {
		holders.add(root);
	}

	@Override
	public boolean hasNext() {
		return !holders.isEmpty();
	}

	@Override
	public BlockTypeHolder next() {
		final BlockTypeHolder next = holders.remove();
		final Collection<BlockTypeHolder> children = next.getChildren();
		if (children != null) {
			holders.addAll(children);
		}
		return next;
	}

	@Override
	public void remove() {
		throw new UnsupportedOperationException();
	}

	@Override
	public Iterator<BlockTypeHolder> iterator() {
		return this;
	}
}<commit_msg>Fix visibility of class<commit_after>package edu.teco.dnd.module.config;

import java.util.Collection;
import java.util.Iterator;
import java.util.LinkedList;
import java.util.Queue;

/**
 * Does a depth first walk over a BlockTypeHolder.
 *
 * @author <NAME>
 */
public class BlockTypeHolderIterator implements Iterator<BlockTypeHolder>, Iterable<BlockTypeHolder> {
	/**
	 * Queue for BlockTypeHolders that have not yet been visited.
	 */
	private final Queue<BlockTypeHolder> holders = new LinkedList<BlockTypeHolder>();
	
	/**
	 * Creates a new iterator with a given root.
	 * 
	 * @param root the root BlockTypeHolder
	 */
	public BlockTypeHolderIterator(final BlockTypeHolder root) {
		holders.add(root);
	}

	@Override
	public boolean hasNext() {
		return !holders.isEmpty();
	}

	@Override
	public BlockTypeHolder next() {
		final BlockTypeHolder next = holders.remove();
		final Collection<BlockTypeHolder> children = next.getChildren();
		if (children != null) {
			holders.addAll(children);
		}
		return next;
	}

	@Override
	public void remove() {
		throw new UnsupportedOperationException();
	}

	@Override
	public Iterator<BlockTypeHolder> iterator() {
		return this;
	}
}
{'fraction_non_alphanumeric': 0.10709732256693583, 'fraction_numerical': 0.0, 'mean_word_length': 4.436489607390301, 'pattern_counts': {'":': 0, '<': 17, '<?xml version=': 0, '>': 17, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2768126', 'n_tokens_mistral': 747, 'n_tokens_neox': 691, 'n_words': 194}