info.magnolia.module.cache
Class CachePolicyResult

java.lang.Object
  extended by info.magnolia.module.cache.CachePolicyResult

public class CachePolicyResult
extends java.lang.Object

CachePolicy returns instances of this class - depending on the value of the behaviour property, the cacheKey and cachedEntry values might be set or not.

Version:
$Revision: $ ($Author: $)
Author:
gjoseph

Nested Class Summary
static class CachePolicyResult.CachePolicyBehaviour
          Descriptor of the cache policy behavior used by this cache policy result.
 
Field Summary
static CachePolicyResult.CachePolicyBehaviour bypass
           
static CachePolicyResult.CachePolicyBehaviour store
           
static CachePolicyResult.CachePolicyBehaviour useCache
           
 
Constructor Summary
CachePolicyResult(CachePolicyResult.CachePolicyBehaviour behaviour, java.lang.Object cacheKey, java.lang.Object cachedEntry)
           
 
Method Summary
 CachePolicyResult.CachePolicyBehaviour getBehaviour()
           
 java.lang.Object getCachedEntry()
           
 java.lang.Object getCacheKey()
           
static CachePolicyResult getCurrent()
          Returns the current CachePolicyResult which was set by the CacheFilter.
 void setCachedEntry(java.lang.Object entry)
           
static void setCurrent(CachePolicyResult cachePolicyResult)
          Saves the result in the context and makes it available by getCurrent().
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

store

public static final CachePolicyResult.CachePolicyBehaviour store

useCache

public static final CachePolicyResult.CachePolicyBehaviour useCache

bypass

public static final CachePolicyResult.CachePolicyBehaviour bypass
Constructor Detail

CachePolicyResult

public CachePolicyResult(CachePolicyResult.CachePolicyBehaviour behaviour,
                         java.lang.Object cacheKey,
                         java.lang.Object cachedEntry)
Method Detail

getBehaviour

public CachePolicyResult.CachePolicyBehaviour getBehaviour()

getCacheKey

public java.lang.Object getCacheKey()

getCachedEntry

public java.lang.Object getCachedEntry()

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

setCachedEntry

public void setCachedEntry(java.lang.Object entry)

setCurrent

public static void setCurrent(CachePolicyResult cachePolicyResult)
Saves the result in the context and makes it available by getCurrent().


getCurrent

public static CachePolicyResult getCurrent()
Returns the current CachePolicyResult which was set by the CacheFilter.



Copyright © 2003-2011 Magnolia International Ltd.. All Rights Reserved.