@Component(role=PluginArtifactsCache.class) public class DefaultPluginArtifactsCache extends Object implements PluginArtifactsCache
Modifier and Type | Class and Description |
---|---|
protected static class |
DefaultPluginArtifactsCache.CacheKey
CacheKey
|
PluginArtifactsCache.CacheRecord, PluginArtifactsCache.Key
Modifier and Type | Field and Description |
---|---|
protected Map<PluginArtifactsCache.Key,PluginArtifactsCache.CacheRecord> |
cache |
Constructor and Description |
---|
DefaultPluginArtifactsCache() |
Modifier and Type | Method and Description |
---|---|
protected void |
assertUniqueKey(PluginArtifactsCache.Key key) |
PluginArtifactsCache.Key |
createKey(Plugin plugin,
DependencyFilter extensionFilter,
List<RemoteRepository> repositories,
RepositorySystemSession session) |
void |
flush() |
PluginArtifactsCache.CacheRecord |
get(PluginArtifactsCache.Key key) |
protected static boolean |
pluginEquals(Plugin a,
Plugin b) |
protected static int |
pluginHashCode(Plugin plugin) |
PluginArtifactsCache.CacheRecord |
put(PluginArtifactsCache.Key key,
List<Artifact> pluginArtifacts) |
PluginArtifactsCache.CacheRecord |
put(PluginArtifactsCache.Key key,
PluginResolutionException exception) |
void |
register(MavenProject project,
PluginArtifactsCache.Key cacheKey,
PluginArtifactsCache.CacheRecord record)
Registers the specified cache record for usage with the given project.
|
protected final Map<PluginArtifactsCache.Key,PluginArtifactsCache.CacheRecord> cache
public PluginArtifactsCache.Key createKey(Plugin plugin, DependencyFilter extensionFilter, List<RemoteRepository> repositories, RepositorySystemSession session)
createKey
in interface PluginArtifactsCache
public PluginArtifactsCache.CacheRecord get(PluginArtifactsCache.Key key) throws PluginResolutionException
get
in interface PluginArtifactsCache
PluginResolutionException
public PluginArtifactsCache.CacheRecord put(PluginArtifactsCache.Key key, List<Artifact> pluginArtifacts)
put
in interface PluginArtifactsCache
protected void assertUniqueKey(PluginArtifactsCache.Key key)
public PluginArtifactsCache.CacheRecord put(PluginArtifactsCache.Key key, PluginResolutionException exception)
put
in interface PluginArtifactsCache
public void flush()
flush
in interface PluginArtifactsCache
protected static int pluginHashCode(Plugin plugin)
public void register(MavenProject project, PluginArtifactsCache.Key cacheKey, PluginArtifactsCache.CacheRecord record)
PluginArtifactsCache
register
in interface PluginArtifactsCache
project
- The project that employs the plugin realm, must not be null
.record
- The cache record being used for the project, must not be null
.Copyright © 2001–2021 The Apache Software Foundation. All rights reserved.