Package org.apache.commons.jcs3.engine
Class CacheElement<K,V>
java.lang.Object
org.apache.commons.jcs3.engine.CacheElement<K,V>
- All Implemented Interfaces:
Serializable,ICacheElement<K,V>
- Direct Known Subclasses:
CacheElementSerialized,PurgatoryElement
Generic element wrapper. Often stuffed inside another.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionCacheElement(String cacheName, K key, V val) Constructor for the CacheElement objectCacheElement(String cacheName, K key, V val, IElementAttributes attrArg) Constructor for the CacheElement object -
Method Summary
Modifier and TypeMethodDescriptionbooleanGets the cacheName attribute of the CacheElement objectGets the IElementAttributes attribute of the CacheElement objectgetKey()Gets the key attribute of the CacheElement objectgetVal()Gets the val attribute of the CacheElement objectinthashCode()voidSets the attributes attribute of the CacheElement objecttoString()For debugging only.
-
Constructor Details
-
CacheElement
Constructor for the CacheElement object- Parameters:
cacheName-key-val-
-
CacheElement
Constructor for the CacheElement object- Parameters:
cacheName-key-val-attrArg-
-
-
Method Details
-
getCacheName
Gets the cacheName attribute of the CacheElement object- Specified by:
getCacheNamein interfaceICacheElement<K,V> - Returns:
- The cacheName value
-
getKey
Gets the key attribute of the CacheElement object- Specified by:
getKeyin interfaceICacheElement<K,V> - Returns:
- The key value
-
getVal
Gets the val attribute of the CacheElement object- Specified by:
getValin interfaceICacheElement<K,V> - Returns:
- The val value
-
setElementAttributes
Sets the attributes attribute of the CacheElement object- Specified by:
setElementAttributesin interfaceICacheElement<K,V> - Parameters:
attr- The new IElementAttributes value
-
getElementAttributes
Gets the IElementAttributes attribute of the CacheElement object- Specified by:
getElementAttributesin interfaceICacheElement<K,V> - Returns:
- The IElementAttributes value, never null
-
equals
-
hashCode
-
toString
For debugging only.
-