public class Cache
extends Object
-
Constructor Summary
Constructors
Constructor to initialize the Cache.
-
Method Summary
Method to look up a cacheable object and cache it if it isn't in the cache.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Cache
Constructor to initialize the Cache.
- Parameters:
storage
- ArrayList
of Cacheable
objects.
-
Method Details
-
lookup
Method to look up a cacheable object and cache it if it isn't in the cache.
- Parameters:
key
- Object to use as a key when searching.