View Javadoc

1   /*
2    =================== DO NOT EDIT THIS FILE ====================
3    Generated by Modello 1.1 on 2011-09-18 11:21:46,
4    any modifications will be overwritten.
5    ==============================================================
6    */
7   
8   package org.apache.maven.continuum.model.project;
9   
10    //---------------------------------/
11   //- Imported classes and packages -/
12  //---------------------------------/
13  
14  import org.apache.continuum.model.project.ProjectScmRoot;
15  import org.apache.continuum.model.release.ContinuumReleaseResult;
16  import org.apache.continuum.model.repository.AbstractPurgeConfiguration;
17  import org.apache.continuum.model.repository.DirectoryPurgeConfiguration;
18  import org.apache.continuum.model.repository.LocalRepository;
19  import org.apache.continuum.model.repository.RepositoryPurgeConfiguration;
20  import org.apache.maven.continuum.model.scm.ChangeFile;
21  import org.apache.maven.continuum.model.scm.ChangeSet;
22  import org.apache.maven.continuum.model.scm.ScmResult;
23  import org.apache.maven.continuum.model.system.Installation;
24  import org.apache.maven.continuum.model.system.NotificationAddress;
25  import org.apache.maven.continuum.model.system.Profile;
26  import org.apache.maven.continuum.model.system.SystemConfiguration;
27  import org.apache.maven.continuum.project.ContinuumProjectState;
28  
29  /**
30   * 
31   *         Schedule for a project.
32   *       
33   * 
34   * @version $Revision$ $Date$
35   */
36  @SuppressWarnings( "all" )
37  public class Schedule
38      implements java.io.Serializable
39  {
40  
41        //--------------------------/
42       //- Class/Member Variables -/
43      //--------------------------/
44  
45      /**
46       * Field id.
47       */
48      private int id = 0;
49  
50      /**
51       * Field active.
52       */
53      private boolean active = false;
54  
55      /**
56       * Field name.
57       */
58      private String name;
59  
60      /**
61       * Field description.
62       */
63      private String description;
64  
65      /**
66       * 
67       *             Delay in seconds.
68       *           
69       */
70      private int delay = 0;
71  
72      /**
73       * 
74       *             Maximum execution time of a job in seconds
75       * before it's
76       *             terminated.
77       *           
78       */
79      private int maxJobExecutionTime = 3600;
80  
81      /**
82       * Field cronExpression.
83       */
84      private String cronExpression;
85  
86      /**
87       * Field buildQueues.
88       */
89      private java.util.List<BuildQueue> buildQueues;
90  
91  
92        //-----------/
93       //- Methods -/
94      //-----------/
95  
96      /**
97       * Method addBuildQueue.
98       * 
99       * @param buildQueue
100      */
101     public void addBuildQueue( BuildQueue buildQueue )
102     {
103         getBuildQueues().add( buildQueue );
104     } //-- void addBuildQueue( BuildQueue )
105 
106     /**
107      * Method equals.
108      * 
109      * @param other
110      * @return boolean
111      */
112     public boolean equals( Object other )
113     {
114         if ( this == other )
115         {
116             return true;
117         }
118 
119         if ( !( other instanceof Schedule ) )
120         {
121             return false;
122         }
123 
124         Schedule that = (Schedule) other;
125         boolean result = true;
126 
127         result = result && id == that.id;
128 
129         return result;
130     } //-- boolean equals( Object )
131 
132     /**
133      * Method getBuildQueues.
134      * 
135      * @return List
136      */
137     public java.util.List<BuildQueue> getBuildQueues()
138     {
139         if ( this.buildQueues == null )
140         {
141             this.buildQueues = new java.util.ArrayList<BuildQueue>();
142         }
143 
144         return this.buildQueues;
145     } //-- java.util.List<BuildQueue> getBuildQueues()
146 
147     /**
148      * Get the cronExpression field.
149      * 
150      * @return String
151      */
152     public String getCronExpression()
153     {
154         return this.cronExpression;
155     } //-- String getCronExpression()
156 
157     /**
158      * Get delay in seconds.
159      * 
160      * @return int
161      */
162     public int getDelay()
163     {
164         return this.delay;
165     } //-- int getDelay()
166 
167     /**
168      * Get the description field.
169      * 
170      * @return String
171      */
172     public String getDescription()
173     {
174         return this.description;
175     } //-- String getDescription()
176 
177     /**
178      * Get the id field.
179      * 
180      * @return int
181      */
182     public int getId()
183     {
184         return this.id;
185     } //-- int getId()
186 
187     /**
188      * Get maximum execution time of a job in seconds before it's
189      *             terminated.
190      * 
191      * @return int
192      */
193     public int getMaxJobExecutionTime()
194     {
195         return this.maxJobExecutionTime;
196     } //-- int getMaxJobExecutionTime()
197 
198     /**
199      * Get the name field.
200      * 
201      * @return String
202      */
203     public String getName()
204     {
205         return this.name;
206     } //-- String getName()
207 
208     /**
209      * Method hashCode.
210      * 
211      * @return int
212      */
213     public int hashCode()
214     {
215         int result = 17;
216 
217         result = 37 * result + (int) id;
218 
219         return result;
220     } //-- int hashCode()
221 
222     /**
223      * Get the active field.
224      * 
225      * @return boolean
226      */
227     public boolean isActive()
228     {
229         return this.active;
230     } //-- boolean isActive()
231 
232     /**
233      * Method removeBuildQueue.
234      * 
235      * @param buildQueue
236      */
237     public void removeBuildQueue( BuildQueue buildQueue )
238     {
239         getBuildQueues().remove( buildQueue );
240     } //-- void removeBuildQueue( BuildQueue )
241 
242     /**
243      * Set the active field.
244      * 
245      * @param active
246      */
247     public void setActive( boolean active )
248     {
249         this.active = active;
250     } //-- void setActive( boolean )
251 
252     /**
253      * Set the buildQueues field.
254      * 
255      * @param buildQueues
256      */
257     public void setBuildQueues( java.util.List<BuildQueue> buildQueues )
258     {
259         this.buildQueues = buildQueues;
260     } //-- void setBuildQueues( java.util.List )
261 
262     /**
263      * Set the cronExpression field.
264      * 
265      * @param cronExpression
266      */
267     public void setCronExpression( String cronExpression )
268     {
269         this.cronExpression = cronExpression;
270     } //-- void setCronExpression( String )
271 
272     /**
273      * Set delay in seconds.
274      * 
275      * @param delay
276      */
277     public void setDelay( int delay )
278     {
279         this.delay = delay;
280     } //-- void setDelay( int )
281 
282     /**
283      * Set the description field.
284      * 
285      * @param description
286      */
287     public void setDescription( String description )
288     {
289         this.description = description;
290     } //-- void setDescription( String )
291 
292     /**
293      * Set the id field.
294      * 
295      * @param id
296      */
297     public void setId( int id )
298     {
299         this.id = id;
300     } //-- void setId( int )
301 
302     /**
303      * Set maximum execution time of a job in seconds before it's
304      *             terminated.
305      * 
306      * @param maxJobExecutionTime
307      */
308     public void setMaxJobExecutionTime( int maxJobExecutionTime )
309     {
310         this.maxJobExecutionTime = maxJobExecutionTime;
311     } //-- void setMaxJobExecutionTime( int )
312 
313     /**
314      * Set the name field.
315      * 
316      * @param name
317      */
318     public void setName( String name )
319     {
320         this.name = name;
321     } //-- void setName( String )
322 
323     /**
324      * Method toString.
325      * 
326      * @return String
327      */
328     public java.lang.String toString()
329     {
330         StringBuilder buf = new StringBuilder( 128 );
331 
332         buf.append( "id = '" );
333         buf.append( getId() );
334         buf.append( "'" );
335 
336         return buf.toString();
337     } //-- java.lang.String toString()
338 
339 }