cocoon-cvs mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cziege...@apache.org
Subject svn commit: r180312 - in /cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile: PortalUser.java impl/AuthenticationProfileManager.java impl/StaticProfileManager.java impl/UserInfo.java
Date Mon, 06 Jun 2005 14:01:20 GMT
Author: cziegeler
Date: Mon Jun  6 07:01:18 2005
New Revision: 180312

URL: http://svn.apache.org/viewcvs?rev=180312&view=rev
Log:
Make user serializable

Modified:
    cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/PortalUser.java
    cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/AuthenticationProfileManager.java
    cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/StaticProfileManager.java
    cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/UserInfo.java

Modified: cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/PortalUser.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/PortalUser.java?rev=180312&r1=180311&r2=180312&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/PortalUser.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/PortalUser.java
Mon Jun  6 07:01:18 2005
@@ -18,12 +18,12 @@
 /**
  * Information about the current portal user.
  * This object decouples the portal from the used authentication method.
- * 
+ *
  * @author <a href="mailto:cziegeler@s-und-n.de">Carsten Ziegeler</a>
  * @version SVN $Id$
  */
 public interface PortalUser {
-    
+
     /**
      * @return Returns the group.
      */
@@ -33,6 +33,6 @@
      * @return Returns the userName.
      */
     String getUserName();
-    
+
     boolean isUserInRole(String role);
 }

Modified: cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/AuthenticationProfileManager.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/AuthenticationProfileManager.java?rev=180312&r1=180311&r2=180312&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/AuthenticationProfileManager.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/AuthenticationProfileManager.java
Mon Jun  6 07:01:18 2005
@@ -15,6 +15,7 @@
  */
 package org.apache.cocoon.portal.profile.impl;
 
+import java.io.Serializable;
 import java.util.HashMap;
 import java.util.HashSet;
 import java.util.Iterator;
@@ -547,14 +548,14 @@
         return new User(state);
     }
     
-    protected static final class User implements PortalUser {
-        
+    protected static final class User implements PortalUser, Serializable {
+
         protected final RequestState state;
-        
+
         public User(RequestState state) {
             this.state = state;    
         }
-        
+
         /* (non-Javadoc)
          * @see org.apache.cocoon.portal.profile.PortalUser#getGroup()
          */
@@ -562,14 +563,14 @@
             // TODO Auto-generated method stub
             return null;
         }
-        
+
         /* (non-Javadoc)
          * @see org.apache.cocoon.portal.profile.PortalUser#getUserName()
          */
         public String getUserName() {
             return this.state.getHandler().getUserId();
         }
-        
+
         /* (non-Javadoc)
          * @see org.apache.cocoon.portal.profile.PortalUser#isUserInRole(java.lang.String)
          */
@@ -577,5 +578,5 @@
             return this.state.getHandler().isUserInRole(role);
         }
     }
-    
+
 }

Modified: cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/StaticProfileManager.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/StaticProfileManager.java?rev=180312&r1=180311&r2=180312&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/StaticProfileManager.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/StaticProfileManager.java
Mon Jun  6 07:01:18 2005
@@ -15,6 +15,7 @@
  */
 package org.apache.cocoon.portal.profile.impl;
 
+import java.io.Serializable;
 import java.util.ArrayList;
 import java.util.Collection;
 import java.util.HashMap;
@@ -383,15 +384,15 @@
         return this.portalUser;
     }
     
-    protected static final class StaticPortalUser implements PortalUser {
-        
+    protected static final class StaticPortalUser implements PortalUser, Serializable {
+
         /* (non-Javadoc)
          * @see org.apache.cocoon.portal.profile.PortalUser#getGroup()
          */
         public String getGroup() {
             return null;
         }
-        
+
         /* (non-Javadoc)
          * @see org.apache.cocoon.portal.profile.PortalUser#getUserName()
          */
@@ -405,5 +406,5 @@
         public boolean isUserInRole(String role) {
             return false;
         }
-}
+    }
 }

Modified: cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/UserInfo.java
URL: http://svn.apache.org/viewcvs/cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/UserInfo.java?rev=180312&r1=180311&r2=180312&view=diff
==============================================================================
--- cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/UserInfo.java
(original)
+++ cocoon/branches/BRANCH_2_1_X/src/blocks/portal/java/org/apache/cocoon/portal/profile/impl/UserInfo.java
Mon Jun  6 07:01:18 2005
@@ -15,6 +15,7 @@
  */
 package org.apache.cocoon.portal.profile.impl;
 
+import java.io.Serializable;
 import java.util.Map;
 
 import org.apache.cocoon.portal.profile.PortalUser;
@@ -23,27 +24,27 @@
  * Information about the current user.
  * This data object is used for loading the profile. It decouples the
  * portal from the used authentication method.
- * 
+ *
  * @author <a href="mailto:cziegeler@s-und-n.de">Carsten Ziegeler</a>
  * @version CVS $Id: MapProfileLS.java 30941 2004-07-29 19:56:58Z vgritsenko $
  */
-public abstract class UserInfo implements PortalUser {
-    
+public abstract class UserInfo implements PortalUser, Serializable {
+
     protected String userName;
-    
+
     protected String group;
-    
+
     protected String portalName;
 
     protected String layoutKey;
 
     protected Map    configurations;
-    
+
     public UserInfo(String portalName, String layoutKey) {
         this.portalName = portalName;
         this.layoutKey = layoutKey;
     }
-    
+
     /**
      * @return Returns the group.
      */
@@ -57,49 +58,49 @@
     public void setGroup(String group) {
         this.group = group;
     }
-    
+
     /**
      * @return Returns the userName.
      */
     public String getUserName() {
         return userName;
     }
-    
+
     /**
      * @param userName The userName to set.
      */
     public void setUserName(String userName) {
         this.userName = userName;
     }
-    
+
     /**
      * @return Returns the configurations.
      */
     public Map getConfigurations() {
         return configurations;
     }
-    
+
     /**
      * @param configurations The configurations to set.
      */
     public void setConfigurations(Map configurations) {
         this.configurations = configurations;
     }
-    
+
     /**
      * @return Returns the layoutKey.
      */
     public String getLayoutKey() {
         return layoutKey;
     }
-    
+
     /**
      * @return Returns the portalName.
      */
     public String getPortalName() {
         return portalName;
     }
-    
+
     /* (non-Javadoc)
      * @see org.apache.cocoon.portal.profile.PortalUser#isUserInRole(java.lang.String)
      */



Mime
View raw message