20 public class ButtonRenderer extends Renderer {
……
26 public void decode(FacesContext context, UIComponent component) {
27 if ((context == null) || (component == null)) {
28 throw new NullPointerException();
29 }
30 ButtonComponent button = (ButtonComponent) component;
31 String clientId = button.getClientId(context);
32 Map requestParameterMap =
33 (Map)context.getExternalContext().getRequestParameterMap();
34 if (!requestParameterMap.containsKey("id")) return;
35 String id = (String)requestParameterMap.get("id");
36 if (id.equals(clientId)) {
37 button.queueEvent(new ActionEvent(button));
38 }
39 }
40
……