org.apache.jcs.auxiliary.disk.jdbc
Class JDBCDiskCacheAttributes
java.lang.Object
org.apache.jcs.auxiliary.AbstractAuxiliaryCacheAttributes
org.apache.jcs.auxiliary.disk.AbstractDiskCacheAttributes
org.apache.jcs.auxiliary.disk.jdbc.JDBCDiskCacheAttributes
- All Implemented Interfaces:
- Serializable, Cloneable, AuxiliaryCacheAttributes, IDiskCacheAttributes
- Direct Known Subclasses:
- MySQLDiskCacheAttributes
public class JDBCDiskCacheAttributes
- extends AbstractDiskCacheAttributes
The configurator will set these values based on what is in the cache.ccf file.
- Author:
- Aaron Smuts
- See Also:
- Serialized Form
DEFAULT_MAX_ACTIVE
public static final int DEFAULT_MAX_ACTIVE
- This is the default limit on the maximum number of active connections.
- See Also:
- Constant Field Values
DEFAULT_SHRINKER_INTERVAL_SECONDS
public static final int DEFAULT_SHRINKER_INTERVAL_SECONDS
- This is the default setting for the cleanup routine.
- See Also:
- Constant Field Values
JDBCDiskCacheAttributes
public JDBCDiskCacheAttributes()
setUserName
public void setUserName(String userName)
- Parameters:
userName
- The userName to set.
getUserName
public String getUserName()
- Returns:
- Returns the userName.
setPassword
public void setPassword(String password)
- Parameters:
password
- The password to set.
getPassword
public String getPassword()
- Returns:
- Returns the password.
setUrl
public void setUrl(String url)
- Parameters:
url
- The url to set.
getUrl
public String getUrl()
- Returns:
- Returns the url.
setDatabase
public void setDatabase(String database)
- This is appended to the url.
- Parameters:
database
- The database to set.
getDatabase
public String getDatabase()
- Returns:
- Returns the database.
setDriverClassName
public void setDriverClassName(String driverClassName)
- Parameters:
driverClassName
- The driverClassName to set.
getDriverClassName
public String getDriverClassName()
- Returns:
- Returns the driverClassName.
setTableName
public void setTableName(String tableName)
- Parameters:
tableName
- The tableName to set.
getTableName
public String getTableName()
- Returns:
- Returns the tableName.
setTestBeforeInsert
public void setTestBeforeInsert(boolean testBeforeInsert)
- If this is true then the disk cache will check to see if the item already exists in the
database. If it is false, it will try to insert. If the insert fails it will try to update.
- Parameters:
testBeforeInsert
- The testBeforeInsert to set.
isTestBeforeInsert
public boolean isTestBeforeInsert()
- Returns:
- Returns the testBeforeInsert.
setMaxActive
public void setMaxActive(int maxActive)
- Parameters:
maxActive
- The maxActive to set.
getMaxActive
public int getMaxActive()
- Returns:
- Returns the maxActive.
setShrinkerIntervalSeconds
public void setShrinkerIntervalSeconds(int shrinkerIntervalSecondsArg)
- Parameters:
shrinkerIntervalSecondsArg
- The shrinkerIntervalSeconds to set.
getShrinkerIntervalSeconds
public int getShrinkerIntervalSeconds()
- Returns:
- Returns the shrinkerIntervalSeconds.
setUseDiskShrinker
public void setUseDiskShrinker(boolean useDiskShrinker)
- Parameters:
useDiskShrinker
- The useDiskShrinker to set.
isUseDiskShrinker
public boolean isUseDiskShrinker()
- Returns:
- Returns the useDiskShrinker.
setConnectionPoolName
public void setConnectionPoolName(String connectionPoolName)
- Parameters:
connectionPoolName
- the connectionPoolName to set
getConnectionPoolName
public String getConnectionPoolName()
- Returns:
- the connectionPoolName
toString
public String toString()
- For debugging.
- Overrides:
toString
in class AbstractDiskCacheAttributes
- Returns:
- debug string with most of the properties.
Copyright © 2002-2012 Apache Software Foundation. All Rights Reserved.