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   * Template which contains some buildDefinitions.
31   * 
32   * @version $Revision$ $Date$
33   */
34  @SuppressWarnings( "all" )
35  public class BuildDefinitionTemplate
36      implements java.io.Serializable
37  {
38  
39        //--------------------------/
40       //- Class/Member Variables -/
41      //--------------------------/
42  
43      /**
44       * Field id.
45       */
46      private int id = 0;
47  
48      /**
49       * Field name.
50       */
51      private String name;
52  
53      /**
54       * 
55       *             true if this definition is a continuum default
56       * build def (cannot be removed)
57       *           .
58       */
59      private boolean continuumDefault = false;
60  
61      /**
62       * type of the buid BuildDefinitionTemplate use for default.
63       */
64      private String type;
65  
66      /**
67       * Field buildDefinitions.
68       */
69      private java.util.List<BuildDefinition> buildDefinitions;
70  
71  
72        //-----------/
73       //- Methods -/
74      //-----------/
75  
76      /**
77       * Method addBuildDefinition.
78       * 
79       * @param buildDefinition
80       */
81      public void addBuildDefinition( BuildDefinition buildDefinition )
82      {
83          getBuildDefinitions().add( buildDefinition );
84      } //-- void addBuildDefinition( BuildDefinition )
85  
86      /**
87       * Method equals.
88       * 
89       * @param other
90       * @return boolean
91       */
92      public boolean equals( Object other )
93      {
94          if ( this == other )
95          {
96              return true;
97          }
98  
99          if ( !( other instanceof BuildDefinitionTemplate ) )
100         {
101             return false;
102         }
103 
104         BuildDefinitionTemplate that = (BuildDefinitionTemplate) other;
105         boolean result = true;
106 
107         result = result && id == that.id;
108 
109         return result;
110     } //-- boolean equals( Object )
111 
112     /**
113      * Method getBuildDefinitions.
114      * 
115      * @return List
116      */
117     public java.util.List<BuildDefinition> getBuildDefinitions()
118     {
119         if ( this.buildDefinitions == null )
120         {
121             this.buildDefinitions = new java.util.ArrayList<BuildDefinition>();
122         }
123 
124         return this.buildDefinitions;
125     } //-- java.util.List<BuildDefinition> getBuildDefinitions()
126 
127     /**
128      * Get the id field.
129      * 
130      * @return int
131      */
132     public int getId()
133     {
134         return this.id;
135     } //-- int getId()
136 
137     /**
138      * Get the name field.
139      * 
140      * @return String
141      */
142     public String getName()
143     {
144         return this.name;
145     } //-- String getName()
146 
147     /**
148      * Get type of the buid BuildDefinitionTemplate use for
149      * default.
150      * 
151      * @return String
152      */
153     public String getType()
154     {
155         return this.type;
156     } //-- String getType()
157 
158     /**
159      * Method hashCode.
160      * 
161      * @return int
162      */
163     public int hashCode()
164     {
165         int result = 17;
166 
167         result = 37 * result + (int) id;
168 
169         return result;
170     } //-- int hashCode()
171 
172     /**
173      * Get true if this definition is a continuum default build def
174      * (cannot be removed).
175      * 
176      * @return boolean
177      */
178     public boolean isContinuumDefault()
179     {
180         return this.continuumDefault;
181     } //-- boolean isContinuumDefault()
182 
183     /**
184      * Method removeBuildDefinition.
185      * 
186      * @param buildDefinition
187      */
188     public void removeBuildDefinition( BuildDefinition buildDefinition )
189     {
190         getBuildDefinitions().remove( buildDefinition );
191     } //-- void removeBuildDefinition( BuildDefinition )
192 
193     /**
194      * Set the buildDefinitions field.
195      * 
196      * @param buildDefinitions
197      */
198     public void setBuildDefinitions( java.util.List<BuildDefinition> buildDefinitions )
199     {
200         this.buildDefinitions = buildDefinitions;
201     } //-- void setBuildDefinitions( java.util.List )
202 
203     /**
204      * Set true if this definition is a continuum default build def
205      * (cannot be removed).
206      * 
207      * @param continuumDefault
208      */
209     public void setContinuumDefault( boolean continuumDefault )
210     {
211         this.continuumDefault = continuumDefault;
212     } //-- void setContinuumDefault( boolean )
213 
214     /**
215      * Set the id field.
216      * 
217      * @param id
218      */
219     public void setId( int id )
220     {
221         this.id = id;
222     } //-- void setId( int )
223 
224     /**
225      * Set the name field.
226      * 
227      * @param name
228      */
229     public void setName( String name )
230     {
231         this.name = name;
232     } //-- void setName( String )
233 
234     /**
235      * Set type of the buid BuildDefinitionTemplate use for
236      * default.
237      * 
238      * @param type
239      */
240     public void setType( String type )
241     {
242         this.type = type;
243     } //-- void setType( String )
244 
245     /**
246      * Method toString.
247      * 
248      * @return String
249      */
250     public java.lang.String toString()
251     {
252         StringBuilder buf = new StringBuilder( 128 );
253 
254         buf.append( "id = '" );
255         buf.append( getId() );
256         buf.append( "'" );
257 
258         return buf.toString();
259     } //-- java.lang.String toString()
260 
261 }