⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 userleveldao.java

📁 一个不错的bbs论坛系统.对初学者很有帮助
💻 JAVA
字号:
package com.yhbbs.user.itface.dao;

import java.sql.SQLException;
import java.util.List;
import com.yhbbs.user.itface.bean.Grade;
import com.yhbbs.user.itface.bean.UserGroup;

/**
 * <p>Title:论坛用户等级、用户组、用户类型存取模块Interface</p>
 * <li> 论坛用户等级、用户组、用户类型数据处理模块 <br>
 * <br><b>WebSite: www.yyhweb.com</b>
 * <br><b>CopyRight: yyhweb[由由华网]</b>
 * @author stephen
 * @version YHBBS-2.0
 */
public interface UserLevelDao {
	
	/** 根据等级ID或者用户类型取得用户等级名称
	 * @param gid 用户等级ID
	 * @param utype 用户类型
	 * @return String 论坛用户名称
	 * @throws SQLException
	 */
	public abstract String getGradeName(int gid,int utype) throws SQLException;
	
	/** 根据ID取得用户等级基本发帖数目
	 * @param gid 用户等级ID
	 * @return int 基本发帖数目
	 * @throws SQLException
	 */
	public abstract int getGradePost(int gid) throws SQLException;
	
	/** 根据ID取得用户等级信息
	 * @param gid 用户等级ID
	 * @return Grade 论坛用户等级
	 * @throws SQLException
	 */
	public abstract Grade getGrade(int gid) throws SQLException;

	/** 取得所有用户等级
	 * @return list 用户等级列表
	 * @throws SQLException
	 */
	public abstract List getAllGrades() throws SQLException;
	
	// UserType
	
	/** 根据类型ID取得用户类型名称
	 * @param id 用户类型ID
	 * @return String 用户类型名称
	 * @throws SQLException
	 */
	public abstract String getUserTypeName(int id) throws SQLException;
	
	/** 取得用户所有类型
	 * @return List 用户类型名称列表
	 * @throws SQLException
	 */
	public abstract List getUserTypes() throws SQLException;
	
	// UserGroup
	
	/** 增加用户组
	 * @param ugroup 用户组
	 * @throws SQLException
	 */
	public abstract void addUserGroup(UserGroup ugroup) throws SQLException;
	
	/** 修改用户组
	 * @param ugroup 用户组
	 * @return true:修改成功 false:修改失败
	 * @throws SQLException
	 */
	public abstract boolean editUserGroup(UserGroup ugroup) throws SQLException;
	
	/** 删除用户组
	 * @param gid 用户组Id
	 * @return true:删除成功 false:删除失败
	 * @throws SQLException
	 */
	public abstract boolean delUserGroup(int gid) throws SQLException;
	
	/** 根据组ID取得用户组名称
	 * @param id 用户组ID
	 * @return String 用户组名称
	 * @throws SQLException
	 */
	public abstract String getUserGroupName(int id) throws SQLException;
	
	/** 取得用户所有组
	 * @return List 用户组名称列表
	 * @throws SQLException
	 */
	public abstract List getUserGroups() throws SQLException;
	
	/** 修改用户级别
	 * @param grade 用户级别
	 * @return true:修改成功 false:修改失败
	 * @throws SQLException
	 */
	public abstract boolean updateGrade(Grade grade) throws SQLException;
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -