Package org.aspectj.weaver.tools.cache
Schnittstelle CacheBacking
- Alle bekannten Implementierungsklassen:
AbstractCacheBacking
,AbstractFileCacheBacking
,AbstractIndexedFileCacheBacking
,AsynchronousFileCacheBacking
,DefaultFileCacheBacking
,FlatFileCacheBacking
,ZippedFileCacheBacking
public interface CacheBacking
Interface for the backing to the cache; usually a file,
but could be an in-memory backing for testing.
aspectj and jvmti provide no suitable guarantees on locking for class redefinitions, so every implementation must have a some locking mechanism to prevent invalid reads.
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibungvoid
clear()
Clear the entire cacheget
(CachedClassReference ref, byte[] originalBytes) Get a cache entryString[]
Return a list of keys which match the given regex.void
put
(CachedClassEntry entry, byte[] originalBytes) Put an entry in the cachevoid
Remove an entry from the cache
-
Methodendetails
-
getKeys
Return a list of keys which match the given regex.- Parameter:
regex
-- Gibt zurück:
-
remove
Remove an entry from the cache- Parameter:
ref
-
-
clear
void clear()Clear the entire cache -
get
Get a cache entry- Parameter:
ref
- entry to retrieveoriginalBytes
- Pre-weaving class bytes - required in order to ensure that the cached entry refers to the same original class- Gibt zurück:
- the cached bytes or null, if the entry does not exist
-
put
Put an entry in the cache- Parameter:
entry
- key of the entryoriginalBytes
- Pre-weaving class bytes - required in order to ensure that the cached entry refers to the same original class
-