Class RedisInfo
java.lang.Object
com.blackrook.redis.RedisInfo
Contains info about a single Redis server.
- Author:
- Matthew Tropiano
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a Redis info object, no timeout, nor password.Creates a Redis info object, no timeout, nor password.Creates a Redis info object, no password.Creates a Redis info object, no timeout.Creates a Redis info object, no timeout.Creates a Redis info object. -
Method Summary
-
Constructor Details
-
RedisInfo
Creates a Redis info object, no timeout, nor password.- Parameters:
host- the server hostname or address.port- the server connection port.
-
RedisInfo
-
RedisInfo
Creates a Redis info object, no timeout, nor password.- Parameters:
host- the server hostname or address.port- the server connection port.db- the database index.
-
RedisInfo
-
RedisInfo
Creates a Redis info object, no password.- Parameters:
host- the server hostname or address.port- the server connection port.db- the database index.timeout- the server socket connection timeout in milliseconds. 0 is no timeout.
-
RedisInfo
Creates a Redis info object.- Parameters:
host- the server hostname or address.port- the server connection port.password- the server database password.db- the database to use for this connection.timeout- the server socket connection timeout in milliseconds. 0 is no timeout.
-
-
Method Details
-
getHost
- Returns:
- the server hostname or address
-
getPort
public int getPort()- Returns:
- the server connection port.
-
getPassword
- Returns:
- the server database password. If null, no password is submitted.
-
getTimeout
public int getTimeout()- Returns:
- Gets the server connection timeout in milliseconds. 0 is no timeout.
-
getDB
public int getDB()- Returns:
- the database id for the connection to use.
-