guestbookdao.java

来自「tapestry4.0应用,特别适用于初学者」· Java 代码 · 共 75 行

JAVA
75
字号
package com.cucu.tapestry.dao;

import java.util.List;

import org.springframework.dao.DataAccessException;

import com.cucu.tapestry.entity.Guestbook;

/**
 * Guestbook DAO接口类,定义所有与分页无关的DAO 接口
 *
 * @author 绝情酷哥
 * @version 1.0
 */
public interface GuestbookDAO {
    /**
     * @return 返回留言列表
     */
    public List getList() throws DataAccessException;

    /**
     * @param parentId
     * @return 回复总数
     */
    public Integer getCommentCount(Integer parentId) throws DataAccessException;

    /**
     * @return 计算总共花费时间
     */
    public Integer getSumTime() throws DataAccessException;

    /**
     * 根据ID删除一个对象
     *
     * @param id
     * @throws DataAccessException
     */
    public void doDeleteTopic(Integer id) throws DataAccessException;

    /**
     * @return 总数
     */
    public Integer getCount() throws DataAccessException;

    /**
     * 设置置顶操作
     *
     * @param id
     * @throws DataAccessException
     */
    public void doSetTop(Integer id) throws DataAccessException;

    /**
     * 新建或者修改一个guestbook
     *
     * @param gb
     * @throws DataAccessException
     */
    public void doUpdateTopic(Guestbook gb) throws DataAccessException;

    /**
     * 根据ID返回guestbook
     *
     * @param id
     * @return guestbook
     * @throws DataAccessException
     */
    public Guestbook getGuestbook(Integer id) throws DataAccessException;

    /**
     * @return 回复总数
     */
    public Integer getReplyCount(Integer parentId) throws DataAccessException;
}

⌨️ 快捷键说明

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