myfaces-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From gcrawf...@apache.org
Subject svn commit: r955027 - in /myfaces/trinidad/branches/1.2.12.3-branch: trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java
Date Tue, 15 Jun 2010 19:56:09 GMT
Author: gcrawford
Date: Tue Jun 15 19:56:09 2010
New Revision: 955027

URL: http://svn.apache.org/viewvc?rev=955027&view=rev
Log:
TRINIDAD-1829 - create a public api for zipping the page state

The current name of the param is
org.apache.myfaces.trinidadinternal.COMPRESS_VIEW_STATE

The proposed name of the param is
org.apache.myfaces.trinidad.COMPRESS_VIEW_STATE 

Modified:
    myfaces/trinidad/branches/1.2.12.3-branch/trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts
    myfaces/trinidad/branches/1.2.12.3-branch/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java

Modified: myfaces/trinidad/branches/1.2.12.3-branch/trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts
URL: http://svn.apache.org/viewvc/myfaces/trinidad/branches/1.2.12.3-branch/trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts?rev=955027&r1=955026&r2=955027&view=diff
==============================================================================
--- myfaces/trinidad/branches/1.2.12.3-branch/trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts
(original)
+++ myfaces/trinidad/branches/1.2.12.3-branch/trinidad-api/src/main/xrts/org/apache/myfaces/trinidad/resource/LoggerBundle.xrts
Tue Jun 15 19:56:09 2010
@@ -454,7 +454,7 @@
 <resource key="COMPARETO_TYPE_MISMATCH">The type for "{0}" prevents it from being compared
to "{1}".</resource>
 
 <!-- ZIP_STATE_FAILED -->
-<resource key="ZIP_STATE_FAILED">Failed to zip the page state. The state must be serializable
to be zipped, so a common reason the page state fails to zip is that the page state is not
serializable.  You can turn off zipping by setting org.apache.myfaces.trinidadinternal.COMPRESS_VIEW_STATE
to false. See the doc about system property org.apache.myfaces.trinidad.CHECK_STATE_SERIALIZATION
for how to test various aspects of serialization.</resource>
+<resource key="ZIP_STATE_FAILED">Failed to zip the page state. The state must be serializable
to be zipped, so a common reason the page state fails to zip is that the page state is not
serializable.  You can turn off zipping by setting org.apache.myfaces.trinidad.COMPRESS_VIEW_STATE
to false. See the doc about system property org.apache.myfaces.trinidad.CHECK_STATE_SERIALIZATION
for how to test various aspects of serialization.</resource>
 
 <!-- UNZIP_STATE_FAILED -->
 <resource key="UNZIP_STATE_FAILED">Failed to unzip the page state.</resource>

Modified: myfaces/trinidad/branches/1.2.12.3-branch/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java
URL: http://svn.apache.org/viewvc/myfaces/trinidad/branches/1.2.12.3-branch/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java?rev=955027&r1=955026&r2=955027&view=diff
==============================================================================
--- myfaces/trinidad/branches/1.2.12.3-branch/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java
(original)
+++ myfaces/trinidad/branches/1.2.12.3-branch/trinidad-impl/src/main/java/org/apache/myfaces/trinidadinternal/application/StateManagerImpl.java
Tue Jun 15 19:56:09 2010
@@ -127,7 +127,7 @@ public class StateManagerImpl extends St
      * Valid values are true and false
      */
     static public final String COMPRESS_VIEW_STATE_PARAM_NAME =
-      "org.apache.myfaces.trinidadinternal.COMPRESS_VIEW_STATE";
+      "org.apache.myfaces.trinidad.COMPRESS_VIEW_STATE";
 
 
   /**
@@ -345,9 +345,9 @@ public class StateManagerImpl extends St
             // Save the view root into the page state as a transient
             // if this feature has not been disabled
             _useViewRootCache(context) ? root : null);
-        
+
         String requestToken = _getRequestTokenForResponse(context);
-        
+
         // If we have a cached token that we want to reuse,
         // and that token hasn't disappeared from the cache already
         // (unlikely, but not impossible), use the stateMap directly
@@ -385,15 +385,15 @@ public class StateManagerImpl extends St
           // See Trinidad-1779
           String activePageStateKey = _getActivePageTokenKey(extContext, trinContext);
           String activeToken = (String)sessionMap.get(activePageStateKey);
-          
+
           // we only need to clear out the state if we're actually changing pages and thus
tokens.
-          // Since we have already updated the state for 
+          // Since we have already updated the state for
           if (!token.equals(activeToken))
           {
             if (activeToken != null)
             {
               PageState activePageState = stateMap.get(activeToken);
-        
+
               if (activePageState != null)
                 activePageState.clearViewRootState();
             }
@@ -709,12 +709,12 @@ public class StateManagerImpl extends St
    * The given parameter (<code>perViewStateSaving</code>) indicates
    * if we need to enable client- OR server-side state-saving
    * for the current VIEW.
-   * 
+   *
    * <p>
    * <b>This is an internal method, that is ONLY called by the
    * Trinidad Document</b>
    * </p>
-   * 
+   *
    * @param perViewStateSaving <code>default</code>, <code>server</code>
or <code>client</code> for stateSaving
    */
   public void setPerViewStateSaving(String perViewStateSaving)
@@ -908,7 +908,7 @@ public class StateManagerImpl extends St
 
     ExternalContext external = context.getExternalContext();
     Object stateSavingMethod =
-      external.getInitParameterMap().get(StateManager.STATE_SAVING_METHOD_PARAM_NAME);  
 
+      external.getInitParameterMap().get(StateManager.STATE_SAVING_METHOD_PARAM_NAME);
 
     // on "SERVER" state-saving we return TRUE, since we want send down a token string.
     if ((stateSavingMethod == null) ||
@@ -927,7 +927,7 @@ public class StateManagerImpl extends St
       return false;
     }
 
-    // if the user has used the <document> 'stateSaving' attribute to specify 
+    // if the user has used the <document> 'stateSaving' attribute to specify
     // client, we force the state mananger (see above) to render the entire
     // state on the client. The indicator is stashed on the FacesContext and
     // is therefore NOT visible during "restoreView" phase. So if we reach this point
@@ -1514,7 +1514,7 @@ public class StateManagerImpl extends St
   }
 
   /**
-   * Static ENUM to capture the values of the <document>'s 
+   * Static ENUM to capture the values of the <document>'s
    * 'stateSaving' attribute
    */
   static private enum StateSaving
@@ -1550,7 +1550,7 @@ public class StateManagerImpl extends St
     "org.apache.myfaces.trinidadinternal.application.APPLICATION_VIEW_CACHE";
 
   // key to stash the per_page_state_saving during rendering
-  private static final String _PER_PAGE_STATE_SAVING = 
+  private static final String _PER_PAGE_STATE_SAVING =
     "org.apache.myfaces.trinidadimpl.PER_PAGE_STATE_SAVING";
 
   private static final String _CACHED_SERIALIZED_VIEW =



Mime
View raw message