|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.amazonaws.util.ResponseMetadataCache
public class ResponseMetadataCache
Cache of response metadata for recently executed requests for diagnostic purposes. This cache has a max size and as entries are added, the oldest entry is aged out once the max size has been reached.
Constructor Summary | |
---|---|
ResponseMetadataCache(int maxEntries)
Creates a new cache that will contain, at most the specified number of entries. |
Method Summary | |
---|---|
void |
add(java.lang.Object obj,
ResponseMetadata metadata)
Adds a new entry to this cache, possibly evicting the oldest entry if the cache is at its size limit. |
ResponseMetadata |
get(java.lang.Object obj)
Returns the response metadata associated with the specified object, or null if no metadata is associated with that object. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ResponseMetadataCache(int maxEntries)
maxEntries
- The maximum size of this cache.Method Detail |
---|
public void add(java.lang.Object obj, ResponseMetadata metadata)
obj
- The key by which to store the metadata.metadata
- The metadata for this entry.public ResponseMetadata get(java.lang.Object obj)
obj
- The key by which the desired metadata is stored.
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |