public class IdBasedRangeCacheKey extends IdBasedCacheKey
Constructor and Description |
---|
IdBasedRangeCacheKey(Long id)
Creates a cache key encapsulating the ID.
|
IdBasedRangeCacheKey(Long id,
long rangeStart,
long rangeEnd)
Creates a cache key for an ID and a range
|
Modifier and Type | Method and Description |
---|---|
String |
getCacheKeyString()
String representation of the cache key which will be used for caching.
|
long |
getRangeEnd() |
long |
getRangeStart() |
getId, isUniquePerClient
public IdBasedRangeCacheKey(Long id)
id
- the ID to be cached; must not be nullpublic IdBasedRangeCacheKey(Long id, long rangeStart, long rangeEnd)
id
- the ID to be cached; must not be nullrangeStart
- the start of the range of the items to be cached. Negative numbers are normalized
to -1. A possible interpretation of -1 would be to ignore this boundary.rangeEnd
- the end of the range of the items to be cached. Negative numbers are normalized to
-1. A possible interpretation of -1 would be to ignore this boundary.public String getCacheKeyString()
getCacheKeyString
in interface CacheKey
getCacheKeyString
in class IdBasedCacheKey
public long getRangeEnd()
public long getRangeStart()
Copyright © 2019 Communote team. All rights reserved.