Class ValueProcessorEhcacheLoaderDecorator

java.lang.Object
com.atlassian.cache.ehcache.wrapper.ValueProcessorEhcacheLoaderDecorator
All Implemented Interfaces:
net.sf.ehcache.loader.CacheLoader

public class ValueProcessorEhcacheLoaderDecorator extends Object implements net.sf.ehcache.loader.CacheLoader
This class makes sure that during any loading operation, wrapped keys do not leak to the end user. If the cache that uses ValueProcessor decides to load the value, this decorator should be used on the provided loader.
  • Constructor Details

    • ValueProcessorEhcacheLoaderDecorator

      public ValueProcessorEhcacheLoaderDecorator(net.sf.ehcache.loader.CacheLoader delegate, ValueProcessor valueProcessor)
  • Method Details

    • load

      public Object load(Object key) throws net.sf.ehcache.CacheException
      Specified by:
      load in interface net.sf.ehcache.loader.CacheLoader
      Throws:
      net.sf.ehcache.CacheException
    • loadAll

      public Map loadAll(Collection keys)
      Specified by:
      loadAll in interface net.sf.ehcache.loader.CacheLoader
    • load

      public Object load(Object key, Object argument)
      Specified by:
      load in interface net.sf.ehcache.loader.CacheLoader
    • loadAll

      public Map loadAll(Collection keys, Object argument)
      Specified by:
      loadAll in interface net.sf.ehcache.loader.CacheLoader
    • getName

      public String getName()
      Specified by:
      getName in interface net.sf.ehcache.loader.CacheLoader
    • clone

      public net.sf.ehcache.loader.CacheLoader clone(net.sf.ehcache.Ehcache cache) throws CloneNotSupportedException
      Specified by:
      clone in interface net.sf.ehcache.loader.CacheLoader
      Throws:
      CloneNotSupportedException
    • init

      public void init()
      Specified by:
      init in interface net.sf.ehcache.loader.CacheLoader
    • dispose

      public void dispose() throws net.sf.ehcache.CacheException
      Specified by:
      dispose in interface net.sf.ehcache.loader.CacheLoader
      Throws:
      net.sf.ehcache.CacheException
    • getStatus

      public net.sf.ehcache.Status getStatus()
      Specified by:
      getStatus in interface net.sf.ehcache.loader.CacheLoader