Package javax.faces.event

Examples of javax.faces.event.ActionListener


   public void broadcast(FacesEvent event) throws AbortProcessingException {
       // Perform standard superclass processing
       super.broadcast(event);
       if (event instanceof ActionEvent) {         
           // Invoke the default ActionListener
           ActionListener listener =
             getFacesContext().getApplication().getActionListener();
           if (listener != null) {
               listener.processAction((ActionEvent) event);
           }
       }
   }
View Full Code Here


    * <p>Return the set of registered {@link ActionListener}s for this
    * {@link ActionSource} instance.  If there are no registered listeners,
    * a zero-length array is returned.</p>
    */
   public ActionListener[] getActionListeners() {
       ActionListener al[] = (ActionListener [])
      getFacesListeners(ActionListener.class);
       return (al);
   }
View Full Code Here

   public void broadcast(FacesEvent event) throws AbortProcessingException {
       // Perform standard superclass processing
       super.broadcast(event);
       if (event instanceof ActionEvent) {         
           // Invoke the default ActionListener
           ActionListener listener =
             getFacesContext().getApplication().getActionListener();
           if (listener != null) {
               listener.processAction((ActionEvent) event);
           }
       }
   }
View Full Code Here

    * <p>Return the set of registered {@link ActionListener}s for this
    * {@link ActionSource} instance.  If there are no registered listeners,
    * a zero-length array is returned.</p>
    */
   public ActionListener[] getActionListeners() {
       ActionListener al[] = (ActionListener [])
      getFacesListeners(ActionListener.class);
       return (al);
   }
View Full Code Here

   public void broadcast(FacesEvent event) throws AbortProcessingException {
       // Perform standard superclass processing
       super.broadcast(event);
       if (event instanceof ActionEvent) {         
           // Invoke the default ActionListener
           ActionListener listener =
             getFacesContext().getApplication().getActionListener();
           if (listener != null) {
               listener.processAction((ActionEvent) event);
           }
       }
   }
View Full Code Here

    * <p>Return the set of registered {@link ActionListener}s for this
    * {@link ActionSource} instance.  If there are no registered listeners,
    * a zero-length array is returned.</p>
    */
   public ActionListener[] getActionListeners() {
       ActionListener al[] = (ActionListener [])
      getFacesListeners(ActionListener.class);
       return (al);
   }
View Full Code Here

   public void broadcast(FacesEvent event) throws AbortProcessingException {
       // Perform standard superclass processing
       super.broadcast(event);
       if (event instanceof ActionEvent) {         
           // Invoke the default ActionListener
           ActionListener listener =
             getFacesContext().getApplication().getActionListener();
           if (listener != null) {
               listener.processAction((ActionEvent) event);
           }
       }
   }
View Full Code Here

            {
                mb.invoke(context, new Object[]
                { event });
            }

            ActionListener defaultActionListener = context.getApplication()
                    .getActionListener();
            if (defaultActionListener != null)
            {
                defaultActionListener.processAction((ActionEvent) event);
            }
        }
    }
View Full Code Here

        this.type = type;
        this.binding = binding;
    }

    public void processAction(ActionEvent event) throws AbortProcessingException {
        ActionListener instance = null;
        FacesContext faces = FacesContext.getCurrentInstance();
        if (faces == null) {
            return;
        }

        if (this.binding != null) {
            instance = (ActionListener) binding.getValue(faces.getELContext());
        }

        if (instance == null && this.type != null) {
            try {
                instance = TagHandlerUtils.loadClass(this.type, ActionListener.class).newInstance();
            } catch (Exception e) {
                throw new AbortProcessingException("Couldn't lazily instantiate ActionListener", e);
            }

            if (this.binding != null) {
                binding.setValue(faces.getELContext(), instance);
            }
        }

        if (instance != null) {
            instance.processAction(event);
        }
    }
View Full Code Here

        } else {
            ValueExpression b = null;
            if (this.binding != null) {
                b = this.binding.getValueExpression(ctx, ActionListener.class);
            }
            ActionListener listener = new LazyActionListener(this.listenerType, b);
            as.addActionListener(listener);
        }
    }
View Full Code Here

TOP

Related Classes of javax.faces.event.ActionListener

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.