92eed5972e3fefc12c33a41819b8a87254b9a85b.svn-base 358 B

123456789101112131415161718192021
  1. package com.cockpit.util;
  2. import java.sql.Connection;
  3. import com.sinosoft.cm.DBUtils;
  4. public class ConnUtil{
  5. private static ConnUtil cu = null ;
  6. private static Connection conn = null ;
  7. private ConnUtil(){
  8. conn = DBUtils.getConnection();
  9. }
  10. public static Connection getConn(){
  11. if(conn == null){
  12. cu = new ConnUtil();
  13. }
  14. return conn ;
  15. }
  16. }