View Javadoc
1   /*
2    * Licensed to the Apache Software Foundation (ASF) under one
3    * or more contributor license agreements.  See the NOTICE file
4    * distributed with this work for additional information
5    * regarding copyright ownership.  The ASF licenses this file
6    * to you under the Apache License, Version 2.0 (the
7    * "License"); you may not use this file except in compliance
8    * with the License.  You may obtain a copy of the License at
9    *
10   *   http://www.apache.org/licenses/LICENSE-2.0
11   *
12   * Unless required by applicable law or agreed to in writing,
13   * software distributed under the License is distributed on an
14   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   * KIND, either express or implied.  See the License for the
16   * specific language governing permissions and limitations
17   * under the License.
18   */
19  package org.apache.maven.artifact.resolver;
20  
21  import java.util.List;
22  import java.util.Map;
23  import java.util.Set;
24  
25  import org.apache.maven.artifact.Artifact;
26  import org.apache.maven.artifact.metadata.ArtifactMetadataSource;
27  import org.apache.maven.artifact.repository.ArtifactRepository;
28  import org.apache.maven.artifact.resolver.filter.ArtifactFilter;
29  import org.apache.maven.wagon.events.TransferListener;
30  
31  /**
32   */
33  // Just hide the one method we want behind the RepositorySystem interface.
34  @Deprecated
35  public interface ArtifactResolver {
36  
37      ArtifactResolutionResult resolve(ArtifactResolutionRequest request);
38  
39      // The rest is deprecated
40      // USED BY MAVEN ASSEMBLY PLUGIN 2.2-beta-2
41      @Deprecated
42      String ROLE = ArtifactResolver.class.getName();
43  
44      // USED BY SUREFIRE, DEPENDENCY PLUGIN
45      @Deprecated
46      ArtifactResolutionResult resolveTransitively(
47              Set<Artifact> artifacts,
48              Artifact originatingArtifact,
49              ArtifactRepository localRepository,
50              List<ArtifactRepository> remoteRepositories,
51              ArtifactMetadataSource source,
52              ArtifactFilter filter)
53              throws ArtifactResolutionException, ArtifactNotFoundException;
54  
55      // USED BY MAVEN ASSEMBLY PLUGIN
56      @Deprecated
57      ArtifactResolutionResult resolveTransitively(
58              Set<Artifact> artifacts,
59              Artifact originatingArtifact,
60              Map<String, Artifact> managedVersions,
61              ArtifactRepository localRepository,
62              List<ArtifactRepository> remoteRepositories,
63              ArtifactMetadataSource source)
64              throws ArtifactResolutionException, ArtifactNotFoundException;
65  
66      // USED BY MAVEN ASSEMBLY PLUGIN
67      @Deprecated
68      ArtifactResolutionResult resolveTransitively(
69              Set<Artifact> artifacts,
70              Artifact originatingArtifact,
71              Map<String, Artifact> managedVersions,
72              ArtifactRepository localRepository,
73              List<ArtifactRepository> remoteRepositories,
74              ArtifactMetadataSource source,
75              ArtifactFilter filter)
76              throws ArtifactResolutionException, ArtifactNotFoundException;
77  
78      // USED BY INVOKER PLUGIN
79      @Deprecated
80      ArtifactResolutionResult resolveTransitively(
81              Set<Artifact> artifacts,
82              Artifact originatingArtifact,
83              List<ArtifactRepository> remoteRepositories,
84              ArtifactRepository localRepository,
85              ArtifactMetadataSource source)
86              throws ArtifactResolutionException, ArtifactNotFoundException;
87  
88      @Deprecated
89      @SuppressWarnings("checkstyle:parameternumber")
90      ArtifactResolutionResult resolveTransitively(
91              Set<Artifact> artifacts,
92              Artifact originatingArtifact,
93              Map<String, Artifact> managedVersions,
94              ArtifactRepository localRepository,
95              List<ArtifactRepository> remoteRepositories,
96              ArtifactMetadataSource source,
97              ArtifactFilter filter,
98              List<ResolutionListener> listeners)
99              throws ArtifactResolutionException, ArtifactNotFoundException;
100 
101     @Deprecated
102     ArtifactResolutionResult resolveTransitively(
103             Set<Artifact> artifacts,
104             Artifact originatingArtifact,
105             List<ArtifactRepository> remoteRepositories,
106             ArtifactRepository localRepository,
107             ArtifactMetadataSource source,
108             List<ResolutionListener> listeners)
109             throws ArtifactResolutionException, ArtifactNotFoundException;
110 
111     // USED BY REMOTE RESOURCES PLUGIN, DEPENDENCY PLUGIN, SHADE PLUGIN
112     @Deprecated
113     void resolve(Artifact artifact, List<ArtifactRepository> remoteRepositories, ArtifactRepository localRepository)
114             throws ArtifactResolutionException, ArtifactNotFoundException;
115 
116     // USED BY REMOTE RESOURCES PLUGIN
117     @Deprecated
118     void resolve(
119             Artifact artifact,
120             List<ArtifactRepository> remoteRepositories,
121             ArtifactRepository localRepository,
122             TransferListener downloadMonitor)
123             throws ArtifactResolutionException, ArtifactNotFoundException;
124 
125     // USED BY DEPENDENCY PLUGIN, ARCHETYPE DOWNLOADER
126     @Deprecated
127     void resolveAlways(
128             Artifact artifact, List<ArtifactRepository> remoteRepositories, ArtifactRepository localRepository)
129             throws ArtifactResolutionException, ArtifactNotFoundException;
130 }