Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/exception/UserException.java
===================================================================
diff -u -r79758294f0dfdfd6f805b9232fe3886b1a5b84ae -rfc947ff9a995fcf7fb1ffb39b165340c50140379
--- lams_common/src/java/org/lamsfoundation/lams/usermanagement/exception/UserException.java (.../UserException.java) (revision 79758294f0dfdfd6f805b9232fe3886b1a5b84ae)
+++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/exception/UserException.java (.../UserException.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379)
@@ -1,16 +1,29 @@
-/*
- * Created on Apr 5, 2005
- *
- * TODO To change the template for this generated file go to
- * Window - Preferences - Java - Code Style - Code Templates
+/****************************************************************
+ * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org)
+ * =============================================================
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ * USA
+ *
+ * http://www.gnu.org/licenses/gpl.txt
+ * ****************************************************************
*/
package org.lamsfoundation.lams.usermanagement.exception;
/**
- * @author Minhas
- *
- * TODO To change the template for this generated type comment go to
- * Window - Preferences - Java - Code Style - Code Templates
+ * @author Manpreet Minhas
*/
public class UserException extends Exception {
@@ -20,5 +33,24 @@
public UserException(String message){
super(message);
}
+ /**
+ * Constructor for wrapping the throwable object
+ * @param cause
+ */
+ public UserException(Throwable cause)
+ {
+ super(cause);
+ }
+ /**
+ * Constructor for wrapping both the customized error message and
+ * throwable exception object.
+ * @param message
+ * @param cause
+ */
+ public UserException(String message, Throwable cause)
+ {
+ super(message, cause);
+ }
+
}
Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/IUserManagementService.java
===================================================================
diff -u -r53475fdb1c711c8ea4034499ffa0380d8da83439 -rfc947ff9a995fcf7fb1ffb39b165340c50140379
--- lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/IUserManagementService.java (.../IUserManagementService.java) (revision 53475fdb1c711c8ea4034499ffa0380d8da83439)
+++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/IUserManagementService.java (.../IUserManagementService.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379)
@@ -1,7 +1,24 @@
-/*
- * Created on Nov 22, 2004
- *
- * Last modified on Nov 22, 2004
+/****************************************************************
+ * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org)
+ * =============================================================
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ * USA
+ *
+ * http://www.gnu.org/licenses/gpl.txt
+ * ****************************************************************
*/
package org.lamsfoundation.lams.usermanagement.service;
@@ -232,11 +249,10 @@
*/
public AuthenticationMethod getAuthenticationMethodByName(String name);
- /**
- * Creates a user
- *
- * @param user the user to be created
- */
+ /**
+ *
+ * @param user the user to be created
+ */
public void createUser(User user);
/**
@@ -298,6 +314,10 @@
*/
public Integer saveOrganisation(Organisation organisation,Integer userID);
+ /***********************************
+ * Methods added by Manpreet Minhas
+ * ********************************/
+
/**
* This method saves a new User to the underlying database while
* creating his default workspace and workspaceFolder
@@ -324,19 +344,9 @@
* @param workspaceFolderType The type of folder to be created.
* @return WorkspaceFolder The new WorkspaceFolder object
*/
- public WorkspaceFolder createWorkspaceFolder(Workspace workspace,Integer userID, Integer workspaceFolderType);
+ public WorkspaceFolder createWorkspaceFolder(Workspace workspace,Integer userID, Integer workspaceFolderType);
/**
- * Returns the workspace related information for the given
- * user.
- *
- * @param userID The user_id of the User
- * @return String The required information in WDDX format
- * @throws IOException
- */
- public String getWorkspace(Integer userID)throws IOException;
-
- /**
* This method returns the same information as
* in above method
* getOrganisationsForUserByRole(User user, String roleName)
Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/UserManagementService.java
===================================================================
diff -u -re5d12a94858623863c4bee7851f421970acd62ca -rfc947ff9a995fcf7fb1ffb39b165340c50140379
--- lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/UserManagementService.java (.../UserManagementService.java) (revision e5d12a94858623863c4bee7851f421970acd62ca)
+++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/service/UserManagementService.java (.../UserManagementService.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379)
@@ -1,7 +1,24 @@
-/*
- * Created on Nov 22, 2004
- *
- * Last modified on Nov 22, 2004
+/****************************************************************
+ * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org)
+ * =============================================================
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ * USA
+ *
+ * http://www.gnu.org/licenses/gpl.txt
+ * ****************************************************************
*/
package org.lamsfoundation.lams.usermanagement.service;
@@ -11,8 +28,6 @@
import java.util.ArrayList;
import java.util.Iterator;
import java.util.Vector;
-
-import org.lamsfoundation.lams.learningdesign.LearningDesign;
import org.lamsfoundation.lams.learningdesign.dao.ILearningDesignDAO;
import org.lamsfoundation.lams.usermanagement.dao.IAuthenticationMethodDAO;
import org.lamsfoundation.lams.usermanagement.dao.IOrganisationDAO;
@@ -35,13 +50,11 @@
import org.lamsfoundation.lams.util.wddx.FlashMessage;
/**
- * TODO Add description here
- *
*
* View Source *
* - * @author Fei Yang + * @author Fei Yang, Manpreet Minhas */ public class UserManagementService implements IUserManagementService { @@ -361,6 +374,10 @@ public void setUserManagementWorkspaceDAO(IWorkspaceDAO workspaceDAO) { this.workspaceDAO = workspaceDAO; } + + /********************************************* + * Utility Methods added by Manpreet Minhas + *********************************************/ /** * @see org.lamsfoundation.lams.usermanagement.service.IUserManagementService#saveOrganisation(org.lamsfoundation.lams.usermanagement.Organisation, @@ -430,6 +447,16 @@ return user.getUserId(); } + /** + * This is a utility method required by the above method + *saveUser
. It adds a new record to the
+ * underlying database table indicating the organisation
+ * to which this user belongs
+ *
+ * @param user
+ * @param roleID
+ * @return Integer
+ */
private Integer createUserOrganisation(User user, Integer roleID) {
UserOrganisation userOrganisation = new UserOrganisation();
userOrganisation.setOrganisation(user.getBaseOrganisation());
@@ -441,6 +468,16 @@
return userOrganisation.getUserOrganisationId();
}
+ /**
+ * This is a utility method required by the above method
+ * createUserOrganisation
. It adds a new record
+ * to the underlying database table indicating the Role that
+ * the given user has in the Organisation.
+ *
+ * @param userOrganisation
+ * @param roleID
+ * @return UserOrganisationRole
+ */
private UserOrganisationRole createUserOrganisationRole(
UserOrganisation userOrganisation, Integer roleID) {
UserOrganisationRole userOrganisationRole = new UserOrganisationRole();
@@ -449,103 +486,14 @@
userOrganisationRoleDAO.saveUserOrganisationRole(userOrganisationRole);
return userOrganisationRole;
}
-
- /** TODO check if a user is authorized to complete this operation */
- public String moveLearningDesign(Long learningDesignID,
- Integer targetWorkspaceFolderID, Integer userID) throws IOException {
- LearningDesign learningDesign = learningDesignDAO
- .getLearningDesignById(learningDesignID);
- if (learningDesign != null) {
- WorkspaceFolder workspaceFolder = workspaceFolderDAO
- .getWorkspaceFolderByID(targetWorkspaceFolderID);
- if (workspaceFolder != null) {
- learningDesign.setWorkspaceFolder(workspaceFolder);
- learningDesignDAO.update(learningDesign);
- flashMessage = new FlashMessage("moveLearningDesign",
- targetWorkspaceFolderID);
- } else {
- flashMessage = new FlashMessage("moveLearningDesign",
- "No such target workspaceFolder with a workspace_folder_id of :"
- + targetWorkspaceFolderID + " exists",
- FlashMessage.ERROR);
- }
- } else {
- flashMessage = new FlashMessage("moveLearningDesign",
- "No such learning design with a learning_design_id of:"
- + learningDesignID + " exists", FlashMessage.ERROR);
- }
- return flashMessage.serializeMessage();
- }
-
/**
- * TODO check if a user is authorized to complete this operation As of now I
- * am assuming that the folders CANNOT be moved across different workspaces.
- * If they can be moved in that case the signature of this method would be
- * changed
- */
- public void moveWorkspaceFolder(Integer currentWorkspaceFolderID,
- Integer targetWorkspaceFolderID, Integer userID) {
- WorkspaceFolder currentWorkspaceFolder = workspaceFolderDAO
- .getWorkspaceFolderByID(currentWorkspaceFolderID);
- WorkspaceFolder targetWorkspaceFolder = workspaceFolderDAO
- .getWorkspaceFolderByID(targetWorkspaceFolderID);
- if (currentWorkspaceFolder != null && targetWorkspaceFolder != null) {
- /** TODO move the contents of this folder */
- currentWorkspaceFolder
- .setParentWorkspaceFolder(targetWorkspaceFolder);
- workspaceFolderDAO.update(currentWorkspaceFolder);
- }
- }
-
- /**
- * TODO check if a user is authorized to complete this operation
- */
- public void renameFolder(Integer workspaceFolderID, String newName,
- Integer userID) {
- WorkspaceFolder workspaceFolder = workspaceFolderDAO
- .getWorkspaceFolderByID(workspaceFolderID);
- if (workspaceFolder != null) {
- workspaceFolder.setName(newName);
- workspaceFolderDAO.update(workspaceFolder);
- }
- }
-
- /** TODO check if a user is authorized to complete this operation */
- public void renameLearningDesign(Long learningDesignID, String title,
- Integer userID) {
- LearningDesign learningDesign = learningDesignDAO
- .getLearningDesignById(learningDesignID);
- if (learningDesign != null) {
- learningDesign.setTitle(title);
- learningDesignDAO.update(learningDesign);
- }
- }
-
- /**
* @param learningDesignDAO
* The learningDesignDAO to set.
*/
public void setLearningDesignDAO(ILearningDesignDAO learningDesignDAO) {
this.learningDesignDAO = learningDesignDAO;
}
-
/**
- * @see org.lamsfoundation.lams.usermanagement.service.IUserManagementService#getWorkspace(java.lang.Integer)
- */
- public String getWorkspace(Integer userID) throws IOException {
- User user = userDAO.getUserById(userID);
- if (user != null) {
- Workspace workspace = user.getWorkspace();
- flashMessage = new FlashMessage("getWorkspace", workspace
- .getWorkspaceDTO());
- } else
- flashMessage = FlashMessage.getNoSuchUserExists("getWorkspace",
- userID);
-
- return flashMessage.serializeMessage();
- }
-
- /**
* @see org.lamsfoundation.lams.usermanagement.service.IUserManagementService#getWDDXForOrganisationsForUserByRole(java.lang.Integer,
* java.lang.String)
*/
Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/AdminPreparer.java
===================================================================
diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379
--- lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/AdminPreparer.java (.../AdminPreparer.java) (revision 19c9010eff6be2e29657beed94349a978088650f)
+++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/AdminPreparer.java (.../AdminPreparer.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379)
@@ -1,7 +1,24 @@
-/*
- * Created on 2005-1-28
- *
- * Last modified on 2005-1-28
+/****************************************************************
+ * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org)
+ * =============================================================
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+ * USA
+ *
+ * http://www.gnu.org/licenses/gpl.txt
+ * ****************************************************************
*/
package org.lamsfoundation.lams.usermanagement.util;
@@ -18,8 +35,6 @@
import org.lamsfoundation.lams.web.AttributeNames;
/**
- * TODO Add description here
- *
* * View Source *
Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/ExcelUserImportFileParser.java =================================================================== diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/ExcelUserImportFileParser.java (.../ExcelUserImportFileParser.java) (revision 19c9010eff6be2e29657beed94349a978088650f) +++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/ExcelUserImportFileParser.java (.../ExcelUserImportFileParser.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,7 +1,24 @@ -/* - * Created on 2005-1-18 - * - * Last modified on 2005-1-18 +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.usermanagement.util; @@ -29,8 +46,6 @@ import org.lamsfoundation.lams.usermanagement.Organisation; /** - * TODO Add description here - * ** View Source *
Index: lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/IUserImportFileParser.java =================================================================== diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/IUserImportFileParser.java (.../IUserImportFileParser.java) (revision 19c9010eff6be2e29657beed94349a978088650f) +++ lams_common/src/java/org/lamsfoundation/lams/usermanagement/util/IUserImportFileParser.java (.../IUserImportFileParser.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,7 +1,24 @@ -/* - * Created on 2005-1-19 - * - * Last modified on 2005-1-19 +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.usermanagement.util; @@ -12,8 +29,6 @@ import org.lamsfoundation.lams.usermanagement.Organisation; /** - * TODO Add description here - * ** View Source *
Index: lams_common/src/java/org/lamsfoundation/lams/util/ConfigurationLoader.java =================================================================== diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/src/java/org/lamsfoundation/lams/util/ConfigurationLoader.java (.../ConfigurationLoader.java) (revision 19c9010eff6be2e29657beed94349a978088650f) +++ lams_common/src/java/org/lamsfoundation/lams/util/ConfigurationLoader.java (.../ConfigurationLoader.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,7 +1,24 @@ -/* - * Created on 2005-1-6 - * - * Last modified on 2005-1-6 +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.util; @@ -20,8 +37,6 @@ /** - * TODO Add description here - * ** View Source *
Index: lams_common/src/java/org/lamsfoundation/lams/util/XmlFileLoader.java =================================================================== diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/src/java/org/lamsfoundation/lams/util/XmlFileLoader.java (.../XmlFileLoader.java) (revision 19c9010eff6be2e29657beed94349a978088650f) +++ lams_common/src/java/org/lamsfoundation/lams/util/XmlFileLoader.java (.../XmlFileLoader.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,7 +1,24 @@ -/* - * Created on 9/12/2004 - * - * Last modified on 9/12/2004 +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.util; @@ -22,8 +39,6 @@ /** - * TODO Add description here - * ** View Source *
Fisheye: Tag fc947ff9a995fcf7fb1ffb39b165340c50140379 refers to a dead (removed) revision in file `lams_common/src/java/org/lamsfoundation/lams/util/wddx/LDWDDXValueObjectFactory.java'. Fisheye: No comparison available. Pass `N' to diff? Fisheye: Tag fc947ff9a995fcf7fb1ffb39b165340c50140379 refers to a dead (removed) revision in file `lams_common/src/java/org/lamsfoundation/lams/util/wddx/LDWDDXValueObjectStorer.java'. Fisheye: No comparison available. Pass `N' to diff? Index: lams_common/src/java/org/lamsfoundation/lams/web/AttributeNames.java =================================================================== diff -u -r19c9010eff6be2e29657beed94349a978088650f -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/src/java/org/lamsfoundation/lams/web/AttributeNames.java (.../AttributeNames.java) (revision 19c9010eff6be2e29657beed94349a978088650f) +++ lams_common/src/java/org/lamsfoundation/lams/web/AttributeNames.java (.../AttributeNames.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,13 +1,28 @@ -/* - * Created on 2005-1-14 - * - * Last modified on 2005-1-14 +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.web; /** - * TODO Add description here - * ** View Source *
Index: lams_common/test/java/org/lamsfoundation/lams/usermanagement/TestUserManagementService.java =================================================================== diff -u -r53475fdb1c711c8ea4034499ffa0380d8da83439 -rfc947ff9a995fcf7fb1ffb39b165340c50140379 --- lams_common/test/java/org/lamsfoundation/lams/usermanagement/TestUserManagementService.java (.../TestUserManagementService.java) (revision 53475fdb1c711c8ea4034499ffa0380d8da83439) +++ lams_common/test/java/org/lamsfoundation/lams/usermanagement/TestUserManagementService.java (.../TestUserManagementService.java) (revision fc947ff9a995fcf7fb1ffb39b165340c50140379) @@ -1,8 +1,24 @@ -/* - * Created on Mar 22, 2005 - * - * TODO To change the template for this generated file go to - * Window - Preferences - Java - Code Style - Code Templates +/**************************************************************** + * Copyright (C) 2005 LAMS Foundation (http://lamsfoundation.org) + * ============================================================= + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 + * USA + * + * http://www.gnu.org/licenses/gpl.txt + * **************************************************************** */ package org.lamsfoundation.lams.usermanagement; @@ -19,9 +35,6 @@ /** * @author Manpreet Minhas - * - * TODO To change the template for this generated type comment go to - * Window - Preferences - Java - Code Style - Code Templates */ public class TestUserManagementService extends AbstractLamsTestCase { @@ -73,10 +86,6 @@ user.setBaseOrganisation(organisationDAO.getOrganisationById(new Integer(1))); assertNotNull(userManagementService.saveUser(user, new Integer(3))); } - public void testMoveLearningDesign()throws IOException{ - String packet = userManagementService.moveLearningDesign(new Long(1),new Integer(4),new Integer(1)); - System.out.println(packet); - } public void testGetOrganisationsForUserByRole()throws IOException{ String packet = userManagementService.getWDDXForOrganisationsForUserByRole(new Integer(4),"AUTHOR"); System.out.println(packet); @@ -85,14 +94,11 @@ String packet = userManagementService.getUsersFromOrganisationByRole(new Integer(4),"AUTHOR"); System.out.println(packet); } - /* (non-Javadoc) + /** + * (non-Javadoc) * @see org.lamsfoundation.lams.AbstractLamsTestCase#getHibernateSessionFactoryName() */ protected String getHibernateSessionFactoryName() { return "coreSessionFactory"; } - public void testGetWorkspace()throws IOException{ - String str = userManagementService.getWorkspace(new Integer(4)); - System.out.println(str); - } }