/** * Clear the entry for String. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(String profileName) { super.clearImpl(profileName); }
/** * Clear the entry for ParsedURL. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(ParsedURL purl) { super.clearImpl(purl); }
/** * Clear the entry for String. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(String profileName) { super.clearImpl(profileName); }
/** * Clear the entry for ParsedURL. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(ParsedURL purl) { super.clearImpl(purl); }
/** * Clear the entry for ParsedURL. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(ParsedURL purl) { super.clearImpl(purl); }
/** * Clear the entry for String. * This is the easiest way to 'get off the hook'. * if you didn't indend to get on it. */ public synchronized void clear(String profileName) { super.clearImpl(profileName); }
/** * Check if <code>request(key)</code> will return immediately with the * Object. Note that it is possible that this will return * true but between this call and the call to request the * soft-reference will be cleared. */ protected final synchronized boolean isDoneImpl(Object key) { Object o = map.get(key); if (o == null) return false; SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared clearImpl(key); return false; }
/** * Check if <code>request(key)</code> will return immediately with the * Object. Note that it is possible that this will return * true but between this call and the call to request the * soft-reference will be cleared. */ protected final synchronized boolean isDoneImpl(Object key) { Object o = map.get(key); if (o == null) return false; SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared clearImpl(key); return false; }
/** * Check if <code>request(key)</code> will return immediately with the * Object. Note that it is possible that this will return * true but between this call and the call to request the * soft-reference will be cleared. */ protected final synchronized boolean isDoneImpl(Object key) { Object o = map.get(key); if (o == null) return false; SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared clearImpl(key); return false; }
/** * Check if <code>request(key)</code> will return with an Object * (not putting you on the hook for it). Note that it is possible * that this will return true but between this call and the call * to request the soft-reference will be cleared. So it * is still possible for request to return NULL, just much less * likely (you can always call 'clear' in that case). */ protected final synchronized boolean isPresentImpl(Object key) { if (!map.containsKey(key)) return false; Object o = map.get(key); if (o == null) // It's been requested but hasn't been 'put' yet. return true; // It's been put let's make sure the soft reference hasn't // been cleared. SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared, so remove our record of key. clearImpl(key); return false; }
/** * Check if <code>request(key)</code> will return with an Object * (not putting you on the hook for it). Note that it is possible * that this will return true but between this call and the call * to request the soft-reference will be cleared. So it * is still possible for request to return NULL, just much less * likely (you can always call 'clear' in that case). */ protected final synchronized boolean isPresentImpl(Object key) { if (!map.containsKey(key)) return false; Object o = map.get(key); if (o == null) // It's been requested but hasn't been 'put' yet. return true; // It's been put let's make sure the soft reference hasn't // been cleared. SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared, so remove our record of key. clearImpl(key); return false; }
/** * Check if <code>request(key)</code> will return with an Object * (not putting you on the hook for it). Note that it is possible * that this will return true but between this call and the call * to request the soft-reference will be cleared. So it * is still possible for request to return NULL, just much less * likely (you can always call 'clear' in that case). */ protected final synchronized boolean isPresentImpl(Object key) { if (!map.containsKey(key)) return false; Object o = map.get(key); if (o == null) // It's been requested but hasn't been 'put' yet. return true; // It's been put let's make sure the soft reference hasn't // been cleared. SoftReference sr = (SoftReference)o; o = sr.get(); if (o != null) return true; // Soft reference was cleared, so remove our record of key. clearImpl(key); return false; }