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 Profile
17 extends ModelBase
18 implements java.io.Serializable, java.lang.Cloneable
19 {
20
21
22
23
24
25
26
27
28
29
30
31
32 private String id = "default";
33
34
35
36
37
38
39 private Activation activation;
40
41
42
43
44 private BuildBase build;
45
46
47
48
49
50
51
52
53
54
55
56 public Profile clone()
57 {
58 try
59 {
60 Profile copy = (Profile) super.clone();
61
62 if ( this.activation != null )
63 {
64 copy.activation = (Activation) this.activation.clone();
65 }
66
67 if ( this.build != null )
68 {
69 copy.build = (BuildBase) this.build.clone();
70 }
71
72 return copy;
73 }
74 catch ( java.lang.Exception ex )
75 {
76 throw (java.lang.RuntimeException) new java.lang.UnsupportedOperationException( getClass().getName()
77 + " does not support clone()" ).initCause( ex );
78 }
79 }
80
81
82
83
84
85
86
87
88 public Activation getActivation()
89 {
90 return this.activation;
91 }
92
93
94
95
96
97
98 public BuildBase getBuild()
99 {
100 return this.build;
101 }
102
103
104
105
106
107
108
109
110
111 public String getId()
112 {
113 return this.id;
114 }
115
116
117
118
119
120
121
122
123 public void setActivation( Activation activation )
124 {
125 this.activation = activation;
126 }
127
128
129
130
131
132
133 public void setBuild( BuildBase build )
134 {
135 this.build = build;
136 }
137
138
139
140
141
142
143
144
145
146 public void setId( String id )
147 {
148 this.id = id;
149 }
150
151
152
153 public static final String SOURCE_POM = "pom";
154
155 public static final String SOURCE_SETTINGS = "settings.xml";
156
157
158
159 private String source = SOURCE_POM;
160
161 public void setSource( String source )
162 {
163 this.source = source;
164 }
165
166 public String getSource()
167 {
168 return source;
169 }
170
171
172
173
174 public String toString()
175 {
176 return "Profile {id: " + getId() + ", source: " + getSource() + "}";
177 }
178
179
180 }