@Override protected V putIfAbsentInternal(long ttl, TimeUnit timeunit, Long maxIdle, TimeUnit maxIdleUnit, Object key, Object value) { key = toNearCacheKey(key); V previousValue; try { previousValue = super.putIfAbsentInternal(ttl, timeunit, maxIdle, maxIdleUnit, key, value); } finally { invalidateNearCache(key); } return previousValue; }
@Override public V putIfAbsent(K key, V value, long ttl, TimeUnit timeunit) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(ttl, timeunit, null, null, key, value); }
@Override public V putIfAbsent(K key, V value) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(DEFAULT_TTL, MILLISECONDS, null, null, key, value); }
@Override public V putIfAbsent(K key, V value, long ttl, TimeUnit ttlUnit, long maxIdle, TimeUnit maxIdleUnit) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(ttl, ttlUnit, maxIdle, maxIdleUnit, key, value); }
@Override public V putIfAbsent(K key, V value, long ttl, TimeUnit timeunit) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(ttl, timeunit, null, null, key, value); }
@Override public V putIfAbsent(K key, V value, long ttl, TimeUnit ttlUnit, long maxIdle, TimeUnit maxIdleUnit) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(ttl, ttlUnit, maxIdle, maxIdleUnit, key, value); }
@Override protected V putIfAbsentInternal(long ttl, TimeUnit timeunit, Long maxIdle, TimeUnit maxIdleUnit, Object key, Object value) { key = toNearCacheKey(key); V previousValue; try { previousValue = super.putIfAbsentInternal(ttl, timeunit, maxIdle, maxIdleUnit, key, value); } finally { invalidateNearCache(key); } return previousValue; }
@Override public V putIfAbsent(K key, V value) { checkNotNull(key, NULL_KEY_IS_NOT_ALLOWED); checkNotNull(value, NULL_VALUE_IS_NOT_ALLOWED); return putIfAbsentInternal(DEFAULT_TTL, MILLISECONDS, null, null, key, value); }