|
@@ -0,0 +1,27 @@
|
|
|
+package cn.com.qmth.examcloud.bridge.commons;
|
|
|
+
|
|
|
+import java.sql.Connection;
|
|
|
+
|
|
|
+import cn.com.qmth.examcloud.commons.util.DBUtil;
|
|
|
+
|
|
|
+/**
|
|
|
+ * 数据库工具
|
|
|
+ *
|
|
|
+ * @author WANGWEI
|
|
|
+ * @date 2019年10月14日
|
|
|
+ * @Copyright (c) 2018-? http://qmth.com.cn All Rights Reserved.
|
|
|
+ */
|
|
|
+public class BridgeDatabaseUtil {
|
|
|
+
|
|
|
+ /**
|
|
|
+ * get JDBC connection
|
|
|
+ *
|
|
|
+ * @author WANGWEI
|
|
|
+ * @param bridgeDataSource
|
|
|
+ * @return
|
|
|
+ */
|
|
|
+ public static Connection getConnection(BridgeDataSource bridgeDataSource) {
|
|
|
+ return DBUtil.getConnection(bridgeDataSource.getName());
|
|
|
+ }
|
|
|
+
|
|
|
+}
|