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

📄 dataaccessor.java

📁 前一段时间看《数据访问模式》时
💻 JAVA
字号:
/**
 *@version 1.0
 *@author cbf107
 *@link http://www.cbf107.com
*/
package com.cbf107.www;

/*
 * 数据访问器接口
 */

import java.util.List;


public interface DataAccessor {
	   //读取表数据
	   /*
	    * table是要读取的表名
	    * colums是要读取的字段名
	    * selectionRow是读取的条件
	    * sortColumns是对读取记录的排序
	    */
	   public List read(String table, String[] columns, Row selectionRow, String[] sortColumns,String order) throws DataException;   	  
	   //插入表数据
	   /*
	    * table是要插入数据的表名
	    * rows是要插入的字段和数据
	    */
	   public void insert(String table, List rows) throws DataException;   
	   //修改表数据
	   /*
	    * table是要修改数据的表名
	    * selectionRow是修改的条件
	    * update是修改的字段和内容
	    */
	   public void update(String table, Row selectionRow, Row update) throws DataException;	   
	   /*删除表数据
	    * table是要进行数据删除的表名
	    * selectionRow是删除的条件
	    */
	   public void delete(String table, Row selectionRow) throws DataException;
}

⌨️ 快捷键说明

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