package com.eactive.eai.rms.bap.manage.comm.adapter;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

import org.springframework.stereotype.Repository;

import com.eactive.eai.rms.common.base.SqlMapClientTemplateDao;

@Repository("bapAdapterDao")
@SuppressWarnings({"deprecation","unchecked"})
public class BapAdapterDao extends SqlMapClientTemplateDao {

	public int selectListCount(HashMap<String, Object> param) throws Exception {
    	return (Integer)template.queryForObject("BapAdapter.selectListCount", param);
    }	

	public List<Map<String, Object>> selectList(HashMap<String, Object> param) throws Exception {
    	return (List<Map<String, Object>>)template.queryForList("BapAdapter.selectList", param);
    }	

	public HashMap<String, Object> adapterGroupDetail(HashMap<String, Object> param) throws Exception {
    	return (HashMap<String, Object>)template.queryForObject("BapAdapter.adapterGroupDetail", param);
    }	

	public HashMap<String, Object> adapterDetail(HashMap<String, Object> param) throws Exception {
    	return (HashMap<String, Object>)template.queryForObject("BapAdapter.adapterDetail", param);
    }	

	public List<Map<String, Object>> propertyList(HashMap<String, Object> param) throws Exception {
    	return (List<Map<String, Object>>)template.queryForList("BapAdapter.propertyList", param);
    }	

    public void insertAdapterGroup(HashMap<String, Object> paramMap) throws Exception{
        this.template.insert("BapAdapter.insertAdapterGroup", paramMap);
    }      

    public void insertAdapter(HashMap<String, Object> paramMap) throws Exception{
        this.template.insert("BapAdapter.insertAdapter", paramMap);
    }      

    public void insertProperty(HashMap<String, Object> paramMap) throws Exception{
        this.template.insert("BapAdapter.insertProperty", paramMap);
    }      
    
    public void updateAdapterGroup(HashMap<String, Object> paramMap) throws Exception{
        this.template.update("BapAdapter.updateAdapterGroup", paramMap);
    }

    public void updateAdapter(HashMap<String, Object> paramMap) throws Exception{
        this.template.update("BapAdapter.updateAdapter", paramMap);
    }

    public void deleteAdapterGroup(HashMap<String, Object> paramMap) throws Exception{
        this.template.delete("BapAdapter.deleteAdapterGroup", paramMap);
    }

    public void deleteAdapter(HashMap<String, Object> paramMap) throws Exception{
        this.template.delete("BapAdapter.deleteAdapter", paramMap);
    }
}