1
2
3
4
5
6
7
8 package org.apache.maven.plugin.javadoc.options;
9
10
11
12
13
14
15
16 @SuppressWarnings( "all" )
17 public class JavadocPathArtifact
18 implements java.io.Serializable
19 {
20
21
22
23
24
25
26
27
28 private String groupId;
29
30
31
32
33 private String artifactId;
34
35
36
37
38 private String version;
39
40
41
42
43
44
45
46
47
48
49
50
51 public boolean equals( Object other )
52 {
53 if ( this == other )
54 {
55 return true;
56 }
57
58 if ( !( other instanceof JavadocPathArtifact ) )
59 {
60 return false;
61 }
62
63 JavadocPathArtifact that = (JavadocPathArtifact) other;
64 boolean result = true;
65
66 result = result && ( getGroupId() == null ? that.getGroupId() == null : getGroupId().equals( that.getGroupId() ) );
67 result = result && ( getArtifactId() == null ? that.getArtifactId() == null : getArtifactId().equals( that.getArtifactId() ) );
68 result = result && ( getVersion() == null ? that.getVersion() == null : getVersion().equals( that.getVersion() ) );
69
70 return result;
71 }
72
73
74
75
76
77
78 public String getArtifactId()
79 {
80 return this.artifactId;
81 }
82
83
84
85
86
87
88 public String getGroupId()
89 {
90 return this.groupId;
91 }
92
93
94
95
96
97
98 public String getVersion()
99 {
100 return this.version;
101 }
102
103
104
105
106
107
108 public int hashCode()
109 {
110 int result = 17;
111
112 result = 37 * result + ( groupId != null ? groupId.hashCode() : 0 );
113 result = 37 * result + ( artifactId != null ? artifactId.hashCode() : 0 );
114 result = 37 * result + ( version != null ? version.hashCode() : 0 );
115
116 return result;
117 }
118
119
120
121
122
123
124 public void setArtifactId( String artifactId )
125 {
126 this.artifactId = artifactId;
127 }
128
129
130
131
132
133
134 public void setGroupId( String groupId )
135 {
136 this.groupId = groupId;
137 }
138
139
140
141
142
143
144 public void setVersion( String version )
145 {
146 this.version = version;
147 }
148
149
150
151
152
153
154 public java.lang.String toString()
155 {
156 StringBuilder buf = new StringBuilder( 128 );
157
158 buf.append( "groupId = '" );
159 buf.append( getGroupId() );
160 buf.append( "'" );
161 buf.append( "\n" );
162 buf.append( "artifactId = '" );
163 buf.append( getArtifactId() );
164 buf.append( "'" );
165 buf.append( "\n" );
166 buf.append( "version = '" );
167 buf.append( getVersion() );
168 buf.append( "'" );
169
170 return buf.toString();
171 }
172
173 }