1 Reply Latest reply on Jul 1, 2010 12:07 PM by jjamrich

    EventNavigationgResult cannot make the jsf page raise a navigation

    yongzhebisheng

      When i doing the portlet IPC with Events ,i can send and recevie the event,but the EventNavigationResult's Outcome return from the BridgeEventHander Class cannot cause a jsf page navigation,Why??can anyone tell me about that?thanks!

       

       

      1. The Receive Bean:

       

      public class EventReceivingBean implements BridgeEventHandler {

      private static Logger log = Logger.getLogger("EventReceivingBean");

      private EventNavigationResult envgr;


      public EventNavigationResult handleEvent(FacesContext context, Event event) {

        SimpleBean sb = ((SimpleEvent)event.getValue()).getEchoBean();
       
        navigation naviga=(navigation) context.getExternalContext().getSessionMap().get("Navigation");
       
        naviga.setDeliveredBean(sb);
       
        envgr=new EventNavigationResult("add","add");
       
        log.info(" outcomes = " + envgr.getOutcome());
       
        return envgr;
       
      }


      2, IN portlet.xml:

       

         <init-param>
         <name>javax.portlet.faces.bridgeEventHandler</name>
         <value>lee.abc.EventReceivingBean</value>
        </init-param>