Examples of KeptInMemoryObjectKey


Examples of net.sf.joafip.store.entity.kept.KeptInMemoryObjectKey

  private final Map<Object, KeptInMemoryObjectKey> keyByObjectMap =
  /**/new IdentityHashMap<Object, KeptInMemoryObjectKey>();

  public void addObject(final String key, final Object object)
      throws StoreException {
    final KeptInMemoryObjectKey keptKey = new KeptInMemoryObjectKey(key);
    if (objectByKeyMap.put(keptKey, object) != null) {
      throw new StoreException("key " + key + " already used");
    }
    if (keyByObjectMap.put(object, keptKey) != null) {
      throw new StoreException("object " + identityString(object)
View Full Code Here

Examples of net.sf.joafip.store.entity.kept.KeptInMemoryObjectKey

  public boolean isKeptInMemory(final Object object) {
    return keyByObjectMap.containsKey(object);
  }

  public String keyOfObject(final Object object) {
    final KeptInMemoryObjectKey keptInMemoryObjectKey = keyByObjectMap
        .get(object);
    return keptInMemoryObjectKey == null ? null : keptInMemoryObjectKey
        .getKey();
  }
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.