Package org.infinispan.context
Interface EntryLookup
-
- All Known Subinterfaces:
InvocationContext
public interface EntryLookup
Interface that can look up MVCC wrapped entries.- Since:
- 4.0
- Author:
- Manik Surtani (manik@jboss.org)
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description default void
forEachEntry(BiConsumer<Object,org.infinispan.container.entries.CacheEntry> action)
Execute an action for each entry in the context.default void
forEachValue(BiConsumer<Object,org.infinispan.container.entries.CacheEntry> action)
Execute an action for each value in the context.Map<Object,org.infinispan.container.entries.CacheEntry>
getLookedUpEntries()
Deprecated.Since 9.3, please useforEachEntry(BiConsumer)
orlookedUpEntriesCount()
instead.default int
lookedUpEntriesCount()
org.infinispan.container.entries.CacheEntry
lookupEntry(Object key)
Retrieves an entry from the collection of looked up entries in the current scope.void
putLookedUpEntry(Object key, org.infinispan.container.entries.CacheEntry e)
Puts an entry in the registry of looked up entries in the current scope.default void
removeLookedUpEntries(Collection<?> keys)
void
removeLookedUpEntry(Object key)
-
-
-
Method Detail
-
lookupEntry
org.infinispan.container.entries.CacheEntry lookupEntry(Object key)
Retrieves an entry from the collection of looked up entries in the current scope.- Parameters:
key
- key to look up- Returns:
- an entry, or null if it cannot be found.
-
getLookedUpEntries
@Deprecated Map<Object,org.infinispan.container.entries.CacheEntry> getLookedUpEntries()
Deprecated.Since 9.3, please useforEachEntry(BiConsumer)
orlookedUpEntriesCount()
instead.Retrieves a map of entries looked up within the current scope. Note: The key inside the CacheEntry may benull
if the key does not exist in the cache.- Returns:
- a map of looked up entries.
-
forEachValue
default void forEachValue(BiConsumer<Object,org.infinispan.container.entries.CacheEntry> action)
Execute an action for each value in the context. Entries that do not have a value (because the key was removed, or it doesn't exist in the cache).- Since:
- 9.3
-
forEachEntry
default void forEachEntry(BiConsumer<Object,org.infinispan.container.entries.CacheEntry> action)
Execute an action for each entry in the context. Includes invalid entries, which have anull
value and may also report anull
key.- Since:
- 9.3
-
lookedUpEntriesCount
default int lookedUpEntriesCount()
- Returns:
- The number of entries wrapped in the context, including invalid entries.
-
putLookedUpEntry
void putLookedUpEntry(Object key, org.infinispan.container.entries.CacheEntry e)
Puts an entry in the registry of looked up entries in the current scope.- Parameters:
key
- key to storee
- entry to store
-
removeLookedUpEntry
void removeLookedUpEntry(Object key)
-
removeLookedUpEntries
default void removeLookedUpEntries(Collection<?> keys)
-
-