This implementation creates classloader scopes of the form:
"ExampleClassLoaderName.[crc hash]"
And weaved class keys of the form:
"com.foo.BarClassName.[bytes len][crc].weaved"
And generated class keys of the form:
"com.foo.BarClassName$AjClosure.generated
| Modifier and Type | Field and Description |
|---|---|
| public static final String | |
| public static final String |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| private String | |
| public String | Returns: a unique string for URLClassloaders, otherwise a non-unique classnamethe classloader which uses the cache, can be null cl, List<String> the aspects aspects)Implements org. |
| public CachedClassReference | generatedKey(String
class to create a key for className)Implements org. className == keyToClass(generatedKey(className)) holds and generatedKey(className).matches(getGeneratedRegex()) == true |
| public String | getGeneratedRegex()
Implements org. |
| public String | getWeavedRegex()
Implements org. |
| public String | Returns: className, e.g. "com.foo.Bar"to convert key)Implements org. |
| public CachedClassReference | weavedKey(String
class to create a key for className, byte[] bytes of the pre-weaved class original_bytes)Implements org. className == keyToClass(weavedKey(className, various_bytes)) holds and weavedKey(className, various_bytes).matches(getWeavedRegex()) == true |
| GENERATED_SUFFIX | back to summary |
|---|---|
| public static final String GENERATED_SUFFIX | |
| WEAVED_SUFFIX | back to summary |
|---|---|
| public static final String WEAVED_SUFFIX | |
| DefaultCacheKeyResolver | back to summary |
|---|---|
| public DefaultCacheKeyResolver() | |
| crc | back to summary |
|---|---|
| private String crc(byte[] input) | |
| createClassLoaderScope | back to summary |
|---|---|
| public String createClassLoaderScope(ClassLoader cl, List<String> aspects) Implements org. Create a scope from a set of urls and aspect urls. Creates scope of the form "ExampleClassLoaderName.[md5sum]" or "ExampleClassLoaderName.[crc]"
| |
| generatedKey | back to summary |
|---|---|
| public CachedClassReference generatedKey(String className) Implements org. Doc from org. Create a key for the given className from a class generated by the weaver such that: className == keyToClass(generatedKey(className)) holds and generatedKey(className).matches(getGeneratedRegex()) == true
| |
| getGeneratedRegex | back to summary |
|---|---|
| public String getGeneratedRegex() Implements org. Doc from org. Return a regex which matches all generated keys
| |
| getWeavedRegex | back to summary |
|---|---|
| public String getWeavedRegex() Implements org. Doc from org. Return a regex which matches all weaved keys;
| |
| keyToClass | back to summary |
|---|---|
| public String keyToClass(String key) Implements org. Converts a cache key back to a className | |
| weavedKey | back to summary |
|---|---|
| public CachedClassReference weavedKey(String className, byte[] original_bytes) Implements org. Doc from org. Create a key for the given class name and byte array from the pre-weaved class such that className == keyToClass(weavedKey(className, various_bytes)) holds and weavedKey(className, various_bytes).matches(getWeavedRegex()) == true
| |