package com.eactive.eai.rms.bat.manage.rule.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("batAdapterDao")
@SuppressWarnings({"deprecation","unchecked"})
public class BatAdapterDao extends SqlMapClientTemplateDao {

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

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

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

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

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

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

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

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

    public String getAdptrCd(HashMap<String, Object> paramMap) throws Exception{
    	Object obj = this.template.queryForObject("BatAdapter.getAdptrCd", paramMap);
    	return ((String) obj).toString();
    }

    public Object getDelYnByIntfId(Map<String, Object> paramMap) throws Exception{
    	Object obj = this.template.queryForObject("BatAdapter.getDelYnByIntfId", paramMap);
    	return obj;
    }
    
	public Map<String, Object> adapterDbDetail(HashMap<String, Object> param) throws Exception {
		return (Map<String, Object>)template.queryForObject("BatAdapter.adapterDbDetail", param);
    }	
	
	public List<Map<String, Object>> layoutList(HashMap<String, Object> param) throws Exception {
    	return (List<Map<String, Object>>)template.queryForList("BatAdapter.adapterLayoutList", param);
    }	

    public Integer getDbAdptrCdSeq(HashMap<String, Object> paramMap) throws Exception{
    	Object obj = this.template.queryForObject("BatAdapter.getDbAdptrCdSeq", paramMap);
    	return ((Integer) obj);
    }
    
    public void subDbInsert(HashMap<String, Object> paramMap) throws Exception{
        this.template.insert("BatAdapter.subDbInsert", paramMap);
    }      

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

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

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

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

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

    public void deleteLayout(HashMap<String, Object> paramMap) throws Exception{
        this.template.delete("BatAdapter.deleteLayout", paramMap);
    }
	public HashMap<String, Object> adapterFileDetail(HashMap<String, Object> param) throws Exception {
    	return (HashMap<String, Object>)template.queryForObject("BatAdapter.adapterFileDetail", param);
    }	
	
    public Integer getFileAdptrCdSeq(HashMap<String, Object> paramMap) throws Exception{
    	Object obj = this.template.queryForObject("BatAdapter.getFileAdptrCdSeq", paramMap);
    	return ((Integer) obj);
    }
    
    public void subFileInsert(HashMap<String, Object> paramMap) throws Exception{
        this.template.insert("BatAdapter.subFileInsert", paramMap);
    }      

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

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

    public void subFileAllUpdate(HashMap<String, Object> paramMap) throws Exception{
    	this.template.update("BatAdapter.subFileAllUpdate", paramMap);
    }    
    
    public void subFileDelete(HashMap<String, Object> paramMap) throws Exception{
        this.template.delete("BatAdapter.subFileDelete", paramMap);
    }

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

	public List<Map<String, Object>> selectAdapterList(Map<String, Object> paramMap) {
		return template.queryForList("BatAdapter.selectAdapterList", paramMap);
	}
    
}