mirror of https://github.com/apache/maven.git
[MNG-5372] removed RepositoryCache, added in 3.0-alpha-3 and deprecated in 3.0-beta-3 with Aether integration (r988749)
git-svn-id: https://svn.apache.org/repos/asf/maven/maven-3/trunk@1407827 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
6c032edddb
commit
3cbed6a1ca
|
@ -1,54 +0,0 @@
|
||||||
package org.apache.maven.artifact.repository;
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Licensed to the Apache Software Foundation (ASF) under one
|
|
||||||
* or more contributor license agreements. See the NOTICE file
|
|
||||||
* distributed with this work for additional information
|
|
||||||
* regarding copyright ownership. The ASF licenses this file
|
|
||||||
* to you under the Apache License, Version 2.0 (the
|
|
||||||
* "License"); you may not use this file except in compliance
|
|
||||||
* with the License. You may obtain a copy of the License at
|
|
||||||
*
|
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
*
|
|
||||||
* Unless required by applicable law or agreed to in writing,
|
|
||||||
* software distributed under the License is distributed on an
|
|
||||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
||||||
* KIND, either express or implied. See the License for the
|
|
||||||
* specific language governing permissions and limitations
|
|
||||||
* under the License.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Caches auxiliary data used during repository access like already processed metadata. The data in the cache is meant
|
|
||||||
* for exclusive consumption by the repository system and is opaque to the cache implementation.
|
|
||||||
*
|
|
||||||
* @author Benjamin Bentmann
|
|
||||||
*/
|
|
||||||
@Deprecated
|
|
||||||
public interface RepositoryCache
|
|
||||||
{
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Puts the specified data into the cache. <strong>Warning:</strong> The cache will directly save the provided
|
|
||||||
* reference. If the cached data is mutable, i.e. could be modified after being put into the cache, the caller is
|
|
||||||
* responsible for creating a copy of the original data and store the copy in the cache.
|
|
||||||
*
|
|
||||||
* @param request The repository request from which this cache was retrieved, must not be {@code null}.
|
|
||||||
* @param key The key to use associate the data with, must not be {@code null}.
|
|
||||||
* @param data The data to store in the cache, may be {@code null}.
|
|
||||||
*/
|
|
||||||
void put( RepositoryRequest request, Object key, Object data );
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Gets the specified data from the cache. <strong>Warning:</strong> The cache will directly return the saved
|
|
||||||
* reference. If the cached data is to be modified after its retrieval, the caller is responsible to create a copy
|
|
||||||
* of the returned data and use this instead of the cache record.
|
|
||||||
*
|
|
||||||
* @param request The repository request from which this cache was retrieved, must not be {@code null}.
|
|
||||||
* @param key The key to use for lookup of the data, must not be {@code null}.
|
|
||||||
* @return The requested data or {@code null} if none was present in the cache.
|
|
||||||
*/
|
|
||||||
Object get( RepositoryRequest request, Object key );
|
|
||||||
|
|
||||||
}
|
|
|
@ -26,7 +26,6 @@ import java.util.Set;
|
||||||
|
|
||||||
import org.apache.maven.artifact.Artifact;
|
import org.apache.maven.artifact.Artifact;
|
||||||
import org.apache.maven.artifact.repository.ArtifactRepository;
|
import org.apache.maven.artifact.repository.ArtifactRepository;
|
||||||
import org.apache.maven.artifact.repository.RepositoryCache;
|
|
||||||
import org.apache.maven.artifact.repository.RepositoryRequest;
|
import org.apache.maven.artifact.repository.RepositoryRequest;
|
||||||
import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
|
import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
|
||||||
import org.apache.maven.settings.Mirror;
|
import org.apache.maven.settings.Mirror;
|
||||||
|
@ -243,16 +242,6 @@ public class ArtifactResolutionRequest
|
||||||
return sb.toString();
|
return sb.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
public RepositoryCache getCache()
|
|
||||||
{
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ArtifactResolutionRequest setCache( RepositoryCache cache )
|
|
||||||
{
|
|
||||||
return this;
|
|
||||||
}
|
|
||||||
|
|
||||||
public boolean isOffline()
|
public boolean isOffline()
|
||||||
{
|
{
|
||||||
return offline;
|
return offline;
|
||||||
|
|
|
@ -28,7 +28,6 @@ import java.util.Properties;
|
||||||
import java.util.concurrent.ConcurrentHashMap;
|
import java.util.concurrent.ConcurrentHashMap;
|
||||||
|
|
||||||
import org.apache.maven.artifact.repository.ArtifactRepository;
|
import org.apache.maven.artifact.repository.ArtifactRepository;
|
||||||
import org.apache.maven.artifact.repository.RepositoryCache;
|
|
||||||
import org.apache.maven.monitor.event.EventDispatcher;
|
import org.apache.maven.monitor.event.EventDispatcher;
|
||||||
import org.apache.maven.plugin.descriptor.PluginDescriptor;
|
import org.apache.maven.plugin.descriptor.PluginDescriptor;
|
||||||
import org.apache.maven.project.MavenProject;
|
import org.apache.maven.project.MavenProject;
|
||||||
|
@ -184,12 +183,6 @@ public class MavenSession
|
||||||
return container.lookupMap( role );
|
return container.lookupMap( role );
|
||||||
}
|
}
|
||||||
|
|
||||||
@Deprecated
|
|
||||||
public RepositoryCache getRepositoryCache()
|
|
||||||
{
|
|
||||||
return null;
|
|
||||||
}
|
|
||||||
|
|
||||||
public ArtifactRepository getLocalRepository()
|
public ArtifactRepository getLocalRepository()
|
||||||
{
|
{
|
||||||
return request.getLocalRepository();
|
return request.getLocalRepository();
|
||||||
|
|
Loading…
Reference in New Issue