You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by mm...@apache.org on 2007/08/08 08:15:07 UTC

svn commit: r563762 - /myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java

Author: mmarinschek
Date: Tue Aug  7 23:15:06 2007
New Revision: 563762

URL: http://svn.apache.org/viewvc?view=rev&rev=563762
Log:
https://issues.apache.org/jira/browse/MYFACES-1685: more error-handling - making sure that all lifecycle methods throw a Faces-Exception including the component path so that the error-page has something to show off

Modified:
    myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java

Modified: myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java
URL: http://svn.apache.org/viewvc/myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java?view=diff&rev=563762&r1=563761&r2=563762
==============================================================================
--- myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java (original)
+++ myfaces/core/branches/1_2_1/api/src/main/java/javax/faces/component/UIComponentBase.java Tue Aug  7 23:15:06 2007
@@ -478,14 +478,20 @@
             throws AbortProcessingException
     {
         if (event == null) throw new NullPointerException("event");
-        if (_facesListeners == null) return;
-        for (Iterator<FacesListener> it = _facesListeners.iterator(); it.hasNext(); )
-        {
-            FacesListener facesListener = it.next();
-            if (event.isAppropriateListener(facesListener))
+        try {
+
+            if (_facesListeners == null) return;
+            for (Iterator<FacesListener> it = _facesListeners.iterator(); it.hasNext(); )
             {
-                event.processListener(facesListener);
+                FacesListener facesListener = it.next();
+                if (event.isAppropriateListener(facesListener))
+                {
+                    event.processListener(facesListener);
+                }
             }
+        }
+        catch(Exception ex) {
+            throw new FacesException("Exception while calling broadcast on component : "+getPathToComponent(this));
         }
     }