protected void encodeIdIcon(ResponseWriter writer, FacesContext context, String attrIconValue, String styleClass,
PanelIcons.State state) throws IOException {
if (attrIconValue == null || attrIconValue.trim().length() <= 0) {
encodeDivIcon(writer, PanelIcons.none, styleClass, state);
} else {
PanelIcons icon = PanelIcons.getIcon(attrIconValue);
if (icon != null) {
encodeDivIcon(writer, icon, styleClass, state);
} else {
encodeImage(writer, context, attrIconValue, styleClass);
}