DATAKV-66

+ add getter for database index on ConnectionFactories
+ update javadoc
This commit is contained in:
Costin Leau
2011-04-19 19:56:10 +03:00
parent ffb61645de
commit 9b1f5464ba
3 changed files with 29 additions and 1 deletions

View File

@@ -280,9 +280,19 @@ public class JedisConnectionFactory implements InitializingBean, DisposableBean,
this.poolConfig = poolConfig;
}
/**
* Returns the index of the database.
*
* @return Returns the database index
*/
public int getDatabase() {
return dbIndex;
}
/**
* Sets the index of the database used by this connection factory.
* Can be between 0 (default) and 15.
* Default is 0.
*
* @param index database index
*/

View File

@@ -224,6 +224,15 @@ public class JredisConnectionFactory implements InitializingBean, DisposableBean
usePool = true;
}
/**
* Returns the index of the database.
*
* @return Returns the database index
*/
public int getDatabase() {
return dbIndex;
}
/**
* Sets the index of the database used by this connection factory.
* Can be between 0 (default) and 15.

View File

@@ -196,6 +196,15 @@ public class RjcConnectionFactory implements InitializingBean, DisposableBean, R
this.usePool = usePool;
}
/**
* Returns the index of the database.
*
* @return Returns the database index
*/
public int getDatabase() {
return dbIndex;
}
/**
* Sets the index of the database used by this connection factory.
* Can be between 0 (default) and 15.