Package com.adaptris.core.fs
Interface ProcessedItemCache
-
- All Superinterfaces:
ComponentLifecycle
- All Known Implementing Classes:
InlineItemCache
,MarshallingItemCache
,NoCache
,XStreamItemCache
public interface ProcessedItemCache extends ComponentLifecycle
Simple interface to track items that have been processed forNonDeletingFsConsumer
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
clear()
Clear the cache.boolean
contains(java.lang.String key)
Query the cache for this key.void
evict()
evict any items in the cache that require it..ProcessedItem
get(java.lang.String key)
Get the TrackedItem associated with the key.void
save()
Explicitly save the state of the cache.int
size()
Return the number of items in the cache.void
update(ProcessedItem i)
Update the cache with the tracked item.void
update(ProcessedItemList list)
Update the cache with the associated list of entries.-
Methods inherited from interface com.adaptris.core.ComponentLifecycle
close, init, start, stop
-
-
-
-
Method Detail
-
update
void update(ProcessedItem i)
Update the cache with the tracked item.- Parameters:
i
- the tracked item.
-
get
ProcessedItem get(java.lang.String key)
Get the TrackedItem associated with the key.- Parameters:
key
- the key- Returns:
- the TrackedItem or null if it does not exist.
-
contains
boolean contains(java.lang.String key)
Query the cache for this key.- Parameters:
key
- the key- Returns:
- true if the item exists.
-
size
int size()
Return the number of items in the cache.- Returns:
- the number of items in the cache.
-
clear
void clear()
Clear the cache.
-
update
void update(ProcessedItemList list)
Update the cache with the associated list of entries.- Parameters:
list
- a list of tracked items
-
save
void save()
Explicitly save the state of the cache.
-
evict
void evict()
evict any items in the cache that require it..
-
-