protected void encodeHtmlDataTableChildren(FacesContext context, HtmlDataTable htmlDataTable) throws IOException { ResponseWriter writer = context.getResponseWriter(); writer.startElement(JsfConstants.TBODY_ELEM, htmlDataTable); LoopIterator rowClasses = toStyleLoopIterator(htmlDataTable .getRowClasses()); LoopIterator columnClasses = toStyleLoopIterator(htmlDataTable .getColumnClasses()); int start = htmlDataTable.getFirst(); int rows = htmlDataTable.getRows(); boolean allRow = true; if (0 < rows) { allRow = false; } htmlDataTable.setRowIndex(start); for (int rowIndex = start; ((allRow || 0 < rows) && htmlDataTable .isRowAvailable());) { encodeBodyRow(context, htmlDataTable, writer, rowClasses, columnClasses); rowIndex++; rows--; htmlDataTable.setRowIndex(rowIndex); } writer.endElement(JsfConstants.TBODY_ELEM); }