01: package net.sourceforge.jaxor.example.db;
02:
03: import net.sourceforge.jaxor.api.ConnectionFactory;
04: import net.sourceforge.jaxor.db.ConnectionRegistry;
05:
06: import java.sql.Connection;
07:
08: /**
09: * Created By: fede
10: * Date: 9-feb-2004
11: * Time: 10.40.41
12: *
13: * Last Checkin: $Author: fspinazzi $
14: * Date: $Date: 2004/02/09 09:52:06 $
15: * Revision: $Revision: 1.1 $
16: */
17: public class DB2Connection implements ConnectionFactory {
18: public static DB2Connection INSTANCE = new DB2Connection();
19:
20: private final ConnectionRegistry reg = ConnectionRegistry
21: .getConnection(com.ibm.db2.jcc.DB2Driver.class);
22:
23: public Connection getConnection() {
24: return reg.create("jdbc:db2://localhost:50001/jaxor",
25: "db2admin", "db2admin");
26: }
27: }
|