You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2018/06/10 16:34:10 UTC
commons-dbcp git commit: fix typo in private ivar name, Javadocs,
and param name.
Repository: commons-dbcp
Updated Branches:
refs/heads/master b7abcb964 -> e45d91d03
fix typo in private ivar name, Javadocs, and param name.
Project: http://git-wip-us.apache.org/repos/asf/commons-dbcp/repo
Commit: http://git-wip-us.apache.org/repos/asf/commons-dbcp/commit/e45d91d0
Tree: http://git-wip-us.apache.org/repos/asf/commons-dbcp/tree/e45d91d0
Diff: http://git-wip-us.apache.org/repos/asf/commons-dbcp/diff/e45d91d0
Branch: refs/heads/master
Commit: e45d91d0386a32edde0ed08b57f53ec2cc1de3ea
Parents: b7abcb9
Author: Gary Gregory <ga...@gmail.com>
Authored: Sun Jun 10 10:34:08 2018 -0600
Committer: Gary Gregory <ga...@gmail.com>
Committed: Sun Jun 10 10:34:08 2018 -0600
----------------------------------------------------------------------
.../managed/DataSourceXAConnectionFactory.java | 24 ++++++++++----------
1 file changed, 12 insertions(+), 12 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/commons-dbcp/blob/e45d91d0/src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java
----------------------------------------------------------------------
diff --git a/src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java b/src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java
index 2f1bb3f..c3a66f0 100644
--- a/src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java
+++ b/src/main/java/org/apache/commons/dbcp2/managed/DataSourceXAConnectionFactory.java
@@ -37,7 +37,7 @@ import java.sql.SQLException;
public class DataSourceXAConnectionFactory implements XAConnectionFactory {
private final TransactionRegistry transactionRegistry;
private final XADataSource xaDataSource;
- private String username;
+ private String userName;
private String password;
/**
@@ -57,10 +57,10 @@ public class DataSourceXAConnectionFactory implements XAConnectionFactory {
*
* @param transactionManager the transaction manager in which connections will be enlisted
* @param xaDataSource the data source from which connections will be retrieved
- * @param username the username used for authenticating new connections or null for unauthenticated
+ * @param userName the user name used for authenticating new connections or null for unauthenticated
* @param password the password used for authenticating new connections
*/
- public DataSourceXAConnectionFactory(final TransactionManager transactionManager, final XADataSource xaDataSource, final String username, final String password) {
+ public DataSourceXAConnectionFactory(final TransactionManager transactionManager, final XADataSource xaDataSource, final String userName, final String password) {
if (transactionManager == null) {
throw new NullPointerException("transactionManager is null");
}
@@ -70,24 +70,24 @@ public class DataSourceXAConnectionFactory implements XAConnectionFactory {
this.transactionRegistry = new TransactionRegistry(transactionManager);
this.xaDataSource = xaDataSource;
- this.username = username;
+ this.userName = userName;
this.password = password;
}
/**
- * Gets the username used to authenticate new connections.
+ * Gets the user name used to authenticate new connections.
* @return the user name or null if unauthenticated connections are used
*/
public String getUsername() {
- return username;
+ return userName;
}
/**
- * Sets the username used to authenticate new connections.
- * @param username the username used for authenticating the connection or null for unauthenticated
+ * Sets the user name used to authenticate new connections.
+ * @param userName the user name used for authenticating the connection or null for unauthenticated
*/
- public void setUsername(final String username) {
- this.username = username;
+ public void setUsername(final String userName) {
+ this.userName = userName;
}
/**
@@ -107,10 +107,10 @@ public class DataSourceXAConnectionFactory implements XAConnectionFactory {
public Connection createConnection() throws SQLException {
// create a new XAConnection
XAConnection xaConnection;
- if (username == null) {
+ if (userName == null) {
xaConnection = xaDataSource.getXAConnection();
} else {
- xaConnection = xaDataSource.getXAConnection(username, password);
+ xaConnection = xaDataSource.getXAConnection(userName, password);
}
// get the real connection and XAResource from the connection