@Override
public void setComponentProperties(FacesContext context, UIComponent component) {
super.setComponentProperties(context, component);
Columns columns = (Columns) component;
setValueExpressionProperty(component, "value");
setStringProperty(component, "var", false, true);
setStringProperty(component, "indexVar");
setValueExpressionProperty(component, "headerValue", getPropertyValue("header"), "header");
setValueExpressionProperty(component, "footerValue", getPropertyValue("footer"), "footer");
setValueExpressionProperty(component, "columnValue");
setConverterProperty(component, "converter");
setValueExpressionProperty(component, "columnId");
setBooleanProperty(component, "columnRendered");
setBooleanProperty(component, "sortingEnabled");
setValueExpressionProperty(component, "sortingExpression");
setValueExpressionProperty(component, "groupingExpression");
String sortingComparator = getPropertyValue("sortingComparator");
if (sortingComparator != null) {
ValueExpression comparatorExpression;
if (!isValueReference(sortingComparator)) {
if (ColumnTag.CASE_INSENSITIVE_TEXT_COMPARATOR.equals(sortingComparator))
comparatorExpression = new ColumnTag.CaseInsensitiveComparatorBinding();
else
throw new IllegalArgumentException("sortingComparator attribute should either be defined as binding or as \"" + ColumnTag.CASE_INSENSITIVE_TEXT_COMPARATOR + "\", but it is defined as follows: " + sortingComparator);
} else {
comparatorExpression = createValueExpression(context, "sortingComparator", sortingComparator);
}
columns.setValueExpression("sortingComparator", comparatorExpression);
}
setStringProperty(component, "width");
setStringProperty(component, "align");
setStringProperty(component, "valign");