public class CacheBlock extends java.lang.Object implements java.lang.Comparable<CacheBlock>
Constructor and Description |
---|
CacheBlock(java.util.Date cacheTime)
Create a cache block for a specific time
|
Modifier and Type | Method and Description |
---|---|
void |
addContext(CachedContext context)
Adds context to the cache block
|
void |
addPage(CachedPage page)
Adds a page to the cache
|
int |
compareTo(CacheBlock other) |
boolean |
equals(java.lang.Object o) |
java.util.Date |
getCacheLinkTime()
Returns the CacheLinkTime for the object.
|
java.util.Date |
getCacheTime()
Returns the CacheTime for the object.
|
java.util.Set<CachedContext> |
getContexts()
Returns the ContextValues for the object
|
java.util.Set<CachedPage> |
getPages()
Returns the PageValues for the object
|
int |
hashCode() |
void |
setCacheLinkTime(java.util.Date cacheLinkTime)
Sets the CacheLinkTime for the object.
|
java.lang.String |
toString() |
public CacheBlock(@NotNull java.util.Date cacheTime)
cacheTime
- The cache timepublic void addPage(@NotNull CachedPage page)
page
- The cached pagepublic void addContext(@NotNull CachedContext context)
context
- The cached context@NotNull public java.util.Set<CachedContext> getContexts()
@NotNull public java.util.Set<CachedPage> getPages()
@NotNull public java.util.Date getCacheTime()
@Nullable public java.util.Date getCacheLinkTime()
public void setCacheLinkTime(@Nullable java.util.Date cacheLinkTime)
cacheLinkTime
- The new value for CacheLinkTime. This is the most recent time the cached data was linked to the provider (or null if that is unknown)public int compareTo(@NotNull CacheBlock other)
compareTo
in interface java.lang.Comparable<CacheBlock>
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
@NotNull public java.lang.String toString()
toString
in class java.lang.Object