1
2
3
4
5
6 package org.apache.maven.model;
7
8
9
10
11
12
13
14
15 @SuppressWarnings( "all" )
16 public class MailingList
17 implements java.io.Serializable, java.lang.Cloneable, org.apache.maven.model.InputLocationTracker
18 {
19
20
21
22
23
24
25
26
27
28
29
30
31 private String name;
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46 private String subscribe;
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61 private String unsubscribe;
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76 private String post;
77
78
79
80
81
82 private String archive;
83
84
85
86
87 private java.util.List<String> otherArchives;
88
89
90
91
92 private java.util.Map<Object, InputLocation> locations;
93
94
95
96
97 private InputLocation location;
98
99
100
101
102 private InputLocation nameLocation;
103
104
105
106
107 private InputLocation subscribeLocation;
108
109
110
111
112 private InputLocation unsubscribeLocation;
113
114
115
116
117 private InputLocation postLocation;
118
119
120
121
122 private InputLocation archiveLocation;
123
124
125
126
127 private InputLocation otherArchivesLocation;
128
129
130
131
132
133
134
135
136
137
138
139 public void addOtherArchive( String string )
140 {
141 getOtherArchives().add( string );
142 }
143
144
145
146
147
148
149 public MailingList clone()
150 {
151 try
152 {
153 MailingList copy = (MailingList) super.clone();
154
155 if ( this.otherArchives != null )
156 {
157 copy.otherArchives = new java.util.ArrayList<String>();
158 copy.otherArchives.addAll( this.otherArchives );
159 }
160
161 if ( copy.locations != null )
162 {
163 copy.locations = new java.util.LinkedHashMap( copy.locations );
164 }
165
166 return copy;
167 }
168 catch ( java.lang.Exception ex )
169 {
170 throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
171 + " does not support clone()" ).initCause( ex );
172 }
173 }
174
175
176
177
178
179
180
181 public String getArchive()
182 {
183 return this.archive;
184 }
185
186
187
188
189
190
191
192 public InputLocation getLocation( Object key )
193 {
194 if ( key instanceof String )
195 {
196 switch ( ( String ) key )
197 {
198 case "" :
199 {
200 return this.location;
201 }
202 case "name" :
203 {
204 return nameLocation;
205 }
206 case "subscribe" :
207 {
208 return subscribeLocation;
209 }
210 case "unsubscribe" :
211 {
212 return unsubscribeLocation;
213 }
214 case "post" :
215 {
216 return postLocation;
217 }
218 case "archive" :
219 {
220 return archiveLocation;
221 }
222 case "otherArchives" :
223 {
224 return otherArchivesLocation;
225 }
226 default :
227 {
228 return getOtherLocation( key );
229 }
230 }
231 }
232 else
233 {
234 return getOtherLocation( key );
235 }
236 }
237
238
239
240
241
242
243 public String getName()
244 {
245 return this.name;
246 }
247
248
249
250
251
252
253 public java.util.List<String> getOtherArchives()
254 {
255 if ( this.otherArchives == null )
256 {
257 this.otherArchives = new java.util.ArrayList<String>();
258 }
259
260 return this.otherArchives;
261 }
262
263
264
265
266
267
268
269 public void setLocation( Object key, InputLocation location )
270 {
271 if ( key instanceof String )
272 {
273 switch ( ( String ) key )
274 {
275 case "" :
276 {
277 this.location = location;
278 return;
279 }
280 case "name" :
281 {
282 nameLocation = location;
283 return;
284 }
285 case "subscribe" :
286 {
287 subscribeLocation = location;
288 return;
289 }
290 case "unsubscribe" :
291 {
292 unsubscribeLocation = location;
293 return;
294 }
295 case "post" :
296 {
297 postLocation = location;
298 return;
299 }
300 case "archive" :
301 {
302 archiveLocation = location;
303 return;
304 }
305 case "otherArchives" :
306 {
307 otherArchivesLocation = location;
308 return;
309 }
310 default :
311 {
312 setOtherLocation( key, location );
313 return;
314 }
315 }
316 }
317 else
318 {
319 setOtherLocation( key, location );
320 }
321 }
322
323
324
325
326
327
328
329 public void setOtherLocation( Object key, InputLocation location )
330 {
331 if ( location != null )
332 {
333 if ( this.locations == null )
334 {
335 this.locations = new java.util.LinkedHashMap<Object, InputLocation>();
336 }
337 this.locations.put( key, location );
338 }
339 }
340
341
342
343
344
345
346
347 private InputLocation getOtherLocation( Object key )
348 {
349 return ( locations != null ) ? locations.get( key ) : null;
350 }
351
352
353
354
355
356
357
358
359
360
361
362 public String getPost()
363 {
364 return this.post;
365 }
366
367
368
369
370
371
372
373
374
375
376
377
378 public String getSubscribe()
379 {
380 return this.subscribe;
381 }
382
383
384
385
386
387
388
389
390
391
392
393
394 public String getUnsubscribe()
395 {
396 return this.unsubscribe;
397 }
398
399
400
401
402
403
404 public void removeOtherArchive( String string )
405 {
406 getOtherArchives().remove( string );
407 }
408
409
410
411
412
413
414
415 public void setArchive( String archive )
416 {
417 this.archive = archive;
418 }
419
420
421
422
423
424
425 public void setName( String name )
426 {
427 this.name = name;
428 }
429
430
431
432
433
434
435
436 public void setOtherArchives( java.util.List<String> otherArchives )
437 {
438 this.otherArchives = otherArchives;
439 }
440
441
442
443
444
445
446
447
448
449
450
451 public void setPost( String post )
452 {
453 this.post = post;
454 }
455
456
457
458
459
460
461
462
463
464
465
466
467 public void setSubscribe( String subscribe )
468 {
469 this.subscribe = subscribe;
470 }
471
472
473
474
475
476
477
478
479
480
481
482
483 public void setUnsubscribe( String unsubscribe )
484 {
485 this.unsubscribe = unsubscribe;
486 }
487
488 }