roller-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agillil...@apache.org
Subject svn commit: r395059 - in /incubator/roller/branches/roller-newbackend: sandbox/atomprotocol/src/org/roller/presentation/atomapi/ src/org/roller/business/ src/org/roller/business/hibernate/ src/org/roller/model/ src/org/roller/pojos/ src/org/roller/pres...
Date Tue, 18 Apr 2006 21:50:53 GMT
Author: agilliland
Date: Tue Apr 18 14:50:51 2006
New Revision: 395059

URL: http://svn.apache.org/viewcvs?rev=395059&view=rev
Log:
manager method name refactorings for UserManager.

storeXXX() -> saveXXX()
retrieveXXX() -> getXXX()
createXXX() -> addXXX() (or is removed)

also removed unnecessary addUsers(list) method.


Modified:
    incubator/roller/branches/roller-newbackend/sandbox/atomprotocol/src/org/roller/presentation/atomapi/RollerAtomHandler.java
    incubator/roller/branches/roller-newbackend/src/org/roller/business/ThemeManagerImpl.java
    incubator/roller/branches/roller-newbackend/src/org/roller/business/hibernate/HibernateUserManagerImpl.java
    incubator/roller/branches/roller-newbackend/src/org/roller/model/UserManager.java
    incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WeblogEntryData.java
    incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WebsiteData.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerRequest.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerSession.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/velocity/RollerResourceLoader.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/CreateWebsiteAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/InviteMemberAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/MemberPermissionsAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/ThemeEditorAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/UserAdminAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WeblogTemplateFormAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WebsiteFormAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourProfileAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourWebsitesAction.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BaseAPIHandler.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BloggerAPIHandler.java
    incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/MetaWeblogAPIHandler.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/RollerTestBase.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/TestUtils.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/PermissionTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/RefererManagerTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/UserTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogCategoryTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogPageTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogTest.java
    incubator/roller/branches/roller-newbackend/tests/org/roller/presentation/StrutsActionTestBase.java

Modified: incubator/roller/branches/roller-newbackend/sandbox/atomprotocol/src/org/roller/presentation/atomapi/RollerAtomHandler.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/sandbox/atomprotocol/src/org/roller/presentation/atomapi/RollerAtomHandler.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/sandbox/atomprotocol/src/org/roller/presentation/atomapi/RollerAtomHandler.java (original)
+++ incubator/roller/branches/roller-newbackend/sandbox/atomprotocol/src/org/roller/presentation/atomapi/RollerAtomHandler.java Tue Apr 18 14:50:51 2006
@@ -109,7 +109,7 @@
         
         if (mUsername != null) {
             try {
-                this.user = mRoller.getUserManager().getUser(mUsername);
+                this.user = mRoller.getUserManager().getUserByUsername(mUsername);
             } catch (Exception e) {
                 mLogger.error("ERROR: setting user", e);
             }
@@ -623,7 +623,7 @@
         }
         String digest = null;
         try {
-            UserData user = mRoller.getUserManager().getUser(userName);
+            UserData user = mRoller.getUserManager().getUserByUsername(userName);
             digest = WSSEUtilities.generateDigest(
                     WSSEUtilities.base64Decode(nonce),
                     created.getBytes("UTF-8"),
@@ -656,7 +656,7 @@
                         int p = userPass.indexOf(":");
                         if (p != -1) {
                             userID = userPass.substring(0, p);
-                            UserData user = mRoller.getUserManager().getUser(userID);                                                        
+                            UserData user = mRoller.getUserManager().getUserByUsername(userID);                                                        
                             boolean enabled = user.getEnabled().booleanValue();
                             if (enabled) {    
                                 // are passwords encrypted?

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/business/ThemeManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/business/ThemeManagerImpl.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/business/ThemeManagerImpl.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/business/ThemeManagerImpl.java Tue Apr 18 14:50:51 2006
@@ -311,7 +311,7 @@
                 if(theme_template.getName().equals(WeblogTemplate.DEFAULT_PAGE)) {
                     // this is the main Weblog template
                     try {
-                        template = userMgr.retrievePage(website.getDefaultPageId());
+                        template = userMgr.getPage(website.getDefaultPageId());
                     } catch(Exception e) {
                         // user may not have a default page yet
                     }
@@ -335,7 +335,7 @@
                             theme_template.getContents(),       // contents
                             new Date()                          // last mod
                             );
-                    userMgr.storePage( template );
+                    userMgr.savePage( template );
                 }
             }
             
@@ -363,7 +363,7 @@
             }
             
             // save our updated website
-            userMgr.storeWebsite(website);
+            userMgr.saveWebsite(website);
             
         } catch (Exception e) {
             mLogger.error("ERROR in action",e);

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/business/hibernate/HibernateUserManagerImpl.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/business/hibernate/HibernateUserManagerImpl.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/business/hibernate/HibernateUserManagerImpl.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/business/hibernate/HibernateUserManagerImpl.java Tue Apr 18 14:50:51 2006
@@ -65,7 +65,7 @@
     /**
      * @see org.roller.model.UserManager#storeWebsite(org.roller.pojos.WebsiteData)
      */
-    public void storeWebsite(WebsiteData data) throws RollerException {
+    public void saveWebsite(WebsiteData data) throws RollerException {
         this.strategy.store(data);
     }
     
@@ -174,7 +174,7 @@
     }
     
     
-    public void storeUser(UserData data) throws RollerException {
+    public void saveUser(UserData data) throws RollerException {
         this.strategy.store(data);
     }
     
@@ -189,7 +189,7 @@
     }
     
     
-    public void storePermissions(PermissionsData perms) throws RollerException {
+    public void savePermissions(PermissionsData perms) throws RollerException {
         this.strategy.store(perms);
     }
     
@@ -202,7 +202,7 @@
     /**
      * @see org.roller.model.UserManager#storePage(org.roller.pojos.WeblogTemplate)
      */
-    public void storePage(WeblogTemplate data) throws RollerException {
+    public void savePage(WeblogTemplate data) throws RollerException {
         this.strategy.store(data);
     }
     
@@ -212,24 +212,11 @@
     }
     
     
-    public void addUser(UserData ud) throws RollerException {
+    public void addUser(UserData newUser) throws RollerException {
         
-        if(ud == null)
+        if(newUser == null)
             throw new RollerException("cannot add null user");
         
-        // simplification, just add user to a collection and reuse the method
-        Collection userList = new ArrayList();
-        userList.add(ud);
-        
-        this.addUsers(userList);
-    }
-    
-    
-    public void addUsers(Collection users) throws RollerException {
-        
-        if(users == null || users.size() < 1)
-            throw new RollerException("no users to add");
-        
         // TODO BACKEND: we must do this in a better fashion, like getUserCnt()?
         boolean adminUser = false;
         List existingUsers = this.getUsers();
@@ -238,27 +225,21 @@
             adminUser = true;
         }
         
-        UserData newUser = null;
-        Iterator items = users.iterator();
-        while(items.hasNext()) {
-            newUser = (UserData) items.next();
-            
-            if(getUser(newUser.getUserName()) != null ||
-                    getUser(newUser.getUserName().toLowerCase()) != null) {
-                throw new RollerException("error.add.user.userNameInUse");
-            }
-            
-            newUser.grantRole("editor");
-            if(adminUser) {
-                newUser.grantRole("admin");
-            }
-            
-            this.strategy.store(newUser);
+        if(getUserByUsername(newUser.getUserName()) != null ||
+                getUserByUsername(newUser.getUserName().toLowerCase()) != null) {
+            throw new RollerException("error.add.user.userNameInUse");
         }
+        
+        newUser.grantRole("editor");
+        if(adminUser) {
+            newUser.grantRole("admin");
+        }
+        
+        this.strategy.store(newUser);
     }
     
     
-    public void createWebsite(WebsiteData newWeblog) throws RollerException {
+    public void addWebsite(WebsiteData newWeblog) throws RollerException {
         
         this.strategy.store(newWeblog);
         this.addWeblogContents(newWeblog);
@@ -335,47 +316,6 @@
     
     
     /**
-     * The old createWebsite() method.
-     *
-     * TODO BACKEND: EOL this method.
-     */
-    public WebsiteData createWebsite(UserData user, Map pages, String handle,
-                                     String name, String description, 
-                                     String email, String theme, String locale, 
-                                     String timeZone) throws RollerException {
-        
-        WebsiteData website = new WebsiteData(
-                    null,                // id
-                    name,                // name
-                    handle,              // handle
-                    description,         // description
-                    user,                // userId
-                    "dummy",             // defaultPageId
-                    "dummy",             // weblogDayPageId
-                    Boolean.TRUE,        // enableBloggerApi
-                    null,                // bloggerCategory
-                    null,                // defaultCategory
-                    "editor-text.jsp",   // editorPage
-                    "",                  // blacklist
-                    Boolean.TRUE,        // allowComments
-                    Boolean.FALSE,       // emailComments
-                    "",                  // emailFromAddress
-                    Boolean.TRUE,        // isEnabled
-                    email,               // emailAddress
-                    new Date(),          // dateCreated
-                    Boolean.TRUE,        // defaultAllowComments
-                    0,                   // defaultCommentDays
-                    Boolean.FALSE);      // moderateComments
-            website.setEditorTheme(theme);
-            website.setLocale(locale);
-            website.setTimeZone(timeZone);
-            
-            this.createWebsite(website);
-            
-            return website;
-    }
-    
-    /**
      * Creates and stores a pending PermissionsData for user and website specified.
      *
      * TODO BACKEND: do we really need this?  can't we just use storePermissions()?
@@ -422,7 +362,7 @@
     }
     
     
-    public WebsiteData retrieveWebsite(String id) throws RollerException {
+    public WebsiteData getWebsite(String id) throws RollerException {
         return (WebsiteData) this.strategy.load(id,WebsiteData.class);
     }
     
@@ -488,17 +428,17 @@
     }
     
     
-    public UserData retrieveUser(String id) throws RollerException {
+    public UserData getUser(String id) throws RollerException {
         return (UserData)this.strategy.load(id,UserData.class);
     }
     
     
-    public UserData getUser(String userName) throws RollerException {
-        return getUser(userName, Boolean.TRUE);
+    public UserData getUserByUsername(String userName) throws RollerException {
+        return getUserByUsername(userName, Boolean.TRUE);
     }
     
     
-    public UserData getUser(String userName, Boolean enabled)
+    public UserData getUserByUsername(String userName, Boolean enabled)
             throws RollerException {
         
         if (userName==null )
@@ -603,7 +543,7 @@
     }
     
     
-    public WeblogTemplate retrievePage(String id) throws RollerException {
+    public WeblogTemplate getPage(String id) throws RollerException {
         // Don't hit database for templates stored on disk
         if (id != null && id.endsWith(".vm")) return null;
         
@@ -686,7 +626,7 @@
     }
     
     
-    public PermissionsData retrievePermissions(String inviteId) throws RollerException {
+    public PermissionsData getPermissions(String inviteId) throws RollerException {
         return (PermissionsData)this.strategy.load(inviteId, PermissionsData.class);
     }
     

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/model/UserManager.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/model/UserManager.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/model/UserManager.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/model/UserManager.java Tue Apr 18 14:50:51 2006
@@ -25,37 +25,31 @@
      * @param user User object to be added, initialized with name, password, etc.
      * @throws RollerException
      */
-    public void addUser(UserData user) throws RollerException;
-    
-    
-    /**
-     * Add a collection of users in a single transaction.
-     */
-    public void addUsers(Collection users) throws RollerException;
+    public void addUser(UserData newUser) throws RollerException;
     
     
     /**
      * Store a single user.
      */
-    public void storeUser(UserData data) throws RollerException;
+    public void saveUser(UserData data) throws RollerException;
     
     
     public void removeUser(UserData user) throws RollerException;
     
     
-    public UserData retrieveUser(String id)throws RollerException;
+    public UserData getUser(String id)throws RollerException;
     
     
     /** 
      * Get user object by user name (only enabled users) 
      */
-    public UserData getUser(String userName) throws RollerException;
+    public UserData getUserByUsername(String userName) throws RollerException;
     
     
     /** 
      * Get user object by user name, optionally include dis-enabled users 
      */
-    public UserData getUser(String userName, Boolean enabled) throws RollerException;
+    public UserData getUserByUsername(String userName, Boolean enabled) throws RollerException;
     
     
     /** 
@@ -93,45 +87,19 @@
             int offset, int length, Boolean enabled) throws RollerException;
     
     
-    public void createWebsite(WebsiteData newWebsite) throws RollerException;
-    
-    
-    /**
-     * Create a fresh new website.
-     *
-     * @param ud          User creating website
-     * @param pages       Pages to be used in theme (TODO: elim. this redundancy)
-     * @param handle      Handle of new website
-     * @param name        Name of new website
-     * @param description Description of new website
-     * @param theme       Name of theme to be used
-     * @param locale      Locale code of new website
-     * @param timeZone    ID of timeZone of new website
-     * @return            New website object (has been saved and committed)
-     * @throws RollerException
-     */
-    public WebsiteData createWebsite(
-            UserData ud,
-            Map pages,
-            String handle,
-            String name,
-            String description,
-            String email,
-            String theme,
-            String locale,
-            String timeZone) throws RollerException;
+    public void addWebsite(WebsiteData newWebsite) throws RollerException;
     
     
     /**
      * Store a single weblog.
      */
-    public void storeWebsite(WebsiteData data) throws RollerException;
+    public void saveWebsite(WebsiteData data) throws RollerException;
     
     
     public void removeWebsite(WebsiteData website) throws RollerException;
     
     
-    public WebsiteData retrieveWebsite(String id) throws RollerException;
+    public WebsiteData getWebsite(String id) throws RollerException;
     
     
     /**
@@ -161,13 +129,13 @@
     public List getWebsites(UserData user, Boolean enabled, Boolean active) throws RollerException;
     
     
-    public void storePermissions(PermissionsData perms) throws RollerException;
+    public void savePermissions(PermissionsData perms) throws RollerException;
     
     
     public void removePermissions(PermissionsData perms) throws RollerException;
     
     
-    public PermissionsData retrievePermissions(String id) throws RollerException;
+    public PermissionsData getPermissions(String id) throws RollerException;
     
     
     /**
@@ -239,7 +207,7 @@
     /**
      * Store page
      */
-    public void storePage(WeblogTemplate data) throws RollerException;
+    public void savePage(WeblogTemplate data) throws RollerException;
     
     
     /**
@@ -251,7 +219,7 @@
     /**
      * Get page by ID
      */
-    public WeblogTemplate retrievePage(String id) throws RollerException;
+    public WeblogTemplate getPage(String id) throws RollerException;
     
     
     /** 

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WeblogEntryData.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WeblogEntryData.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WeblogEntryData.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WeblogEntryData.java Tue Apr 18 14:50:51 2006
@@ -1137,7 +1137,7 @@
     public void setCreatorId(String creatorId) throws RollerException
     {
         UserManager umgr = RollerFactory.getRoller().getUserManager();
-        setCreator(umgr.retrieveUser(creatorId)); 
+        setCreator(umgr.getUser(creatorId)); 
     }
 
     /** Convenience method for checking status */

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WebsiteData.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WebsiteData.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WebsiteData.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/pojos/WebsiteData.java Tue Apr 18 14:50:51 2006
@@ -178,7 +178,7 @@
         // if we didn't get the Template from a theme then look in the db
         if(template == null) {
             UserManager userMgr = RollerFactory.getRoller().getUserManager();
-            template = userMgr.retrievePage(this.defaultPageId);
+            template = userMgr.getPage(this.defaultPageId);
         }
         
         if(template != null)

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerRequest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerRequest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerRequest.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerRequest.java Tue Apr 18 14:50:51 2006
@@ -152,7 +152,7 @@
         if (userName != null)
         {
             UserManager userMgr = RollerFactory.getRoller().getUserManager();
-            UserData currentUser = userMgr.getUser(userName);
+            UserData currentUser = userMgr.getUserByUsername(userName);
             // TODO: possible fix for backend refactoryings
             //RollerFactory.getRoller().setUser(currentUser);
         }
@@ -336,14 +336,14 @@
             }
             else if (websiteid != null && mWebsite == null )
             {
-                mWebsite = userMgr.retrieveWebsite(websiteid); 
+                mWebsite = userMgr.getWebsite(websiteid); 
             }
             
             // Look for page ID in request params
             String pageId = mRequest.getParameter(RollerRequest.PAGEID_KEY);                    
             if ( pageId != null )
             {
-                mPage = userMgr.retrievePage(pageId);                 
+                mPage = userMgr.getPage(pageId);                 
             }
             else if (mWebsite != null) 
             {
@@ -704,7 +704,7 @@
                 try
                 {
                     mPage = RollerFactory.getRoller()
-                        .getUserManager().retrievePage(id);
+                        .getUserManager().getPage(id);
                 }
                 catch (RollerException e)
                 {

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerSession.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerSession.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerSession.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/RollerSession.java Tue Apr 18 14:50:51 2006
@@ -64,7 +64,7 @@
                 try 
                 {
                     UserManager umgr = RollerFactory.getRoller().getUserManager();
-                    UserData user = umgr.getUser(principal.getName());
+                    UserData user = umgr.getUserByUsername(principal.getName());
                     // only set authenticated user if user is enabled
                     if (user.getEnabled().booleanValue()) 
                     {

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/velocity/RollerResourceLoader.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/velocity/RollerResourceLoader.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/velocity/RollerResourceLoader.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/velocity/RollerResourceLoader.java Tue Apr 18 14:50:51 2006
@@ -61,7 +61,7 @@
         
         try {
             WeblogTemplate page = 
-                    RollerFactory.getRoller().getUserManager().retrievePage(name);
+                    RollerFactory.getRoller().getUserManager().getPage(name);
             
             if (page == null) {
                 throw new ResourceNotFoundException(
@@ -99,7 +99,7 @@
         String name = resource.getName();
         try {
             WeblogTemplate page = 
-                    RollerFactory.getRoller().getUserManager().retrievePage(name);
+                    RollerFactory.getRoller().getUserManager().getPage(name);
             
             if (mLogger.isDebugEnabled()) {
                 mLogger.debug(name + ": resource=" + resource.getLastModified() +

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/weblog/actions/WeblogEntryFormAction.java Tue Apr 18 14:50:51 2006
@@ -237,8 +237,8 @@
             RollerSession      rses = RollerSession.getRollerSession(request);
             UserManager     userMgr = roller.getUserManager();
             WeblogManager weblogMgr = roller.getWeblogManager();
-            UserData           ud  = userMgr.retrieveUser(form.getCreatorId());
-            WebsiteData       site = userMgr.retrieveWebsite(form.getWebsiteId());
+            UserData           ud  = userMgr.getUser(form.getCreatorId());
+            WebsiteData       site = userMgr.getWebsite(form.getWebsiteId());
             WeblogEntryData  entry = null;
             
             if ( rses.isUserAuthorizedToAuthor(site)
@@ -610,7 +610,7 @@
         try {
             WeblogEntryFormEx wf = (WeblogEntryFormEx)actionForm;
             UserManager umgr = RollerFactory.getRoller().getUserManager();
-            WebsiteData site = umgr.retrieveWebsite(wf.getWebsiteId());
+            WebsiteData site = umgr.getWebsite(wf.getWebsiteId());
             RollerSession rses =
                     RollerSession.getRollerSession(request);
             if (rses.isUserAuthorizedToAuthor(site)) {
@@ -666,7 +666,7 @@
         try {
             WeblogEntryFormEx wf = (WeblogEntryFormEx)actionForm;
             UserManager umgr = RollerFactory.getRoller().getUserManager();
-            WebsiteData site = umgr.retrieveWebsite(wf.getWebsiteId());
+            WebsiteData site = umgr.getWebsite(wf.getWebsiteId());
             RollerSession rses =
                     RollerSession.getRollerSession(request);
             if ( rses.isUserAuthorized(site) ) {

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/CreateWebsiteAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/CreateWebsiteAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/CreateWebsiteAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/CreateWebsiteAction.java Tue Apr 18 14:50:51 2006
@@ -136,16 +136,32 @@
                 }
             }
             
-            website = mgr.createWebsite(
-                    user,
-                    null,
-                    form.getHandle(),
-                    form.getName(),
-                    form.getDescription(),
-                    form.getEmailAddress(),
-                    form.getTheme(),
-                    form.getLocale(),
-                    form.getTimeZone());
+            WebsiteData newWebsite = new WebsiteData(
+                    null,                           // id
+                    form.getName(),                 // name
+                    form.getHandle(),               // handle
+                    form.getDescription(),          // description
+                    user,                           // userId
+                    "dummy",                        // defaultPageId
+                    "dummy",                        // weblogDayPageId
+                    Boolean.TRUE,                   // enableBloggerApi
+                    null,                           // bloggerCategory
+                    null,                           // defaultCategory
+                    "editor-text.jsp",              // editorPage
+                    "",                             // blacklist
+                    Boolean.TRUE,                   // allowComments
+                    Boolean.FALSE,                  // emailComments
+                    "",                             // emailFromAddress
+                    Boolean.TRUE,                   // isEnabled
+                    form.getEmailAddress(),         // emailAddress
+                    new java.util.Date(),           // dateCreated
+                    Boolean.TRUE,                   // defaultAllowComments
+                    0,                              // defaultCommentDays
+                    Boolean.FALSE);                 // moderateComments
+            newWebsite.setEditorTheme(form.getTheme());
+            newWebsite.setLocale(form.getLocale());
+            newWebsite.setTimeZone(form.getTimeZone());
+            
             RollerFactory.getRoller().flush();
             
             request.setAttribute("model",

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/InviteMemberAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/InviteMemberAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/InviteMemberAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/InviteMemberAction.java Tue Apr 18 14:50:51 2006
@@ -121,7 +121,7 @@
         ActionMessages errors = new ActionErrors();
         InviteMemberForm form = (InviteMemberForm)actionForm;
         UserManager umgr = RollerFactory.getRoller().getUserManager();
-        UserData user = umgr.getUser(form.getUserName());
+        UserData user = umgr.getUserByUsername(form.getUserName());
         
         BasePageModel pageModel = new BasePageModel(
             "inviteMember.title", request, response, mapping);              

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/MemberPermissionsAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/MemberPermissionsAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/MemberPermissionsAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/MemberPermissionsAction.java Tue Apr 18 14:50:51 2006
@@ -144,7 +144,7 @@
                         else
                         {
                             perms.setPermissionMask(val);
-                            userMgr.storePermissions(perms);
+                            userMgr.savePermissions(perms);
                             changed++;
                         }
                     }

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/ThemeEditorAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/ThemeEditorAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/ThemeEditorAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/ThemeEditorAction.java Tue Apr 18 14:50:51 2006
@@ -280,7 +280,7 @@
                         website.setEditorTheme(newTheme);
                         
                         UserManager userMgr = RollerFactory.getRoller().getUserManager();
-                        userMgr.storeWebsite(website);
+                        userMgr.saveWebsite(website);
                         RollerFactory.getRoller().flush();
                         
                         mLogger.debug("Saved theme "+newTheme+" for "+username);

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/UserAdminAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/UserAdminAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/UserAdminAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/UserAdminAction.java Tue Apr 18 14:50:51 2006
@@ -73,7 +73,7 @@
                 {
                     ActionMessages msgs = getErrors(request);
                     msgs = (msgs == null) ? new ActionMessages() : msgs;
-                    user = mgr.getUser(userForm.getUserName(), null);                    
+                    user = mgr.getUserByUsername(userForm.getUserName(), null);                    
                     if (user != null)
                     {
                         userForm.copyFrom(user, request.getLocale());                        
@@ -190,7 +190,7 @@
                     
                 } else {
                     
-                    UserData user = mgr.retrieveUser(userForm.getId());
+                    UserData user = mgr.getUser(userForm.getId());
                     userForm.copyTo(user, request.getLocale()); 
                 
                     // Check username and email addresses
@@ -220,7 +220,7 @@
                     if (msgs.isEmpty()) {
                         try {
                            // Persist changes to user
-                            mgr.storeUser(user);
+                            mgr.saveUser(user);
                             RollerFactory.getRoller().flush();
                             
                             msgs.add(ActionMessages.GLOBAL_MESSAGE,

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WeblogTemplateFormAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WeblogTemplateFormAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WeblogTemplateFormAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WeblogTemplateFormAction.java Tue Apr 18 14:50:51 2006
@@ -77,7 +77,7 @@
                 validateLink( data );
 
                 UserManager mgr = RollerFactory.getRoller().getUserManager();
-                mgr.storePage( data );
+                mgr.savePage( data );
                 RollerFactory.getRoller().flush();
                 
                 ActionMessages uiMessages = new ActionMessages();
@@ -164,7 +164,7 @@
             if (website == null && form.getId()!=null) 
             {
                 UserManager mgr = RollerFactory.getRoller().getUserManager();                
-                WeblogTemplate template = mgr.retrievePage(form.getId());
+                WeblogTemplate template = mgr.getPage(form.getId());
                 website = template.getWebsite();
             }
             
@@ -200,7 +200,7 @@
         {
             UserManager mgr = RollerFactory.getRoller().getUserManager();
             WeblogTemplateForm form = (WeblogTemplateForm)actionForm;
-            WeblogTemplate template = mgr.retrievePage(form.getId());
+            WeblogTemplate template = mgr.getPage(form.getId());
             WebsiteData website = template.getWebsite();
             
             RollerSession rses = RollerSession.getRollerSession(request);          
@@ -301,7 +301,7 @@
             RollerRequest rreq = RollerRequest.getRollerRequest(request);
             WeblogTemplateForm form = (WeblogTemplateForm)actionForm;
             UserManager mgr = RollerFactory.getRoller().getUserManager();
-            WeblogTemplate data = mgr.retrievePage(form.getId());
+            WeblogTemplate data = mgr.getPage(form.getId());
             WebsiteData website = data.getWebsite();
             
             RollerSession rses = RollerSession.getRollerSession(request);
@@ -312,7 +312,7 @@
 
                 validateLink( data );
 
-                mgr.storePage( data );
+                mgr.savePage( data );
                 RollerFactory.getRoller().flush();
                 
                 // set the (possibly) new link back into the Form bean

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WebsiteFormAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WebsiteFormAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WebsiteFormAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/WebsiteFormAction.java Tue Apr 18 14:50:51 2006
@@ -136,7 +136,7 @@
             WeblogManager wmgr = RollerFactory.getRoller().getWeblogManager();
             UserManager umgr = RollerFactory.getRoller().getUserManager();
             
-            WebsiteData wd = umgr.retrieveWebsite(form.getId());
+            WebsiteData wd = umgr.getWebsite(form.getId());
             
             // Set website in request, so subsequent action gets it
             RollerRequest.getRollerRequest(request).setWebsite(wd);
@@ -149,7 +149,7 @@
                     form.setEnabled(wd.getEnabled());
                     form.copyTo(wd, request.getLocale());
                     
-                    umgr.storeWebsite(wd);
+                    umgr.saveWebsite(wd);
                     RollerFactory.getRoller().getRefererManager().applyRefererFilters(wd);
                     
                     RollerFactory.getRoller().flush();
@@ -226,7 +226,7 @@
             throws Exception {
         WebsiteFormEx form = (WebsiteFormEx)actionForm;
         UserManager umgr = RollerFactory.getRoller().getUserManager();
-        WebsiteData website = umgr.retrieveWebsite(form.getId());
+        WebsiteData website = umgr.getWebsite(form.getId());
         ActionForward forward = mapping.findForward("removeWebsite.page");
         request.setAttribute("model", new WebsitePageModel(
                 "websiteRemove.title", request, response, mapping, website));
@@ -256,7 +256,7 @@
         try {
             UserManager umgr = RollerFactory.getRoller().getUserManager();
             WebsiteFormEx form = (WebsiteFormEx)actionForm;
-            WebsiteData website = umgr.retrieveWebsite(form.getId());
+            WebsiteData website = umgr.getWebsite(form.getId());
             
             RollerSession rses = RollerSession.getRollerSession(request);
             if ( rses.isUserAuthorizedToAdmin(website) ) {

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourProfileAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourProfileAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourProfileAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourProfileAction.java Tue Apr 18 14:50:51 2006
@@ -148,7 +148,7 @@
                 
                 // save the updated profile
                 UserManager mgr = RollerFactory.getRoller().getUserManager();
-                mgr.storeUser(data);
+                mgr.saveUser(data);
                 RollerFactory.getRoller().flush();
 
                 request.setAttribute("model", new BasePageModel(

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourWebsitesAction.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourWebsitesAction.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourWebsitesAction.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/website/actions/YourWebsitesAction.java Tue Apr 18 14:50:51 2006
@@ -77,12 +77,12 @@
         YourWebsitesForm form = (YourWebsitesForm)actionForm;
         
         UserManager userMgr = RollerFactory.getRoller().getUserManager();
-        PermissionsData perms = userMgr.retrievePermissions(form.getInviteId());
+        PermissionsData perms = userMgr.getPermissions(form.getInviteId());
         
         // TODO ROLLER_2.0: notify inviter that invitee has accepted invitation  
         // TODO EXCEPTIONS: better exception handling
         perms.setPending(false);
-        userMgr.storePermissions(perms);
+        userMgr.savePermissions(perms);
         RollerFactory.getRoller().flush();
         
         ActionMessages msgs = new ActionMessages();
@@ -106,7 +106,7 @@
         YourWebsitesForm form = (YourWebsitesForm)actionForm;
         
         UserManager userMgr = RollerFactory.getRoller().getUserManager();
-        PermissionsData perms = userMgr.retrievePermissions(form.getInviteId());
+        PermissionsData perms = userMgr.getPermissions(form.getInviteId());
         
         // TODO ROLLER_2.0: notify inviter that invitee has declined invitation
         // TODO EXCEPTIONS: better exception handling here

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BaseAPIHandler.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BaseAPIHandler.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BaseAPIHandler.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BaseAPIHandler.java Tue Apr 18 14:50:51 2006
@@ -104,7 +104,7 @@
             RollerRequest rreq = RollerRequest.getRollerRequest();
             
             UserManager userMgr = RollerFactory.getRoller().getUserManager();
-            user = userMgr.getUser(username);
+            user = userMgr.getUserByUsername(username);
             userEnabled = user.getEnabled().booleanValue();
             
             website = userMgr.getWebsiteByHandle(blogid);
@@ -186,7 +186,7 @@
             RollerRequest rreq = RollerRequest.getRollerRequest();
             
             UserManager userMgr = RollerFactory.getRoller().getUserManager();
-            user = userMgr.getUser(username);
+            user = userMgr.getUserByUsername(username);
             
             enabled = user.getEnabled().booleanValue();
             if (enabled)

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BloggerAPIHandler.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BloggerAPIHandler.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BloggerAPIHandler.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/BloggerAPIHandler.java Tue Apr 18 14:50:51 2006
@@ -124,9 +124,9 @@
             Roller roller = RollerFactory.getRoller();
             UserManager userMgr = roller.getUserManager();
             
-            WeblogTemplate page = userMgr.retrievePage(templateType);
+            WeblogTemplate page = userMgr.getPage(templateType);
             page.setContents(templateData);
-            userMgr.storePage(page);
+            userMgr.savePage(page);
             flushPageCache(page.getWebsite());
             
             return true;
@@ -164,7 +164,7 @@
         try {
             Roller roller = RollerFactory.getRoller();
             UserManager userMgr = roller.getUserManager();
-            WeblogTemplate page = userMgr.retrievePage(templateType);
+            WeblogTemplate page = userMgr.getPage(templateType);
             
             if ( null == page ) {
                 throw new XmlRpcException(UNKNOWN_EXCEPTION,"Template not found");
@@ -200,7 +200,7 @@
         try {
             Roller roller = RollerFactory.getRoller();
             UserManager userMgr = roller.getUserManager();
-            UserData user = userMgr.getUser(userid);
+            UserData user = userMgr.getUserByUsername(userid);
             
             // parses full name into two strings, firstname and lastname
             String firstname = "", lastname = "";
@@ -265,7 +265,7 @@
                         RollerContext.getRollerContext().getAbsoluteContextUrl(req);
                 
                 UserManager umgr = RollerFactory.getRoller().getUserManager();
-                UserData user = umgr.getUser(userid);
+                UserData user = umgr.getUserByUsername(userid);
                 // get list of user's enabled websites
                 List websites = umgr.getWebsites(user, Boolean.TRUE, null);
                 Iterator iter = websites.iterator();

Modified: incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/MetaWeblogAPIHandler.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/MetaWeblogAPIHandler.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/MetaWeblogAPIHandler.java (original)
+++ incubator/roller/branches/roller-newbackend/src/org/roller/presentation/xmlrpc/MetaWeblogAPIHandler.java Tue Apr 18 14:50:51 2006
@@ -228,7 +228,7 @@
         try {
             Roller roller = RollerFactory.getRoller();
             WeblogManager weblogMgr = roller.getWeblogManager();
-            UserData user = roller.getUserManager().getUser(userid);
+            UserData user = roller.getUserManager().getUserByUsername(userid);
             Timestamp current =
                     new Timestamp(System.currentTimeMillis());
             

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/RollerTestBase.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/RollerTestBase.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/RollerTestBase.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/RollerTestBase.java Tue Apr 18 14:50:51 2006
@@ -161,10 +161,31 @@
                 Boolean.TRUE);
         umgr.addUser(ud);
         
-        // Create website for user with those pages
-        WebsiteData website = umgr.createWebsite(
-           ud, new HashMap(), username, username, username,"dummy@example.com",
-           "basic","en_US_WIN", "America/Los_Angeles");
+        WebsiteData website = new WebsiteData(
+                    null,                // id
+                    username,                // name
+                    username,              // handle
+                    username,         // description
+                    ud,                // userId
+                    "dummy",             // defaultPageId
+                    "dummy",             // weblogDayPageId
+                    Boolean.TRUE,        // enableBloggerApi
+                    null,                // bloggerCategory
+                    null,                // defaultCategory
+                    "editor-text.jsp",   // editorPage
+                    "",                  // blacklist
+                    Boolean.TRUE,        // allowComments
+                    Boolean.FALSE,       // emailComments
+                    "",                  // emailFromAddress
+                    Boolean.TRUE,        // isEnabled
+                    "dummy@example.com",               // emailAddress
+                    new Date(),          // dateCreated
+                    Boolean.TRUE,        // defaultAllowComments
+                    0,                   // defaultCommentDays
+                    Boolean.FALSE);      // moderateComments
+            website.setEditorTheme("basic");
+            website.setLocale("en_US_WIN");
+            website.setTimeZone("America/Los_Angeles");
         
         ThemeManager themeMgr = getRoller().getThemeManager();
         Theme usersTheme = themeMgr.getTheme(website.getEditorTheme());
@@ -200,7 +221,7 @@
             mCalendar.setTime(new Date());
             
             // create categories
-            website  = umgr.retrieveWebsite(website.getId());
+            website  = umgr.getWebsite(website.getId());
             WeblogCategoryData rootCat = wmgr.getRootWeblogCategory(website);
             createCategoryPostsAndComments(0, wmgr, ud, website, rootCat);
             
@@ -318,7 +339,7 @@
         UserManager umgr = getRoller().getUserManager();
         for (Iterator siteIter = mWebsitesCreated.iterator(); siteIter.hasNext();) {
             WebsiteData site = (WebsiteData) siteIter.next();
-            site = umgr.retrieveWebsite(site.getId());
+            site = umgr.getWebsite(site.getId());
             if (site != null) {
                 umgr.removeWebsite(site);
             }
@@ -326,7 +347,7 @@
         
         for (Iterator userIter = mUsersCreated.iterator(); userIter.hasNext();) {
             UserData user = (UserData) userIter.next();
-            user = umgr.retrieveUser(user.getId());
+            user = umgr.getUser(user.getId());
             if (user != null) umgr.removeUser(user);
         }
     }
@@ -363,7 +384,7 @@
         mLogger.debug("try to delete " + deleteMe);
         UserManager umgr = getRoller().getUserManager();
         
-        UserData user = umgr.getUser(deleteMe);
+        UserData user = umgr.getUserByUsername(deleteMe);
         
         WebsiteData website = (WebsiteData)umgr.getWebsites(user, null, null).get(0);
         umgr.removeWebsite(website);

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/TestUtils.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/TestUtils.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/TestUtils.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/TestUtils.java Tue Apr 18 14:50:51 2006
@@ -64,7 +64,7 @@
         mgr.addUser(testUser);
         
         // query for the user to make sure we return the persisted object
-        UserData user = mgr.getUser(username);
+        UserData user = mgr.getUserByUsername(username);
         
         if(user == null)
             throw new RollerException("error inserting new user");
@@ -80,7 +80,7 @@
         
         // lookup the user
         UserManager mgr = RollerFactory.getRoller().getUserManager();
-        UserData user = mgr.retrieveUser(id);
+        UserData user = mgr.getUser(id);
         
         // remove the user
         mgr.removeUser(user);
@@ -108,7 +108,7 @@
         
         // add weblog
         UserManager mgr = RollerFactory.getRoller().getUserManager();
-        mgr.createWebsite(testWeblog);
+        mgr.addWebsite(testWeblog);
         
         // query for the new weblog and return it
         WebsiteData weblog = mgr.getWebsiteByHandle(handle);
@@ -127,7 +127,7 @@
         
         // lookup the weblog
         UserManager mgr = RollerFactory.getRoller().getUserManager();
-        WebsiteData weblog = mgr.retrieveWebsite(id);
+        WebsiteData weblog = mgr.getWebsite(id);
         
         // remove the weblog
         mgr.removeWebsite(weblog);

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/PermissionTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/PermissionTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/PermissionTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/PermissionTest.java Tue Apr 18 14:50:51 2006
@@ -88,7 +88,7 @@
         perm.setWebsite(testWeblog);
         perm.setPending(false);
         perm.setPermissionMask(PermissionsData.ADMIN);
-        mgr.storePermissions(perm);
+        mgr.savePermissions(perm);
         TestUtils.endSession(true);
         
         // check that create was successful
@@ -99,7 +99,7 @@
         
         // update permissions
         perm.setPermissionMask(PermissionsData.LIMITED);
-        mgr.storePermissions(perm);
+        mgr.savePermissions(perm);
         TestUtils.endSession(true);
         
         // check that update was successful
@@ -138,7 +138,7 @@
         perm.setWebsite(testWeblog);
         perm.setPending(true);
         perm.setPermissionMask(PermissionsData.AUTHOR);
-        mgr.storePermissions(perm);
+        mgr.savePermissions(perm);
         
         // get pending permissions for a user
         perms = mgr.getPendingPermissions(testUser);
@@ -153,7 +153,7 @@
         // get permissions by id
         String id = perm.getId();
         perm = null;
-        perm = mgr.retrievePermissions(id);
+        perm = mgr.getPermissions(id);
         assertNotNull(perm);
         assertEquals(id, perm.getId());
         
@@ -195,11 +195,11 @@
         // accept invitation
         perm = mgr.getPermissions(testWeblog, user);
         perm.setPending(false);
-        mgr.storePermissions(perm);
+        mgr.savePermissions(perm);
         TestUtils.endSession(true);
         
         // re-query now that we have changed things
-        user = mgr.getUser(user.getUserName());
+        user = mgr.getUserByUsername(user.getUserName());
         testWeblog = mgr.getWebsiteByHandle(testWeblog.getHandle());
         
         // assert that invitation list is empty
@@ -220,7 +220,7 @@
         mgr.retireUser(testWeblog, user);
         TestUtils.endSession(true);
         
-        user = mgr.retrieveUser(user.getId());
+        user = mgr.getUser(user.getId());
         weblogs = mgr.getWebsites(user, null, null);
         assertEquals(0, weblogs.size());
         

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/RefererManagerTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/RefererManagerTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/RefererManagerTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/RefererManagerTest.java Tue Apr 18 14:50:51 2006
@@ -1 +1 @@
-package org.roller.business;

import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import org.roller.RollerException;
import org.roller.model.PropertiesManager;
import org.roller.model.RefererManager;
import org.roller.pojos.RollerPropertyData;
import org.roller.pojos.UserData;
import org.roller.pojos.WebsiteData;
import org.roller.util.DateUtil;
import org.roller.TestUtils;
import org.roller.model.RollerFactory;
import org.roller.model.UserManager;


/**
 * Test Roller Referer Management.
 */
public class RefererManagerTest extends TestCase {
    
    public static Log log = LogFactory.getLog(RefererManagerTest.class);
    
    UserData testUser = null;
    WebsiteData testWeblog = null;
    
    int count = 20;
    String testDay;
    String origSpa
 mWords;
    
    
    public RefererManagerTest(String name) {
        super(name);
    }
    
    
    public static Test suite() {
        return new TestSuite(RefererManagerTest.class);
    }
    
    
    /**
     * All tests in this suite require a user and a weblog.
     */
    public void setUp() throws Exception {
        
        try {
            testUser = TestUtils.setupUser("referTestUser");
            testWeblog = TestUtils.setupWeblog("referTestWeblog", testUser);
            
            // add "spamtest" to refererSpamWords
            PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
            RollerPropertyData spamprop = pmgr.getProperty("spam.blacklist");
            this.origSpamWords = spamprop.getValue();
            spamprop.setValue(spamprop.getValue() + ", spamtest");
            pmgr.store(spamprop);
            
            // add a number of referers to play with
            RefererManager rmgr = RollerFactory.getRoll
 er().getRefererManager();
            Calendar lCalendar = Calendar.getInstance();
            lCalendar.setTime(new Date());
            for (int i = 0; i < count; i++) {
                lCalendar.add(Calendar.DATE, -1);
                Timestamp day = new Timestamp(lCalendar.getTime().getTime());
                testDay = DateUtil.format8chars(day);
                
                rmgr.processReferrer("http://test"+i, "http://test"+i,
                        testWeblog.getHandle(), null, testDay);
            }
            
            TestUtils.endSession(true);
            
        } catch (Exception ex){
            log.error(ex);
            throw new Exception("Test setup failed", ex);
        }
    }
    
    public void tearDown() throws Exception {
        
        try {
            // reset refererSpamWords to original value
            PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
            RollerPropertyData spamprop = pmgr.getPro
 perty("spam.blacklist");
            spamprop.setValue(this.origSpamWords);
            pmgr.store(spamprop);
            
            TestUtils.teardownWeblog(testWeblog.getId());
            TestUtils.teardownUser(testUser.getId());
            
            TestUtils.endSession(true);
        } catch (Exception ex) {
            log.error(ex);
            throw new Exception("Test teardown failed", ex);
        }
    }
    
    
    public void testGetReferersToDate() throws Exception {
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List referers = rmgr.getReferersToDate(testWeblog, testDay);
        assertEquals("Should be one Referer.", referers.size(), 1);
    }
    
    
    public void testRefererProcessing() throws RollerException {
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals("number of refer
 ers should equal count", count, refs.size());
        
        int hits = rmgr.getDayHits(testWeblog);
        assertEquals("There should be one fewer hits than referers", count, hits);
    }
    
    
    public void testApplyRefererFilters() throws Exception {
        
        log.info("Test apply referers (global)");
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals(count, refs.size());
        
        PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
        RollerPropertyData spamprop = pmgr.getProperty("spam.blacklist");
        String origWords = spamprop.getValue();
        spamprop.setValue(spamprop.getValue() + ", test");
        pmgr.store(spamprop);
        TestUtils.endSession(true);
        
        rmgr.applyRefererFilters();
        TestUtils.endSession(true);
        
        refs = rmgr.getReferers(testWeblog);
      
   assertEquals(0, refs.size());
        
        spamprop = pmgr.getProperty("spam.blacklist");
        spamprop.setValue(origWords);
        pmgr.store(spamprop);
        TestUtils.endSession(true);
    }
    
    
    public void testApplyRefererFiltersWebsite() throws Exception {
        
        log.info("Test apply referers (weblog)");
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals(count, refs.size());
        String origWords = null;
        
        UserManager umgr = RollerFactory.getRoller().getUserManager();
        testWeblog = umgr.retrieveWebsite(testWeblog.getId());
        origWords = testWeblog.getBlacklist();
        testWeblog.setBlacklist("test");
        umgr.storeWebsite(testWeblog);
        TestUtils.endSession(true);
        
        rmgr.applyRefererFilters();
        TestUtils.endSession(true);
        
        refs = rmgr.getReferer
 s(testWeblog);
        assertEquals(0, refs.size());
    }
    
}
\ No newline at end of file
+package org.roller.business;

import java.sql.Timestamp;
import java.util.Calendar;
import java.util.Date;
import java.util.List;
import junit.framework.Test;
import junit.framework.TestCase;
import junit.framework.TestSuite;import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

import org.roller.RollerException;
import org.roller.model.PropertiesManager;
import org.roller.model.RefererManager;
import org.roller.pojos.RollerPropertyData;
import org.roller.pojos.UserData;
import org.roller.pojos.WebsiteData;
import org.roller.util.DateUtil;
import org.roller.TestUtils;
import org.roller.model.RollerFactory;
import org.roller.model.UserManager;


/**
 * Test Roller Referer Management.
 */
public class RefererManagerTest extends TestCase {
    
    public static Log log = LogFactory.getLog(RefererManagerTest.class);
    
    UserData testUser = null;
    WebsiteData testWeblog = null;
    
    int count = 20;
    String testDay;
    String origSpa
 mWords;
    
    
    public RefererManagerTest(String name) {
        super(name);
    }
    
    
    public static Test suite() {
        return new TestSuite(RefererManagerTest.class);
    }
    
    
    /**
     * All tests in this suite require a user and a weblog.
     */
    public void setUp() throws Exception {
        
        try {
            testUser = TestUtils.setupUser("referTestUser");
            testWeblog = TestUtils.setupWeblog("referTestWeblog", testUser);
            
            // add "spamtest" to refererSpamWords
            PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
            RollerPropertyData spamprop = pmgr.getProperty("spam.blacklist");
            this.origSpamWords = spamprop.getValue();
            spamprop.setValue(spamprop.getValue() + ", spamtest");
            pmgr.store(spamprop);
            
            // add a number of referers to play with
            RefererManager rmgr = RollerFactory.getRoll
 er().getRefererManager();
            Calendar lCalendar = Calendar.getInstance();
            lCalendar.setTime(new Date());
            for (int i = 0; i < count; i++) {
                lCalendar.add(Calendar.DATE, -1);
                Timestamp day = new Timestamp(lCalendar.getTime().getTime());
                testDay = DateUtil.format8chars(day);
                
                rmgr.processReferrer("http://test"+i, "http://test"+i,
                        testWeblog.getHandle(), null, testDay);
            }
            
            TestUtils.endSession(true);
            
        } catch (Exception ex){
            log.error(ex);
            throw new Exception("Test setup failed", ex);
        }
    }
    
    public void tearDown() throws Exception {
        
        try {
            // reset refererSpamWords to original value
            PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
            RollerPropertyData spamprop = pmgr.getPro
 perty("spam.blacklist");
            spamprop.setValue(this.origSpamWords);
            pmgr.store(spamprop);
            
            TestUtils.teardownWeblog(testWeblog.getId());
            TestUtils.teardownUser(testUser.getId());
            
            TestUtils.endSession(true);
        } catch (Exception ex) {
            log.error(ex);
            throw new Exception("Test teardown failed", ex);
        }
    }
    
    
    public void testGetReferersToDate() throws Exception {
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List referers = rmgr.getReferersToDate(testWeblog, testDay);
        assertEquals("Should be one Referer.", referers.size(), 1);
    }
    
    
    public void testRefererProcessing() throws RollerException {
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals("number of refer
 ers should equal count", count, refs.size());
        
        int hits = rmgr.getDayHits(testWeblog);
        assertEquals("There should be one fewer hits than referers", count, hits);
    }
    
    
    public void testApplyRefererFilters() throws Exception {
        
        log.info("Test apply referers (global)");
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals(count, refs.size());
        
        PropertiesManager pmgr = RollerFactory.getRoller().getPropertiesManager();
        RollerPropertyData spamprop = pmgr.getProperty("spam.blacklist");
        String origWords = spamprop.getValue();
        spamprop.setValue(spamprop.getValue() + ", test");
        pmgr.store(spamprop);
        TestUtils.endSession(true);
        
        rmgr.applyRefererFilters();
        TestUtils.endSession(true);
        
        refs = rmgr.getReferers(testWeblog);
      
   assertEquals(0, refs.size());
        
        spamprop = pmgr.getProperty("spam.blacklist");
        spamprop.setValue(origWords);
        pmgr.store(spamprop);
        TestUtils.endSession(true);
    }
    
    
    public void testApplyRefererFiltersWebsite() throws Exception {
        
        log.info("Test apply referers (weblog)");
        
        RefererManager rmgr = RollerFactory.getRoller().getRefererManager();
        
        List refs = rmgr.getReferers(testWeblog);
        assertEquals(count, refs.size());
        String origWords = null;
        
        UserManager umgr = RollerFactory.getRoller().getUserManager();
        testWeblog = umgr.getWebsite(testWeblog.getId());
        origWords = testWeblog.getBlacklist();
        testWeblog.setBlacklist("test");
        umgr.saveWebsite(testWeblog);
        TestUtils.endSession(true);
        
        rmgr.applyRefererFilters();
        TestUtils.endSession(true);
        
        refs = rmgr.getReferers(test
 Weblog);
        assertEquals(0, refs.size());
    }
    
}
\ No newline at end of file

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/UserTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/UserTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/UserTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/UserTest.java Tue Apr 18 14:50:51 2006
@@ -59,7 +59,7 @@
         testUser.setEnabled(Boolean.TRUE);
         
         // make sure test user does not exist
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNull(user);
         
         // add test user
@@ -69,18 +69,18 @@
         
         // make sure test user exists
         user = null;
-        user = mgr.retrieveUser(id);
+        user = mgr.getUser(id);
         assertNotNull(user);
         assertEquals(testUser, user);
         
         // modify user and save
         user.setFullName("testtesttest");
-        mgr.storeUser(user);
+        mgr.saveUser(user);
         TestUtils.endSession(true);
         
         // make sure changes were saved
         user = null;
-        user = mgr.retrieveUser(id);
+        user = mgr.getUser(id);
         assertNotNull(user);
         assertEquals("testtesttest", user.getFullName());
         
@@ -90,7 +90,7 @@
         
         // make sure user no longer exists
         user = null;
-        user = mgr.retrieveUser(id);
+        user = mgr.getUser(id);
         assertNull(user);
     }
     
@@ -108,14 +108,14 @@
         TestUtils.endSession(true);
         
         // lookup by username
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNotNull(user);
         assertEquals(testUser.getUserName(), user.getUserName());
         
         // lookup by id
         String id = user.getId();
         user = null;
-        user = mgr.retrieveUser(id);
+        user = mgr.getUser(id);
         assertNotNull(user);
         assertEquals(testUser.getUserName(), user.getUserName());
         
@@ -137,9 +137,9 @@
         
         // make sure disable users are not returned
         user.setEnabled(Boolean.FALSE);
-        mgr.storeUser(user);
+        mgr.saveUser(user);
         user = null;
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNull(user);
         
         // remove test user
@@ -161,7 +161,7 @@
         TestUtils.endSession(true);
         
         // verify user has 2 roles, admin & editor
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNotNull(user);
         assertEquals(2, user.getRoles().size());
         assertTrue(user.hasRole("editor"));
@@ -169,12 +169,12 @@
         
         // remove role
         user.revokeRole("admin");
-        mgr.storeUser(user);
+        mgr.saveUser(user);
         TestUtils.endSession(true);
         
         // check that role was removed
         user = null;
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNotNull(user);
         assertEquals(1, user.getRoles().size());
         assertTrue(user.hasRole("editor"));
@@ -182,12 +182,12 @@
         
         // add role
         user.grantRole("admin");
-        mgr.storeUser(user);
+        mgr.saveUser(user);
         TestUtils.endSession(true);
         
         // check that role was added
         user = null;
-        user = mgr.getUser(testUser.getUserName());
+        user = mgr.getUserByUsername(testUser.getUserName());
         assertNotNull(user);
         assertEquals(2, user.getRoles().size());
         assertTrue(user.hasRole("editor"));

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogCategoryTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogCategoryTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogCategoryTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogCategoryTest.java Tue Apr 18 14:50:51 2006
@@ -102,7 +102,7 @@
         assertEquals(newCat, cat);
         
         // make sure category count increased
-        testWeblog = RollerFactory.getRoller().getUserManager().retrieveWebsite(testWeblog.getId());
+        testWeblog = RollerFactory.getRoller().getUserManager().getWebsite(testWeblog.getId());
         assertEquals(numCats+1, mgr.getRootWeblogCategory(testWeblog).getWeblogCategories().size());
         
         // update category
@@ -126,7 +126,7 @@
         assertNull(cat);
         
         // make sure category count decreased
-        testWeblog = RollerFactory.getRoller().getUserManager().retrieveWebsite(testWeblog.getId());
+        testWeblog = RollerFactory.getRoller().getUserManager().getWebsite(testWeblog.getId());
         assertEquals(numCats, mgr.getRootWeblogCategory(testWeblog).getWeblogCategories().size());
     }
     

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogPageTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogPageTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogPageTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogPageTest.java Tue Apr 18 14:50:51 2006
@@ -89,7 +89,7 @@
         WeblogTemplate template = null;
         
         // create template
-        mgr.storePage(testPage);
+        mgr.savePage(testPage);
         TestUtils.endSession(true);
         
         // check that create was successful
@@ -100,7 +100,7 @@
         
         // update template
         template.setName("testtesttest");
-        mgr.storePage(template);
+        mgr.savePage(template);
         TestUtils.endSession(true);
         
         // check that update was successful
@@ -129,12 +129,12 @@
         WeblogTemplate page = null;
         
         // create page
-        mgr.storePage(testPage);
+        mgr.savePage(testPage);
         String id = testPage.getId();
         TestUtils.endSession(true);
         
         // lookup by id
-        page = mgr.retrievePage(id);
+        page = mgr.getPage(id);
         assertNotNull(page);
         assertEquals(testPage.getContents(), page.getContents());
         

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogTest.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogTest.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogTest.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/business/WeblogTest.java Tue Apr 18 14:50:51 2006
@@ -88,24 +88,24 @@
         assertNull(weblog);
         
         // add test weblog
-        mgr.createWebsite(testWeblog);
+        mgr.addWebsite(testWeblog);
         String id = testWeblog.getId();
         TestUtils.endSession(true);
         
         // make sure test weblog exists
         weblog = null;
-        weblog = mgr.retrieveWebsite(id);
+        weblog = mgr.getWebsite(id);
         assertNotNull(weblog);
         assertEquals(testWeblog, weblog);
         
         // modify weblog and save
         weblog.setName("testtesttest");
-        mgr.storeWebsite(weblog);
+        mgr.saveWebsite(weblog);
         TestUtils.endSession(true);
         
         // make sure changes were saved
         weblog = null;
-        weblog = mgr.retrieveWebsite(id);
+        weblog = mgr.getWebsite(id);
         assertNotNull(weblog);
         assertEquals("testtesttest", weblog.getName());
         
@@ -115,7 +115,7 @@
         
         // make sure weblog no longer exists
         weblog = null;
-        weblog = mgr.retrieveWebsite(id);
+        weblog = mgr.getWebsite(id);
         assertNull(weblog);
     }
     
@@ -134,7 +134,7 @@
         TestUtils.endSession(true);
         
         // lookup by id
-        weblog = mgr.retrieveWebsite(testWeblog1.getId());
+        weblog = mgr.getWebsite(testWeblog1.getId());
         assertNotNull(weblog);
         assertEquals(testWeblog1.getHandle(), weblog.getHandle());
         
@@ -146,7 +146,7 @@
         
         // make sure disable weblogs are not returned
         weblog.setEnabled(Boolean.FALSE);
-        mgr.storeWebsite(weblog);
+        mgr.saveWebsite(weblog);
         weblog = null;
         weblog = mgr.getWebsiteByHandle(testWeblog1.getHandle());
         assertNull(weblog);
@@ -154,7 +154,7 @@
         // restore enabled state
         weblog = mgr.getWebsiteByHandle(testWeblog1.getHandle(), Boolean.FALSE);
         weblog.setEnabled(Boolean.TRUE);
-        mgr.storeWebsite(weblog);
+        mgr.saveWebsite(weblog);
         TestUtils.endSession(true);
         weblog = null;
         weblog = mgr.getWebsiteByHandle(testWeblog1.getHandle());
@@ -169,7 +169,7 @@
         
         // make sure disabled weblogs are not returned
         weblog.setEnabled(Boolean.FALSE);
-        mgr.storeWebsite(weblog);
+        mgr.saveWebsite(weblog);
         TestUtils.endSession(true);
         List weblogs2 = mgr.getWebsites(testUser, Boolean.TRUE, Boolean.TRUE);
         assertEquals(1, weblogs2.size());
@@ -178,7 +178,7 @@
         
         // make sure inactive weblogs are not returned
         weblog.setActive(Boolean.FALSE);
-        mgr.storeWebsite(weblog);
+        mgr.saveWebsite(weblog);
         TestUtils.endSession(true);
         List weblogs3 = mgr.getWebsites(testUser, Boolean.TRUE, Boolean.TRUE);
         assertEquals(0, weblogs3.size());

Modified: incubator/roller/branches/roller-newbackend/tests/org/roller/presentation/StrutsActionTestBase.java
URL: http://svn.apache.org/viewcvs/incubator/roller/branches/roller-newbackend/tests/org/roller/presentation/StrutsActionTestBase.java?rev=395059&r1=395058&r2=395059&view=diff
==============================================================================
--- incubator/roller/branches/roller-newbackend/tests/org/roller/presentation/StrutsActionTestBase.java (original)
+++ incubator/roller/branches/roller-newbackend/tests/org/roller/presentation/StrutsActionTestBase.java Tue Apr 18 14:50:51 2006
@@ -57,7 +57,7 @@
         
         HttpSession session = mockRequest.getSession(true);        
         UserManager umgr = getRoller().getUserManager();
-        UserData user = umgr.getUser(username);
+        UserData user = umgr.getUserByUsername(username);
 
         RollerSession rollerSession = new RollerSession();
         rollerSession.setAuthenticatedUser(user);



Mime
View raw message