package org.fouram.core.base.service;

import javax.annotation.Resource;

import org.fouram.core.base.dao.DAO;

/**
 * 业务逻辑层基类
 */
public abstract class BaseService {

	@Resource(name = "daoSupport")
	private DAO dao;
	
	public Integer save(String sqlStr, Object paramObj) throws Exception {
		return dao.save(sqlStr, paramObj);
	}

	public Integer update(String sqlStr, Object paramObj) throws Exception {
		return dao.update(sqlStr, paramObj);
	}

	public Integer delete(String sqlStr, Object paramObj) throws Exception {
		return dao.delete(sqlStr, paramObj);
	}

	public Object findObject(String sqlStr, Object paramObj) throws Exception {
		return dao.findForObject(sqlStr, paramObj);
	}

	public Object findList(String sqlStr, Object paramObj) throws Exception {
		return dao.findForList(sqlStr, paramObj);
	}
}