@ -58,6 +59,9 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@@ -58,6 +59,9 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
/** The maximum number of entries in the cache. */
privatevolatileintcacheLimit=DEFAULT_CACHE_LIMIT;
@ -65,6 +69,9 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@@ -65,6 +69,9 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
/** Whether we should refrain from resolving views again if unresolved once. */
privatebooleancacheUnresolved=true;
/** Filter function that determines if view should be cached. */
@ -141,6 +148,21 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@@ -141,6 +148,21 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
returnthis.cacheUnresolved;
}
/**
*Setsthefilterthatdeterminesifviewshouldbecached.
*Defaultbehaviouristocacheallviews.
*/
publicvoidsetCacheFilter(CacheFiltercacheFilter){
Assert.notNull(cacheFilter,"CacheFilter must not be null");
@ -160,7 +182,7 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@@ -160,7 +182,7 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@ -266,4 +288,26 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu
@@ -266,4 +288,26 @@ public abstract class AbstractCachingViewResolver extends WebApplicationObjectSu