for (Iterator<String> i = bugCatSet.iterator(); i.hasNext();) { String bugCat = i.next();
for (String bugCat : bugCatSet) {
	private void writeBugCategories() throws IOException {		// Find bug categories reported		Set<String> bugCatSet = new HashSet<String>();		for (Iterator<BugInstance> i = getBugCollection().iterator(); i.hasNext();) {			BugInstance bugInstance = i.next();			BugPattern bugPattern = bugInstance.getBugPattern();			if (bugPattern != null) {				bugCatSet.add(bugPattern.getCategory());			}		}		// Emit element describing each reported bug code		for (Iterator<String> i = bugCatSet.iterator(); i.hasNext();) {			String bugCat = i.next();			String bugCatDescription = I18N.instance().getBugCategoryDescription(bugCat);			if (bugCatDescription == null)				continue;			XMLAttributeList attributeList = new XMLAttributeList();			attributeList.addAttribute("category", bugCat);			xmlOutput.openTag("BugCategory", attributeList);			xmlOutput.openTag("Description");			xmlOutput.writeText(bugCatDescription);			xmlOutput.closeTag("Description");			xmlOutput.closeTag("BugCategory");		}	}