亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? usermodel.java

?? 一個論壇程序的簡單實現(xiàn)
?? JAVA
字號:
/*
 * Copyright (c) 2003, Rafael Steil
 * All rights reserved.
 * 
 * Redistribution and use in source and binary forms, 
 * with or without modification, are permitted provided 
 * that the following conditions are met:
 * 
 * 1) Redistributions of source code must retain the above 
 * copyright notice, this list of conditions and the 
 * following  disclaimer.
 * 2)  Redistributions in binary form must reproduce the 
 * above copyright notice, this list of conditions and 
 * the following disclaimer in the documentation and/or 
 * other materials provided with the distribution.
 * 3) Neither the name of "Rafael Steil" nor 
 * the names of its contributors may be used to endorse 
 * or promote products derived from this software without 
 * specific prior written permission.
 * 
 * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT 
 * HOLDERS AND CONTRIBUTORS "AS IS" AND ANY 
 * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, 
 * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF 
 * MERCHANTABILITY AND FITNESS FOR A PARTICULAR 
 * PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL 
 * THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE 
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, 
 * EXEMPLARY, OR CONSEQUENTIAL DAMAGES 
 * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 
 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, 
 * OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
 * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER 
 * IN CONTRACT, STRICT LIABILITY, OR TORT 
 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 
 * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF 
 * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE
 * 
 * This file creating date: Feb 19, 2003 / 8:56:56 PM
 * The JForum Project
 * http://www.jforum.net 
 */
package net.jforum.model;

import java.security.NoSuchAlgorithmException;
import java.util.HashMap;
import java.util.List;

import net.jforum.entities.User;

/**
  * Model interface for {@link net.jforum.User}.
 * This interface defines methods which are expected to be
 * implementd by a specific data access driver. The intention is
 * to provide all functionality needed to update, insert, delete and
 * select some specific data.
 * 
 * @author Rafael Steil
 * @version $Id: UserModel.java,v 1.12 2004/11/05 03:29:49 rafaelsteil Exp $
 */
public interface UserModel 
{
	/**
	 * Gets a specific <code>User</code>.
	 * 
	 * @param userId The User ID to search
	 * @return <code>User</code>object containing all the information
	 * @throws Exception
	 * @see #selectAll
	 */
	public User selectById(int userId) throws Exception;
	
	/**
	 * Gets a specific <code>User</code>.
	 * 
	 * @param username The User name to search
	 * @return <code>User</code>object containing all the information
	 * @throws Exception
	 * @see #selectAll
	 */
	public User selectByName(String username) throws Exception;
	
	/**
	 * Gets all users
	 * 
	 * @return <code>ArrayList</code> with the users. Each entry is an <code>User</code> object
	 * @throws Exception
	 */
	public List selectAll() throws Exception;
	
	/**
	 * Finds an user by matching an input string. 
	 * 
	 * @param input The username to search. May be part of the username. 
	 * The method will match all users who have the input string as 
	 * part of their usernames.
	 * @param exactMath Set to <code>true</code> to get the user data related to 
	 * the username passed as argument, and set it to <code>false</code> to 
	 * search all users who match the criteria. 
	 * @return <code>List</code> with the found users. Each entry is an 
	 * <code>User</code> object, where only the <i>id</i> and <i>username</i>
	 * members are filled.
	 * @throws Exception exact
	 */
	public List findByName(String input, boolean exactMath) throws Exception;
	
	/**
	 * Gets all users
	 *
	 * @param startFrom Index to start fetching from
	 * @param count Number of records to retrieve
	 * @return <code>ArrayList</code> with the users. Each entry is an <code>User</code> object
	 * @throws Exception
	 */
	public List selectAll(int startFrom, int count) throws Exception;
	

	/**
	 * Deletes an user.
	 * 
	 * @param userId The user ID to delete
	 * @throws Exception
	 * @see #undelete(int)
	 */
	public void delete(int userId) throws Exception;
	
	/**
	 * Undeletes an user.
	 * The system allows user undeletation because when you 
	 * call {@link #delete(int)} the user isn't fisically deleted of the
	 * database, but just marked as deleted. This is done to ensure
	 * data integrity.
	 * 
	 * @param userId The user ID to undelete
	 * @throws Exception
	 * @see #delete(int)
	 */
	public void undelete(int userId) throws Exception;
	
	/**
	 * Updates a user.
	 * 
	 * @param user Reference to a <code>User</code> object to update
	 * @throws Exception
	 * @see #update(int)
	 */
	public void update(User user) throws Exception;
	
	/**
	 * Adds a new User.
	 * 
	 * @param user Reference to a valid and configured <code>User</code> object
	 * @return The new user id
	 * @throws Exception
	 */
	public int addNew(User user) throws Exception;

	/**
	 * Adds a new user with a predefined user id
	 * 
	 * (added by Pieter for external login support)
	 * @param user Reference to a valid and configured <code>User</code> object, with the user id already set
	 * @throws Exception
	 */
	public void addNewWithId(User user) throws Exception ;
	
	/**
	 * Set the active status.
	 * An user with the active status equals to false cannot be considered
	 * a "oficial", "fully registered" user until its status is set to true. This is
	 * interesting when you want to request user confirmation about registrations,
	 * for example
	 * 
	 * @param userId The user ID to change the status
	 * @param active <code>true</code> or <code>false</code>
	 * @throws Exception
	 */
	public void setActive(int userId, boolean active) throws Exception;
	
	/**
	 * Sets the ranking.
	 * 
	 * @param userId The user ID
	 * @throws Exception
	 */
	public void setRanking(int userId, int rankingId) throws Exception;
	
	/**
	 * Increments the number of posts of the user.
	 * 
	 * @param userId The user ID to increment the number of posts
	 * @throws Exception
	 */
	public void incrementPosts(int userId) throws Exception;
	
	/**
	 * Decrement the number of posts of some user.
	 * 
	 * @param userId The user ID do decrement the number of posts.
	 * @throws Exception
	 */
	public void decrementPosts(int userId) throws Exception;
	
	/**
	 * Gest some piece of information of the last user registered
	 * 
	 * @return <code>HashMap</code> containing the information. The map
	 * has two keys:<br>
	 * <li><b>userName</b>: The username
	 * <li><b>userId</b>: The user's ID 
	 * @throws Exception
	 */
	public HashMap getLastUserInfo() throws Exception;
	
	/**
	 * Gets the total number of users
	 * 
	 * @return The total number of users
	 * @throws Exception
	 */
	public int getTotalUsers() throws Exception;
	
	/**
	 * whether the user is locked or not.
	 * 
	 * @return boolean
	 * @throws Exception
	 */	
	public boolean isDeleted(int user_id) throws Exception;
	
	/***
	 * Checks the existence of some username.
	 * This method is used to ensure that will not be two equal usernames in the database.
	 * 
	 * @param username The username to verify
	 * @return <code>true</code> or <code>false</code>, if the user was found or not, respectively
	 * @throws Exception
	 */
	public boolean isUsernameRegistered(String username) throws Exception;
	
	/**
	 * Validates the user login.
	 * 
	 * @param username The username
	 * @param password The password
	 * @return The user object if the provided information was corret, <code>null</code> if the information was invalid 
	 * @throws Exception
	 */
	public User validateLogin(String username, String password) throws NoSuchAlgorithmException, Exception;
	
	/**
	 * Associate the user to the group
	 * 
	 * @param userId The user id 
	 * @param groupId The group id to associate to
	 * @throws Exception
	 */
	public void addToGroup(int userId, int[] groupId) throws Exception;
	
	/**
	 * Remove the user from the group
	 * 
	 * @param userId The user id
	 * @param groupId The group id to remove the user from
	 */
	public void removeFromGroup(int userId, int[] groupId) throws Exception;
	
	/**
	 * Stores the "lost password" security hash, that was generated
	 * when the user asked the system to get a reminder of his password. 
	 * This hash is used to ensure the information supplied.  
	 * 
	 * @param email The user email
	 * @param hash The hash to store.
	 * @throws Exception
	 */
	public void writeLostPasswordHash(String email, String hash) throws Exception;
	
	/**
	 * Validate the provided security hash against the data stored in our system.
	 * 
	 * @param email The user email
	 * @param hash The supplied security hash
	 * @return <code>true</code> if the data matches ok, of <code>false</code> if it is invalid
	 * @throws Exception
	 */
	public boolean validateLostPasswordHash(String email, String hash) throws Exception;
	
	/**
	 * Writes a new password for the user. 
	 * 
	 * @param password The new password
	 * @param email The user email
	 * @throws Exception
	 */
	public void saveNewPassword(String password, String email) throws Exception;
	
	/**
	 * Gets the username related to the email
	 * 
	 * @param email The email to search for the username
	 * @return The username, if found, or an empty <code>String</code>
	 * @throws Exception
	 */
	public String getUsernameByEmail(String email) throws Exception;
	
	/**
	 * Validate if the activated key matches the one in the database
	 * 
	 * @param userId Which user to validate the activation key?
	 * @param hash The activation key
	 * @return <code>true</code> if the data matches ok, of <code>false</code> if it is invalid
	 * @throws Exception
	 */
	public boolean validateActivationKeyHash(int userId , String hash) throws Exception;

	/**
	 * Set user account to active
	 * 
	 * @param userId Which user account to set active?
	 * @throws Exception
	 */	
	public void writeUserActive(int userId) throws Exception;
}

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
1024成人网| 捆绑变态av一区二区三区| 日本sm残虐另类| a美女胸又www黄视频久久| 欧美丰满嫩嫩电影| 亚洲三级小视频| 国产乱子伦视频一区二区三区 | 免费人成在线不卡| 色婷婷av一区二区三区之一色屋| 精品日韩在线观看| 午夜精品爽啪视频| 91色porny| 国产精品丝袜在线| 国产盗摄女厕一区二区三区| 日韩亚洲电影在线| 午夜影院久久久| 色婷婷久久99综合精品jk白丝| 久久久噜噜噜久久中文字幕色伊伊| 亚瑟在线精品视频| 欧美午夜精品久久久久久超碰| 国产精品久久久久aaaa樱花| 国产又粗又猛又爽又黄91精品| 欧美精品自拍偷拍| 亚洲国产精品影院| 欧美午夜不卡在线观看免费| 亚洲视频 欧洲视频| 99国产精品一区| 亚洲欧洲性图库| av电影在线不卡| 亚洲日穴在线视频| 色综合色综合色综合色综合色综合| 中文字幕不卡在线播放| www.亚洲人| 亚洲欧洲99久久| 色综合久久久久综合体| 亚洲视频免费在线观看| 91免费看视频| 亚洲一区二区三区小说| 欧美日韩日日夜夜| 日韩中文字幕91| 精品福利在线导航| 丁香网亚洲国际| 亚洲私人黄色宅男| 欧美区一区二区三区| 日韩国产在线一| 26uuu亚洲综合色欧美 | 国产女人aaa级久久久级| 国产精品一区二区三区乱码| 亚洲国产精品ⅴa在线观看| 99热这里都是精品| 午夜精品成人在线视频| 欧美一级一区二区| 成人性视频网站| 一区二区三区四区精品在线视频| 欧美理论片在线| 国产成人av电影在线| 一区二区三区四区在线播放| 日韩视频一区在线观看| 懂色av一区二区夜夜嗨| 亚洲高清不卡在线观看| 精品免费一区二区三区| 99久久精品免费看| 奇米色一区二区| 亚洲手机成人高清视频| 日韩亚洲欧美一区二区三区| 成人激情免费电影网址| 图片区小说区区亚洲影院| 2023国产一二三区日本精品2022| 99久久er热在这里只有精品15| 日韩成人精品视频| 最新热久久免费视频| 日韩一区二区麻豆国产| jiyouzz国产精品久久| 日韩激情中文字幕| 亚洲欧洲av在线| 精品黑人一区二区三区久久 | 亚洲欧美日韩人成在线播放| 91精品国产麻豆| 91麻豆国产精品久久| 久久99精品久久久久久| 亚洲综合偷拍欧美一区色| 久久久99精品免费观看不卡| 欧美日韩精品专区| 99久久亚洲一区二区三区青草| 奇米一区二区三区| 午夜精品成人在线视频| 亚洲精品乱码久久久久久黑人| 精品国产乱码久久久久久蜜臀| 欧美性欧美巨大黑白大战| 成人动漫一区二区| 国产一区二区三区蝌蚪| 日本三级亚洲精品| 亚洲成人在线免费| 亚洲人成在线播放网站岛国| 国产无遮挡一区二区三区毛片日本| 欧美精三区欧美精三区| 欧美日韩中文一区| 91网站在线播放| 不卡在线观看av| 国产成人精品免费视频网站| 国内精品国产成人国产三级粉色| 婷婷丁香激情综合| 亚洲成人黄色小说| 亚洲国产精品一区二区www| 亚洲日本一区二区| 日本一区二区高清| 亚洲国产成人在线| 欧美国产日韩精品免费观看| 久久亚洲二区三区| 久久精品亚洲精品国产欧美 | 国产精品乱人伦| 欧美国产乱子伦| 国产精品人成在线观看免费| 国产色综合一区| 国产精品女同一区二区三区| 国产欧美中文在线| 国产精品美女久久久久久久网站| 国产欧美日韩不卡| 亚洲欧美综合在线精品| 亚洲激情一二三区| 亚洲狠狠爱一区二区三区| 亚洲成a人片在线不卡一二三区| 亚洲高清一区二区三区| 天天影视涩香欲综合网 | 亚洲成人动漫av| 视频在线观看一区二区三区| 免费不卡在线观看| 国产麻豆成人精品| 91麻豆国产福利精品| 欧美亚洲动漫精品| 欧美一区二区三区免费大片| 日韩三级.com| 久久精品亚洲乱码伦伦中文| 亚洲色图制服丝袜| 亚洲一级在线观看| 久久99国产精品麻豆| 国产v日产∨综合v精品视频| 91在线你懂得| 日韩一级二级三级| 国产日本一区二区| 久久国产精品99久久久久久老狼| 韩国女主播成人在线| 99久久综合精品| 91精品在线麻豆| 国产欧美一区二区三区在线老狼| 亚洲私人黄色宅男| 久久草av在线| 91美女在线观看| 精品粉嫩超白一线天av| 亚洲乱码国产乱码精品精可以看 | 曰韩精品一区二区| 蜜桃久久av一区| 99久久婷婷国产综合精品电影| 欧美制服丝袜第一页| 精品国产91洋老外米糕| 亚洲免费在线看| 激情久久五月天| 欧美日韩在线免费视频| 中文字幕精品在线不卡| 首页国产丝袜综合| 色综合网站在线| 久久亚洲一级片| 日本一区中文字幕| 色综合天天狠狠| 国产欧美日本一区视频| 五月天一区二区三区| voyeur盗摄精品| 日韩精品最新网址| 亚洲v中文字幕| 99久久免费国产| 久久精品一区二区三区av| 青青青爽久久午夜综合久久午夜 | 九九视频精品免费| 精品视频在线免费观看| 18欧美亚洲精品| 国产成+人+日韩+欧美+亚洲| 日韩欧美国产一二三区| 午夜精品123| 欧洲在线/亚洲| 亚洲人成亚洲人成在线观看图片| 国产高清成人在线| 精品国产污网站| 老司机一区二区| 欧美一区二区三区免费观看视频| 亚洲一区在线看| 在线观看日韩国产| 极品少妇xxxx精品少妇| 91精品国产色综合久久不卡蜜臀| 夜色激情一区二区| 在线区一区二视频| 亚洲欧美日本韩国| 色综合色狠狠天天综合色| 日韩一区有码在线| 91视频.com| 樱花影视一区二区| 在线观看欧美日本| 亚洲一区自拍偷拍| 在线不卡的av| 蜜臀久久99精品久久久久久9| 91精品国产高清一区二区三区蜜臀|