Package er.extensions.foundation

Examples of er.extensions.foundation.ERXExpiringCache


     * call {@link #addObject(EOEnterpriseObject)} on it.
     * @param key the key of the object that was not found in the cache
     */
    protected void handleUnsuccessfullQueryForKey(Object key) {
      if (!_fetchInitialValues) {
        ERXExpiringCache cache = cache();
            // The other methods are synchronized on cache and then lock the EC. If we do it backwards,
            // we can get a deadly embrace.
        synchronized (cache) {
                ERXEC editingContext = editingContext();
              editingContext.lock();
              try {
                NSArray<T> objects = fetchObjectsForKey(editingContext, key);
              if (objects.count() == 0) {
                cache.setObjectForKey(createRecord(NO_GID_MARKER, null), key);
              }
              else if (objects.count() == 1) {
                  T eo = objects.objectAtIndex(0);
                  addObject(eo);
              }
View Full Code Here

TOP

Related Classes of er.extensions.foundation.ERXExpiringCache

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.