for (IGridColumn column : columns) {
hide = renderOpenTag(column, i, columns.size(), response, hide);
if (column.isLightWeight(getDefaultModel())) {
// for lightweight columns get the renderable instance and render it
IRenderable renderable = column.newCell(getDefaultModel());
if (renderable == null) {
throw new IllegalStateException(
"Lightweight columns must return valid IRenderable instance in newCell(IModel model)");
}
response.write("<div class=\"");
response.write(getInnerDivClass(column));
response.write("\">");
renderable.render(getDefaultModel(), response);
response.write("</div>");
} else {
// for non-lightweight components get the actual component and render it
Component component = get(column.getId());
if (component == null) {