1 package org.apache.maven.shared.release.transform.jdom;
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22 import java.util.List;
23
24 import org.apache.maven.model.Dependency;
25 import org.apache.maven.model.Exclusion;
26 import org.apache.maven.shared.release.transform.MavenCoordinate;
27 import org.jdom.Element;
28
29
30
31
32
33
34
35 public class JDomDependency extends Dependency implements MavenCoordinate
36 {
37 private final MavenCoordinate coordinate;
38
39 public JDomDependency( Element dependency )
40 {
41 this.coordinate = new JDomMavenCoordinate( dependency );
42 }
43
44 @Override
45 public void addExclusion( Exclusion exclusion )
46 {
47 throw new UnsupportedOperationException();
48 }
49
50 @Override
51 public String getArtifactId()
52 {
53 return coordinate.getArtifactId();
54 }
55
56 @Override
57 public String getClassifier()
58 {
59 throw new UnsupportedOperationException();
60 }
61
62 @Override
63 public List<Exclusion> getExclusions()
64 {
65 throw new UnsupportedOperationException();
66 }
67
68 @Override
69 public String getGroupId()
70 {
71 return coordinate.getGroupId();
72 }
73
74 @Override
75 public String getScope()
76 {
77 throw new UnsupportedOperationException();
78 }
79
80 @Override
81 public String getSystemPath()
82 {
83 throw new UnsupportedOperationException();
84 }
85
86 @Override
87 public String getType()
88 {
89 throw new UnsupportedOperationException();
90 }
91
92 @Override
93 public String getVersion()
94 {
95 return coordinate.getVersion();
96 }
97
98 @Override
99 public boolean isOptional()
100 {
101 throw new UnsupportedOperationException();
102 }
103
104 @Override
105 public void removeExclusion( Exclusion exclusion )
106 {
107 throw new UnsupportedOperationException();
108 }
109
110 @Override
111 public void setArtifactId( String artifactId )
112 {
113 throw new UnsupportedOperationException();
114 }
115
116 @Override
117 public void setClassifier( String classifier )
118 {
119 throw new UnsupportedOperationException();
120 }
121
122 @Override
123 public void setExclusions( List<Exclusion> exclusions )
124 {
125 throw new UnsupportedOperationException();
126 }
127
128 @Override
129 public void setGroupId( String groupId )
130 {
131 throw new UnsupportedOperationException();
132 }
133
134 @Override
135 public void setOptional( boolean optional )
136 {
137 throw new UnsupportedOperationException();
138 }
139
140 @Override
141 public void setScope( String scope )
142 {
143 throw new UnsupportedOperationException();
144 }
145
146 @Override
147 public void setSystemPath( String systemPath )
148 {
149 throw new UnsupportedOperationException();
150 }
151
152 @Override
153 public void setType( String type )
154 {
155 throw new UnsupportedOperationException();
156 }
157
158 @Override
159 public void setVersion( String version )
160 {
161 coordinate.setVersion( version );
162 }
163
164 @Override
165 public String getName()
166 {
167 return "dependency";
168 }
169 }