Examples of HashCodeCacheKeyGenerator


Examples of com.googlecode.ehcache.annotations.key.HashCodeCacheKeyGenerator

    }

    Cache rcache = cacheManager.getCache("runCache");
    if (rcache != null) {
      BlockingCache cache = new BlockingCache(rcache);
      HashCodeCacheKeyGenerator keygen = new HashCodeCacheKeyGenerator();
      for (Run run : runs) {
        Long cachekey = keygen.generateKey(run);
        cache.remove(cachekey);
        cache.put(new Element(cachekey, run));
      }
    }
  }
View Full Code Here

Examples of org.springmodules.cache.key.HashCodeCacheKeyGenerator

  public void testIsSingleton() {
    assertTrue(factoryBean.isSingleton());
  }

  public void testSetCacheKeyGenerator() {
    CacheKeyGenerator keyGenerator = new HashCodeCacheKeyGenerator();
    factoryBean.setCacheKeyGenerator(keyGenerator);

    assertSame(keyGenerator, factoryBean.getCachingInterceptor()
        .cacheKeyGenerator());
  }
View Full Code Here

Examples of org.springmodules.cache.key.HashCodeCacheKeyGenerator

      if (!successful) cache.cancelCacheUpdate(key);
    }
  }

  private CacheKeyGenerator defaultKeyGenerator() {
    return new HashCodeCacheKeyGenerator(true);
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.