DAO.java 1.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. package com.zhcs.dt.dao;
  2. /**
  3. * @author FH Q313596790
  4. * 修改时间:2015、12、11
  5. */
  6. public interface DAO {
  7. /**
  8. * 保存对象
  9. * @param str
  10. * @param obj
  11. * @return
  12. * @throws Exception
  13. */
  14. public Object save(String str, Object obj) throws Exception;
  15. /**
  16. * 修改对象
  17. * @param str
  18. * @param obj
  19. * @return
  20. * @throws Exception
  21. */
  22. public Object update(String str, Object obj) throws Exception;
  23. /**
  24. * 删除对象
  25. * @param str
  26. * @param obj
  27. * @return
  28. * @throws Exception
  29. */
  30. public Object delete(String str, Object obj) throws Exception;
  31. /**
  32. * 查找对象
  33. * @param str
  34. * @param obj
  35. * @return
  36. * @throws Exception
  37. */
  38. public Object findForObject(String str, Object obj) throws Exception;
  39. /**
  40. * 查找对象
  41. * @param str
  42. * @param obj
  43. * @return
  44. * @throws Exception
  45. */
  46. public Object findForList(String str, Object obj) throws Exception;
  47. /**
  48. * 查找对象封装成Map
  49. * @param s
  50. * @param obj
  51. * @return
  52. * @throws Exception
  53. */
  54. public Object findForMap(String sql, Object obj, String key , String value) throws Exception;
  55. }