public interface Cache
Modifier and Type | Method and Description |
---|---|
void |
addToCache(CacheObjectKey key,
Object entry,
boolean force)
Add key and entry value into the cache.
|
Object |
checkAndUpdateCache(CacheObjectKey key)
Check if an entry is found for this key object.
|
void |
clearCache()
Clear statement cache
|
void |
flushCache()
Closing all statements in statement cache and flush the statement cache
of all the statements.
|
int |
getSize()
Get the size of statement cache
|
boolean |
isSynchronized()
Check if the statement cache is synchronized.
|
void |
purge()
Remove all statements stored in the statement cache after closing
the statement objects.
|
void |
purge(Object entry)
Remove the specified entry stored in the statement cache after closing
the statement object associated with this entry.
|
Object checkAndUpdateCache(CacheObjectKey key)
key
- whose mapping entry is to be checked.void addToCache(CacheObjectKey key, Object entry, boolean force)
key
- that contains the sql string and its type (PS/CS)entry
- that is the wrapper of PreparedStatement or
CallableStatementforce
- If existing key is to be overwrittenvoid clearCache()
void purge()
void flushCache()
int getSize()
boolean isSynchronized()
void purge(Object entry)
entry
- Copyright © 2019. All rights reserved.