1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19 package org.apache.maven.classrealm;
20
21 import java.io.File;
22 import org.eclipse.aether.artifact.Artifact;
23
24
25
26
27 class ArtifactClassRealmConstituent implements ClassRealmConstituent {
28
29 private final Artifact artifact;
30
31 ArtifactClassRealmConstituent(Artifact artifact) {
32 this.artifact = artifact;
33 }
34
35 public String getGroupId() {
36 return artifact.getGroupId();
37 }
38
39 public String getArtifactId() {
40 return artifact.getArtifactId();
41 }
42
43 public String getType() {
44 return artifact.getExtension();
45 }
46
47 public String getClassifier() {
48 return artifact.getClassifier();
49 }
50
51 public String getVersion() {
52 return artifact.getBaseVersion();
53 }
54
55 public File getFile() {
56 return artifact.getFile();
57 }
58
59 @Override
60 public String toString() {
61 return artifact.toString();
62 }
63 }