for(int i = 0; i < elementCount; i++) {
MenuElement element = menuElements.get(i);
if(element.isRendered() && element instanceof MenuItem) {
MenuItem item = (MenuItem) element;
//dont render chevron before home icon
if(i != 0) {
writer.startElement("li", null);
writer.writeAttribute("class", BreadCrumb.CHEVRON_CLASS, null);
writer.endElement("li");
}
writer.startElement("li", null);
writer.writeAttribute("role", "menuitem", null);
if(item.isDisabled())
encodeDisabledMenuItem(context, item);
else
encodeMenuItem(context, menu, item);
writer.endElement("li");