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 2005/12/29 14:14:43 UTC

svn commit: r359781 - /myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java

Author: mmarinschek
Date: Thu Dec 29 05:14:37 2005
New Revision: 359781

URL: http://svn.apache.org/viewcvs?rev=359781&view=rev
Log:
changing comments - getting out reset of uniqueIdCounter at beginning of encodebegin

Modified:
    myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java

Modified: myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java
URL: http://svn.apache.org/viewcvs/myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java?rev=359781&r1=359780&r2=359781&view=diff
==============================================================================
--- myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java (original)
+++ myfaces/api/trunk/src/java/javax/faces/component/UIViewRoot.java Thu Dec 29 05:14:37 2005
@@ -46,11 +46,6 @@
      * The counter which will ensure a unique component id
      * for every component instance in the tree that doesn't have
      * an id attribute set.
-     * <br/>
-     * Attention: it is not allowed to save this uniqueIdCounter
-     * between requests, as having the same counter value on
-     * every request is the only way for the JSP/JSF bridge
-     * to assign tags to their corresponding components.
      */
     private long _uniqueIdCounter = 0;
 
@@ -181,24 +176,12 @@
     public void encodeBegin(FacesContext context)
             throws java.io.IOException
     {
-        _uniqueIdCounter = 0;
         clearEvents();
         super.encodeBegin(context);
     }
 
     /* Provides a unique id for this component instance.
-     * Don't ever use this method for dynamically generated
-     * component instances - this is really only for
-     * providing a unique id to component instances that use
-     * the JSP/JSF bridge.
-     * This also means that you should make sure that
-     * getClientId() is not called on automatically generated
-     * components cause getClientId() calls this
-     * method if no id has been set. If you can't ensure this,
-     * set ids on all dynamically generated component instances.
-     * <br />
-     * This restriction might change with JSF 1.2.
-     */
+    */
     public String createUniqueId()
     {
         ExternalContext extCtx = FacesContext.getCurrentInstance().getExternalContext();