productmanager.java

来自「网上商店。提供网上销售」· Java 代码 · 共 76 行

JAVA
76
字号
package ydh.business;


import java.util.Iterator;
import java.util.List;

import org.hibernate.Session;
import org.hibernate.Transaction;

import ydh.product.Product;
import ydh.product.ProductDAO;
import ydh.user.User;
import ydh.user.UserDAO;


public class ProductManager {
	ProductDAO dao;

	public ProductDAO getDao() {
		return dao;
	}

	public void setDao(ProductDAO dao) {
		this.dao = dao;
	}
   public List search(String name){
	   List l=getDao().search(name);
	   return l;
   }
	public List findid(String id){
		   List l=getDao().findid(id);
		   return l;
	   }
	public List findAll(int firstRow,int maxResults){
		List list=getDao().findAll(firstRow, maxResults);
  return list;
	}
	public void save(Product p){
		getDao().save(p);
	} 
	public void update(Product p){
		getDao().update(p);
	}
	public void delete(Product p){
		getDao().delete(p);
	}
	public List findAll(int firstRow,int maxResults,String ca){
		List list=getDao().findAll(firstRow, maxResults,ca);
  return list;
	}
	public List newgoods(int firstRow,int maxResults){
		List list=getDao().newgoods(firstRow, maxResults);
  return list;
	}
	public List salegoods(int firstRow,int maxResults){
		List list=getDao().salegoods(firstRow, maxResults);
  return list;
	}
	public List findAll(){
		List list=getDao().findAll();
  return list;
	}
	public List findAll(String catalogid){
		List list=getDao().findAll(catalogid);
  return list;
	}
	public List newgoods(){
		List list=getDao().newgoods();
  return list;
	}
	public List salegoods(){
		List list=getDao().salegoods();
  return list;
	}
}

⌨️ 快捷键说明

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