Log In | Get Help   
Home My Page Projects Code Snippets Project Openings Accounting and Billing Portal
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files
[abportal] View of /src/main/java/eu/smartlm/abs/portal/security/login/dao/UserDao.java
[abportal] / src / main / java / eu / smartlm / abs / portal / security / login / dao / UserDao.java Repository:
ViewVC logotype

View of /src/main/java/eu/smartlm/abs/portal/security/login/dao/UserDao.java

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1 - (download) (annotate)
Wed Jul 28 10:05:51 2010 UTC (13 years, 9 months ago) by dgarcia
File size: 1186 byte(s)
First code commit
package eu.smartlm.abs.portal.security.login.dao;

import java.util.List;

import eu.smartlm.abs.portal.security.login.model.User;

/**
 * Interface that abstract the User database implementation from the rest of the project
 * @author David García Pérez - CESGA
 **/
public interface UserDao {
	public static int USER_ADDED = 100;
	public static int ALREADY_USED_USERNAME = 200; 
	/**
	 * Gives back a list with all the users stored in teh database
	 * @return a list of all users
	 */
	public List<User> getUsers();

	/**
	 * Adds an user to the database
	 * @param user to be added
	 */
	public int addUser(User user);

	/**
	 * Removes an specific user from the database
	 * @param username of the user to be removed
	 */
	public void removeUser(String username);

	/**
	 * Edits the information of an user stored in the database
	 * @param user with the same id but with the updated information
	 */
	public void editUser(User user);

	/**
	 * Retrieves an user form the database by username field
	 * @param username of the user to be retrieved
	 * @return the User or <code>null</code> if the users does not exists in the database
	 */
	public User getUser(String username);
}

root@forge.cesga.es
ViewVC Help
Powered by ViewVC 1.0.0  

Powered By FusionForge