View Javadoc
1   package org.apache.maven.repository.legacy.metadata;
2   
3   /*
4    * Licensed to the Apache Software Foundation (ASF) under one
5    * or more contributor license agreements.  See the NOTICE file
6    * distributed with this work for additional information
7    * regarding copyright ownership.  The ASF licenses this file
8    * to you under the Apache License, Version 2.0 (the
9    * "License"); you may not use this file except in compliance
10   * with the License.  You may obtain a copy of the License at
11   *
12   *  http://www.apache.org/licenses/LICENSE-2.0
13   *
14   * Unless required by applicable law or agreed to in writing,
15   * software distributed under the License is distributed on an
16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17   * KIND, either express or implied.  See the License for the
18   * specific language governing permissions and limitations
19   * under the License.
20   */
21  
22  import java.util.List;
23  import java.util.Map;
24  import java.util.Set;
25  
26  import org.apache.maven.artifact.Artifact;
27  import org.apache.maven.artifact.repository.ArtifactRepository;
28  
29  /**
30   * ResolutionGroup
31   */
32  public class ResolutionGroup
33  {
34  
35      private final Set<Artifact> artifacts;
36  
37      private final List<ArtifactRepository> resolutionRepositories;
38  
39      private final Artifact pomArtifact;
40  
41      private final Artifact relocatedArtifact;
42  
43      private final Map<String, Artifact> managedVersions;
44  
45      public ResolutionGroup( Artifact pomArtifact, Set<Artifact> artifacts,
46                              List<ArtifactRepository> resolutionRepositories )
47      {
48          this( pomArtifact, null, artifacts, null, resolutionRepositories );
49      }
50  
51      public ResolutionGroup( Artifact pomArtifact, Artifact relocatedArtifact, Set<Artifact> artifacts,
52                              Map<String, Artifact> managedVersions, List<ArtifactRepository> resolutionRepositories )
53      {
54          this.pomArtifact = pomArtifact;
55          this.relocatedArtifact = relocatedArtifact;
56          this.artifacts = artifacts;
57          this.managedVersions = managedVersions;
58          this.resolutionRepositories = resolutionRepositories;
59      }
60  
61      public Artifact getPomArtifact()
62      {
63          return pomArtifact;
64      }
65  
66      public Artifact getRelocatedArtifact()
67      {
68          return relocatedArtifact;
69      }
70  
71      public Set<Artifact> getArtifacts()
72      {
73          return artifacts;
74      }
75  
76      public List<ArtifactRepository> getResolutionRepositories()
77      {
78          return resolutionRepositories;
79      }
80  
81      public Map<String, Artifact> getManagedVersions()
82      {
83          return managedVersions;
84      }
85  
86  }