Map<String,String> params = facesContext.getExternalContext().getRequestParameterMap();
String clientId = rating.getClientId(facesContext);
String rateValue = params.get(clientId + "_input");
if(rating.getRateListener() != null) {
RateEvent rateEvent;
if(isValueBlank(rateValue))
rateEvent = new RateEvent(rating, null);
else
rateEvent = new RateEvent(rating, Double.valueOf(rateValue));
if(rating.isImmediate())
rateEvent.setPhaseId(PhaseId.APPLY_REQUEST_VALUES);
else
rateEvent.setPhaseId(PhaseId.INVOKE_APPLICATION);
rating.queueEvent(rateEvent);
}
else {
rating.setSubmittedValue(rateValue);