001    package org.apache.maven.repository.legacy.metadata;
002    
003    /*
004     * Licensed to the Apache Software Foundation (ASF) under one
005     * or more contributor license agreements.  See the NOTICE file
006     * distributed with this work for additional information
007     * regarding copyright ownership.  The ASF licenses this file
008     * to you under the Apache License, Version 2.0 (the
009     * "License"); you may not use this file except in compliance
010     * with the License.  You may obtain a copy of the License at
011     *
012     *  http://www.apache.org/licenses/LICENSE-2.0
013     *
014     * Unless required by applicable law or agreed to in writing,
015     * software distributed under the License is distributed on an
016     * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
017     * KIND, either express or implied.  See the License for the
018     * specific language governing permissions and limitations
019     * under the License.
020     */
021    
022    import java.util.List;
023    import java.util.Map;
024    import java.util.Set;
025    
026    import org.apache.maven.artifact.Artifact;
027    import org.apache.maven.artifact.repository.ArtifactRepository;
028    
029    public class ResolutionGroup
030    {
031    
032        private final Set<Artifact> artifacts;
033    
034        private final List<ArtifactRepository> resolutionRepositories;
035    
036        private final Artifact pomArtifact;
037    
038        private final Artifact relocatedArtifact;
039    
040        private final Map<String, Artifact> managedVersions;
041    
042        public ResolutionGroup( Artifact pomArtifact, Set<Artifact> artifacts,
043                                List<ArtifactRepository> resolutionRepositories )
044        {
045            this( pomArtifact, null, artifacts, null, resolutionRepositories );
046        }
047    
048        public ResolutionGroup( Artifact pomArtifact, Artifact relocatedArtifact, Set<Artifact> artifacts,
049                                Map<String, Artifact> managedVersions, List<ArtifactRepository> resolutionRepositories )
050        {
051            this.pomArtifact = pomArtifact;
052            this.relocatedArtifact = relocatedArtifact;
053            this.artifacts = artifacts;
054            this.managedVersions = managedVersions;
055            this.resolutionRepositories = resolutionRepositories;
056        }
057    
058        public Artifact getPomArtifact()
059        {
060            return pomArtifact;
061        }
062    
063        public Artifact getRelocatedArtifact()
064        {
065            return relocatedArtifact;
066        }
067    
068        public Set<Artifact> getArtifacts()
069        {
070            return artifacts;
071        }
072    
073        public List<ArtifactRepository> getResolutionRepositories()
074        {
075            return resolutionRepositories;
076        }
077    
078        public Map<String, Artifact> getManagedVersions()
079        {
080            return managedVersions;
081        }
082    
083    }