Home | History | Annotate | Download | only in cert

Lines Matching defs:Cache

36  * objects they are returned from the cache, if not - newly generated
37 * objects can be saved in the cache.<br>
45 * determine whether object to be generated is in the cache or not.
65 * If it is so - the cached object is returned from the cache,
66 * if not - new object should be generated and saved in the cache.<br>
71 public class Cache {
92 // size of the cache
103 // to the object cached at cache[N]
110 private final Object[] cache;
112 // This array is used to speed up the process of the search in the cache.
123 // cache population indicator
127 * Creates the Cache object.
130 * @param size capacity of the cache to be created.
132 public Cache(int pref_size, int size) {
138 cache = new Object[cache_size];
142 * Creates the Cache object of size of 9.
146 public Cache(int pref_size) {
151 * Creates the Cache object of size of 9.
153 public Cache() {
161 * to exactly determine whether object is contained in the cache or not,
162 * and to put the object in the cache.
181 * Checks if there are any object in the cache generated
204 * form if it is contained in the cache and null otherwise.
225 return cache[i];
236 * Puts the object into the cache.
239 * @param object the object to be saved in the cache
242 // check for empty space in the cache
244 // so cache is full, will erase the first entry in the
245 // cache (oldest entry). it could be better to throw out
310 cache[index] = object;