Class CachingResourceVersion

java.lang.Object
org.apache.wicket.request.resource.caching.version.CachingResourceVersion
All Implemented Interfaces:
IResourceVersion

public class CachingResourceVersion extends Object implements IResourceVersion
Caches the results of a delegating IResourceVersion instance in a member variable. The cache will be valid for the lifetime of this instance. It will expire the oldest entries if the maximum number of entries is exceeded.
Since:
1.5
Author:
Peter Ertl
  • Constructor Details

    • CachingResourceVersion

      create version cache

      the cache will accept up to 5000 before evicting the oldest entries.

      Parameters:
      delegate - delegating resource version provider
    • CachingResourceVersion

      public CachingResourceVersion(IResourceVersion delegate, int maxEntries)
      create version cache

      the cache will accept a maximum number of entries specified by maxEntries before evicting the oldest entries.

      Parameters:
      delegate - resource version provider
      maxEntries - maximum number of cache entries
  • Method Details