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 Repository
17 extends RepositoryBase
18 implements java.io.Serializable, java.lang.Cloneable
19 {
20
21
22
23
24
25
26
27
28 private RepositoryPolicy releases;
29
30
31
32
33 private RepositoryPolicy snapshots;
34
35
36
37
38
39
40
41
42
43
44
45 public Repository clone()
46 {
47 try
48 {
49 Repository copy = (Repository) super.clone();
50
51 if ( this.releases != null )
52 {
53 copy.releases = (RepositoryPolicy) this.releases.clone();
54 }
55
56 if ( this.snapshots != null )
57 {
58 copy.snapshots = (RepositoryPolicy) this.snapshots.clone();
59 }
60
61 return copy;
62 }
63 catch ( java.lang.Exception ex )
64 {
65 throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
66 + " does not support clone()" ).initCause( ex );
67 }
68 }
69
70
71
72
73
74
75
76 public RepositoryPolicy getReleases()
77 {
78 return this.releases;
79 }
80
81
82
83
84
85
86
87 public RepositoryPolicy getSnapshots()
88 {
89 return this.snapshots;
90 }
91
92
93
94
95
96
97
98 public void setReleases( RepositoryPolicy releases )
99 {
100 this.releases = releases;
101 }
102
103
104
105
106
107
108
109 public void setSnapshots( RepositoryPolicy snapshots )
110 {
111 this.snapshots = snapshots;
112 }
113
114 }