View Javadoc

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