类 | |
| class | Entry |
Public 成员函数 | |
| Entry | get (String key) |
| void | put (String key, Entry entry) |
| void | initialize () |
| void | invalidate (String key, boolean fullExpire) |
| void | remove (String key) |
| void | clear () |
An interface for a cache keyed by a String with a byte array as data.
| void com.ab.network.toolbox.Cache.clear | ( | ) |
Empties the cache.
| Entry com.ab.network.toolbox.Cache.get | ( | String | key | ) |
| void com.ab.network.toolbox.Cache.initialize | ( | ) |
Performs any potentially long-running actions needed to initialize the cache; will be called from a worker thread.
| void com.ab.network.toolbox.Cache.invalidate | ( | String | key, |
| boolean | fullExpire | ||
| ) |
Invalidates an entry in the cache.
| key | Cache key |
| fullExpire | True to fully expire the entry, false to soft expire |
| void com.ab.network.toolbox.Cache.put | ( | String | key, |
| Entry | entry | ||
| ) |
Adds or replaces an entry to the cache.
| key | Cache key |
| entry | Data to store and metadata for cache coherency, TTL, etc. |
| void com.ab.network.toolbox.Cache.remove | ( | String | key | ) |
1.8.8