Package br.net.woodstock.rockframework.core.cache

Examples of br.net.woodstock.rockframework.core.cache.Cache


  public Cache create(final String id) {
    Assert.notEmpty(id, "id");
    if (this.contains(id)) {
      throw new IllegalArgumentException("A cache with name " + id + " already exists");
    }
    Cache c = new MemoryCacheImpl(id);
    this.caches.add(c);
    return c;
  }
View Full Code Here


  @Override
  public void remove(final String id) {
    Assert.notEmpty(id, "id");
    Iterator<Cache> iterator = this.caches.iterator();
    while (iterator.hasNext()) {
      Cache cache = iterator.next();
      if (((MemoryCacheImpl) cache).getId().equals(id)) {
        iterator.remove();
        break;
      }
    }
View Full Code Here

TOP

Related Classes of br.net.woodstock.rockframework.core.cache.Cache

Copyright © 2018 www.massapicom. 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.