@Component(role=PluginArtifactsCache.class) public class DefaultPluginArtifactsCache extends Object implements PluginArtifactsCache
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.CacheRecord record)
Registers the specified cache record for usage with the given project.
|
protected final Map<PluginArtifactsCache.Key,PluginArtifactsCache.CacheRecord> cache
public DefaultPluginArtifactsCache()
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)
protected static boolean pluginEquals(Plugin a, Plugin b)
public void register(MavenProject project, 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–2013 The Apache Software Foundation. All rights reserved.