cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From h...@apache.org
Subject cvs commit: xml-cocoon2/src/org/apache/cocoon/acting SessionStateAction.java
Date Tue, 18 Sep 2001 14:53:26 GMT
haul        01/09/18 07:53:26

  Modified:    src/org/apache/cocoon/acting Tag: cocoon_20_branch
                        SessionStateAction.java
  Log:
  changed *SessionState(Matcher|Selector)* to more general *SessionAttribute(Matcher|Selector)*
  updated docs + samples accordingly
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.5   +11 -12    xml-cocoon2/src/org/apache/cocoon/acting/SessionStateAction.java
  
  Index: SessionStateAction.java
  ===================================================================
  RCS file: /home/cvs/xml-cocoon2/src/org/apache/cocoon/acting/SessionStateAction.java,v
  retrieving revision 1.1.2.4
  retrieving revision 1.1.2.5
  diff -u -r1.1.2.4 -r1.1.2.5
  --- SessionStateAction.java	2001/08/22 12:08:20	1.1.2.4
  +++ SessionStateAction.java	2001/09/18 14:53:25	1.1.2.5
  @@ -65,15 +65,14 @@
    *   </tr> 
    * </table>
    *
  - * @see org.apache.cocoon.matching.WildcardSessionStateMatcherFactory
  - * @see org.apache.cocoon.selection.SessionStateSelectorFactory
  + * @see org.apache.cocoon.matching.WildcardSessionAttributeMatcherFactory
  + * @see org.apache.cocoon.selection.SessionAttributeSelectorFactory
    *
    * @author <a href="mailto:haul@informatik.tu-darmstadt.de">Christian Haul</a>
  - * @version CVS $Id: SessionStateAction.java,v 1.1.2.4 2001/08/22 12:08:20 sylvain Exp
$ */
  + * @version CVS $Id: SessionStateAction.java,v 1.1.2.5 2001/09/18 14:53:25 haul Exp $ */
   public class SessionStateAction extends AbstractConfigurableAction implements ThreadSafe
{
   
  -    private static String componentName = "REZEPTE SessionStateAction";
  -    protected String statekey = Constants.SESSION_STATE_ATTRIBUTE;
  +    protected String statekey = "org.apache.cocoon.SessionState";
       protected String newstate = null;
       protected int sublevels = 0;
       protected int mylevel = 0;
  @@ -111,7 +110,7 @@
   	mylevel = par.getParameterAsInteger("state-level", mylevel);
   
   	if (newstate == null ) {
  -	    getLogger().error(componentName + ": new-state is null");
  +	    getLogger().error("new-state is null");
   	    return null;
   	}
   
  @@ -124,29 +123,29 @@
   		if (sublevels == 0) {
   		    oldstate = (String) session.getAttribute(statekey);
   		    session.setAttribute(statekey, newstate);
  -		    getLogger().debug(componentName+" : "+statekey+"="+newstate);
  +		    getLogger().debug(statekey+"="+newstate);
   
   		} else { // sublevels != 0
   		    oldstate = (String) session.getAttribute( statekey + Integer.toString(mylevel) );
   		    for (int i=mylevel+1; i<=sublevels; i++) {
   			session.removeAttribute( statekey+Integer.toString(i) );
  -			getLogger().debug(componentName+" : remove "+statekey+Integer.toString(i));
  +			getLogger().debug("remove "+statekey+Integer.toString(i));
   		    }
   		    session.setAttribute( statekey + Integer.toString(mylevel), newstate);
  -		    getLogger().debug(componentName+" : "+statekey+Integer.toString(mylevel)+"="+newstate);
  +		    getLogger().debug(statekey+Integer.toString(mylevel)+"="+newstate);
   		}
  -		getLogger().debug(componentName + " transition " + oldstate + " -> " + newstate);
  +		getLogger().debug("transition " + oldstate + " -> " + newstate);
   		
   		HashMap map = new HashMap(1);
   		map.put("newstate", newstate);
   		return map;
   		
   	    } else {
  -                getLogger().warn(componentName + ": A session object was not present or
no longer valid");
  +                getLogger().warn("A session object was not present or no longer valid");
   		return null;
               }
           } else {
  -	    getLogger().warn(componentName + ": No request object");
  +	    getLogger().warn("No request object");
   	    return null;
   	}
   	
  
  
  

----------------------------------------------------------------------
In case of troubles, e-mail:     webmaster@xml.apache.org
To unsubscribe, e-mail:          cocoon-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: cocoon-cvs-help@xml.apache.org


Mime
View raw message