当前位置: 首页>>代码示例>>Java>>正文


Java ReplicationConnection.getCurrentConnection方法代码示例

本文整理汇总了Java中com.mysql.jdbc.ReplicationConnection.getCurrentConnection方法的典型用法代码示例。如果您正苦于以下问题:Java ReplicationConnection.getCurrentConnection方法的具体用法?Java ReplicationConnection.getCurrentConnection怎么用?Java ReplicationConnection.getCurrentConnection使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.mysql.jdbc.ReplicationConnection的用法示例。


在下文中一共展示了ReplicationConnection.getCurrentConnection方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getActiveMySQLConnectionChecked

import com.mysql.jdbc.ReplicationConnection; //导入方法依赖的package包/类
/**
 * Get the active connection as an object implementing the
 * internal MySQLConnection interface. This should not be used
 * unless a MySQLConnection is required.
 * 
 * {@link getActiveConnection()} is provided for the general case.
 * The returned object is not a {@link ReplicationConnection}, but
 * instead the {@link LoadBalancedConnectionProxy} for either the
 * master or slaves.
 */
protected MySQLConnection getActiveMySQLConnectionChecked() throws SQLException {
    ReplicationConnection c = (ReplicationConnection) getActiveConnection();
    MySQLConnection mc = (MySQLConnection) c.getCurrentConnection();
    return mc;
}
 
开发者ID:bragex,项目名称:the-vigilantes,代码行数:16,代码来源:FabricMySQLConnectionProxy.java

示例2: getActiveMySQLConnection

import com.mysql.jdbc.ReplicationConnection; //导入方法依赖的package包/类
/**
 * Get the active connection as an object implementing the
 * internal MySQLConnection interface. This should not be used
 * unless a MySQLConnection is required.
 * 
 * {@link getActiveConnection()} is provided for the general case.
 * The returned object is not a {@link ReplicationConnection}, but
 * instead the {@link LoadBalancedConnectionProxy} for either the
 * master or slaves.
 */
protected MySQLConnection getActiveMySQLConnection() throws SQLException {
    ReplicationConnection c = (ReplicationConnection) getActiveConnection();
    MySQLConnection mc = (MySQLConnection) c.getCurrentConnection();
    return mc;
}
 
开发者ID:lamsfoundation,项目名称:lams,代码行数:16,代码来源:FabricMySQLConnectionProxy.java

示例3: getActiveMySQLConnection

import com.mysql.jdbc.ReplicationConnection; //导入方法依赖的package包/类
/**
 * Get the active connection as an object implementing the
 * internal MySQLConnection interface. This should not be used
 * unless a MySQLConnection is required.
 * 
 * {@link getActiveConnection()} is provided for the general case.
 * The returned object is not a {@link ReplicationConnection}, but
 * instead the {@link LoadBalancingConnectionProxy} for either the
 * master or slaves.
 */
protected MySQLConnection getActiveMySQLConnection() throws SQLException {
    ReplicationConnection c = (ReplicationConnection) getActiveConnection();
    MySQLConnection mc = (MySQLConnection) c.getCurrentConnection();
    return mc;
}
 
开发者ID:mniepert,项目名称:TPKB,代码行数:16,代码来源:FabricMySQLConnectionProxy.java

示例4: getActiveMySQLConnection

import com.mysql.jdbc.ReplicationConnection; //导入方法依赖的package包/类
/**
 * Get the active connection as an object implementing the
 * internal MySQLConnection interface. This should not be used
 * unless a MySQLConnection is required.
 *
 * {@link getActiveConnection()} is provided for the general case.
 * The returned object is not a {@link ReplicationConnection}, but
 * instead the {@link LoadBalancingConnectionProxy} for either the
 * master or slaves.
 */
protected MySQLConnection getActiveMySQLConnection() throws SQLException {
	ReplicationConnection c = (ReplicationConnection) getActiveConnection();
	MySQLConnection mc = (MySQLConnection) c.getCurrentConnection();
	return mc;
}
 
开发者ID:hinsenchan,项目名称:fil_project_mgmt_app_v2,代码行数:16,代码来源:FabricMySQLConnectionProxy.java


注:本文中的com.mysql.jdbc.ReplicationConnection.getCurrentConnection方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。