if (c != null) {
// Make sure the component supports 1.2
if (FacesAPI.getComponentVersion(c) >= 12) {
c.setValueExpression("binding", ve);
} else {
ValueBinding vb = new LegacyValueBinding(ve);
c.setValueBinding("binding", vb);
}
}
} else {
ValueBinding vb = new LegacyValueBinding(ve);
c = app.createComponent(vb, faces, this.componentType);
if (c != null) {
c.setValueBinding("binding", vb);
}
}