View Javadoc

1   /*
2    =================== DO NOT EDIT THIS FILE ====================
3    Generated by Modello 1.0.1 on 2009-03-27 22:27:26,
4    any modifications will be overwritten.
5    ==============================================================
6    */
7   
8   package com.mindtree.techworks.insight.releng.mvn.nsis.model;
9   
10  /**
11   * Defines a section.
12   * 
13   * @version $Revision$ $Date$
14   */
15  public class Section
16      implements java.io.Serializable
17  {
18  
19        //--------------------------/
20       //- Class/Member Variables -/
21      //--------------------------/
22  
23      /**
24       * The name of the section.
25       */
26      private String name;
27  
28      /**
29       * The descriptive name of the section.
30       */
31      private String description = "";
32  
33      /**
34       * Checks if the section is optional.
35       */
36      private boolean optional = false;
37  
38      /**
39       * Indicates if the section is bold.
40       */
41      private boolean bold = false;
42  
43      /**
44       * 
45       * 						Indicates if the section is hidden
46       * 					.
47       */
48      private boolean hidden = false;
49  
50      /**
51       * Field inInsTypes.
52       */
53      private java.util.List/*<String>*/ inInsTypes;
54  
55      /**
56       * Field fileSets.
57       */
58      private java.util.List/*<FileSet>*/ fileSets;
59  
60      /**
61       * Field files.
62       */
63      private java.util.List/*<FileItem>*/ files;
64  
65      /**
66       * Field dependencySets.
67       */
68      private java.util.List/*<DependencySet>*/ dependencySets;
69  
70      /**
71       * Field shortcuts.
72       */
73      private java.util.List/*<ShortCut>*/ shortcuts;
74  
75  
76        //-----------/
77       //- Methods -/
78      //-----------/
79  
80      /**
81       * Method addDependencySet.
82       * 
83       * @param dependencySet
84       */
85      public void addDependencySet( DependencySet dependencySet )
86      {
87          if ( !(dependencySet instanceof DependencySet) )
88          {
89              throw new ClassCastException( "Section.addDependencySets(dependencySet) parameter must be instanceof " + DependencySet.class.getName() );
90          }
91          getDependencySets().add( dependencySet );
92      } //-- void addDependencySet( DependencySet )
93  
94      /**
95       * Method addFile.
96       * 
97       * @param fileItem
98       */
99      public void addFile( FileItem fileItem )
100     {
101         if ( !(fileItem instanceof FileItem) )
102         {
103             throw new ClassCastException( "Section.addFiles(fileItem) parameter must be instanceof " + FileItem.class.getName() );
104         }
105         getFiles().add( fileItem );
106     } //-- void addFile( FileItem )
107 
108     /**
109      * Method addFileSet.
110      * 
111      * @param fileSet
112      */
113     public void addFileSet( FileSet fileSet )
114     {
115         if ( !(fileSet instanceof FileSet) )
116         {
117             throw new ClassCastException( "Section.addFileSets(fileSet) parameter must be instanceof " + FileSet.class.getName() );
118         }
119         getFileSets().add( fileSet );
120     } //-- void addFileSet( FileSet )
121 
122     /**
123      * Method addInInsType.
124      * 
125      * @param string
126      */
127     public void addInInsType( String string )
128     {
129         if ( !(string instanceof String) )
130         {
131             throw new ClassCastException( "Section.addInInsTypes(string) parameter must be instanceof " + String.class.getName() );
132         }
133         getInInsTypes().add( string );
134     } //-- void addInInsType( String )
135 
136     /**
137      * Method addShortcut.
138      * 
139      * @param shortCut
140      */
141     public void addShortcut( ShortCut shortCut )
142     {
143         if ( !(shortCut instanceof ShortCut) )
144         {
145             throw new ClassCastException( "Section.addShortcuts(shortCut) parameter must be instanceof " + ShortCut.class.getName() );
146         }
147         getShortcuts().add( shortCut );
148     } //-- void addShortcut( ShortCut )
149 
150     /**
151      * Method getDependencySets.
152      * 
153      * @return List
154      */
155     public java.util.List/*<DependencySet>*/ getDependencySets()
156     {
157         if ( this.dependencySets == null )
158         {
159             this.dependencySets = new java.util.ArrayList/*<DependencySet>*/();
160         }
161 
162         return this.dependencySets;
163     } //-- java.util.List/*<DependencySet>*/ getDependencySets()
164 
165     /**
166      * Get the descriptive name of the section.
167      * 
168      * @return String
169      */
170     public String getDescription()
171     {
172         return this.description;
173     } //-- String getDescription()
174 
175     /**
176      * Method getFileSets.
177      * 
178      * @return List
179      */
180     public java.util.List/*<FileSet>*/ getFileSets()
181     {
182         if ( this.fileSets == null )
183         {
184             this.fileSets = new java.util.ArrayList/*<FileSet>*/();
185         }
186 
187         return this.fileSets;
188     } //-- java.util.List/*<FileSet>*/ getFileSets()
189 
190     /**
191      * Method getFiles.
192      * 
193      * @return List
194      */
195     public java.util.List/*<FileItem>*/ getFiles()
196     {
197         if ( this.files == null )
198         {
199             this.files = new java.util.ArrayList/*<FileItem>*/();
200         }
201 
202         return this.files;
203     } //-- java.util.List/*<FileItem>*/ getFiles()
204 
205     /**
206      * Method getInInsTypes.
207      * 
208      * @return List
209      */
210     public java.util.List/*<String>*/ getInInsTypes()
211     {
212         if ( this.inInsTypes == null )
213         {
214             this.inInsTypes = new java.util.ArrayList/*<String>*/();
215         }
216 
217         return this.inInsTypes;
218     } //-- java.util.List/*<String>*/ getInInsTypes()
219 
220     /**
221      * Get the name of the section.
222      * 
223      * @return String
224      */
225     public String getName()
226     {
227         return this.name;
228     } //-- String getName()
229 
230     /**
231      * Method getShortcuts.
232      * 
233      * @return List
234      */
235     public java.util.List/*<ShortCut>*/ getShortcuts()
236     {
237         if ( this.shortcuts == null )
238         {
239             this.shortcuts = new java.util.ArrayList/*<ShortCut>*/();
240         }
241 
242         return this.shortcuts;
243     } //-- java.util.List/*<ShortCut>*/ getShortcuts()
244 
245     /**
246      * Get indicates if the section is bold.
247      * 
248      * @return boolean
249      */
250     public boolean isBold()
251     {
252         return this.bold;
253     } //-- boolean isBold()
254 
255     /**
256      * Get indicates if the section is hidden.
257      * 
258      * @return boolean
259      */
260     public boolean isHidden()
261     {
262         return this.hidden;
263     } //-- boolean isHidden()
264 
265     /**
266      * Get checks if the section is optional.
267      * 
268      * @return boolean
269      */
270     public boolean isOptional()
271     {
272         return this.optional;
273     } //-- boolean isOptional()
274 
275     /**
276      * Method removeDependencySet.
277      * 
278      * @param dependencySet
279      */
280     public void removeDependencySet( DependencySet dependencySet )
281     {
282         if ( !(dependencySet instanceof DependencySet) )
283         {
284             throw new ClassCastException( "Section.removeDependencySets(dependencySet) parameter must be instanceof " + DependencySet.class.getName() );
285         }
286         getDependencySets().remove( dependencySet );
287     } //-- void removeDependencySet( DependencySet )
288 
289     /**
290      * Method removeFile.
291      * 
292      * @param fileItem
293      */
294     public void removeFile( FileItem fileItem )
295     {
296         if ( !(fileItem instanceof FileItem) )
297         {
298             throw new ClassCastException( "Section.removeFiles(fileItem) parameter must be instanceof " + FileItem.class.getName() );
299         }
300         getFiles().remove( fileItem );
301     } //-- void removeFile( FileItem )
302 
303     /**
304      * Method removeFileSet.
305      * 
306      * @param fileSet
307      */
308     public void removeFileSet( FileSet fileSet )
309     {
310         if ( !(fileSet instanceof FileSet) )
311         {
312             throw new ClassCastException( "Section.removeFileSets(fileSet) parameter must be instanceof " + FileSet.class.getName() );
313         }
314         getFileSets().remove( fileSet );
315     } //-- void removeFileSet( FileSet )
316 
317     /**
318      * Method removeInInsType.
319      * 
320      * @param string
321      */
322     public void removeInInsType( String string )
323     {
324         if ( !(string instanceof String) )
325         {
326             throw new ClassCastException( "Section.removeInInsTypes(string) parameter must be instanceof " + String.class.getName() );
327         }
328         getInInsTypes().remove( string );
329     } //-- void removeInInsType( String )
330 
331     /**
332      * Method removeShortcut.
333      * 
334      * @param shortCut
335      */
336     public void removeShortcut( ShortCut shortCut )
337     {
338         if ( !(shortCut instanceof ShortCut) )
339         {
340             throw new ClassCastException( "Section.removeShortcuts(shortCut) parameter must be instanceof " + ShortCut.class.getName() );
341         }
342         getShortcuts().remove( shortCut );
343     } //-- void removeShortcut( ShortCut )
344 
345     /**
346      * Set indicates if the section is bold.
347      * 
348      * @param bold
349      */
350     public void setBold( boolean bold )
351     {
352         this.bold = bold;
353     } //-- void setBold( boolean )
354 
355     /**
356      * Set specifies which dependencies to include in the assembly.
357      * A
358      *             dependencySet is specified by providing one or
359      * more of
360      *             &lt;dependencySet&gt; subelements.
361      * 
362      * @param dependencySets
363      */
364     public void setDependencySets( java.util.List/*<DependencySet>*/ dependencySets )
365     {
366         this.dependencySets = dependencySets;
367     } //-- void setDependencySets( java.util.List )
368 
369     /**
370      * Set the descriptive name of the section.
371      * 
372      * @param description
373      */
374     public void setDescription( String description )
375     {
376         this.description = description;
377     } //-- void setDescription( String )
378 
379     /**
380      * Set specifies which groups of files to include in the
381      * assembly. A
382      *             fileSet is specified by providing one or more of
383      * &lt;fileSet&gt;
384      *             subelements.
385      * 
386      * @param fileSets
387      */
388     public void setFileSets( java.util.List/*<FileSet>*/ fileSets )
389     {
390         this.fileSets = fileSets;
391     } //-- void setFileSets( java.util.List )
392 
393     /**
394      * Set specifies which single files to include in the assembly.
395      * A file
396      *             is specified by providing one or more of
397      * &lt;file&gt;
398      *             subelements.
399      * 
400      * @param files
401      */
402     public void setFiles( java.util.List/*<FileItem>*/ files )
403     {
404         this.files = files;
405     } //-- void setFiles( java.util.List )
406 
407     /**
408      * Set indicates if the section is hidden.
409      * 
410      * @param hidden
411      */
412     public void setHidden( boolean hidden )
413     {
414         this.hidden = hidden;
415     } //-- void setHidden( boolean )
416 
417     /**
418      * Set this command specifies which install types (see
419      * 						InstType) the current section defaults to the enabled
420      * 						state in. For a read only section specify RO, or
421      * insert
422      * 						numbers for the corresponding InstType values with an
423      * 1
424      * 						based index.
425      * 
426      * @param inInsTypes
427      */
428     public void setInInsTypes( java.util.List/*<String>*/ inInsTypes )
429     {
430         this.inInsTypes = inInsTypes;
431     } //-- void setInInsTypes( java.util.List )
432 
433     /**
434      * Set the name of the section.
435      * 
436      * @param name
437      */
438     public void setName( String name )
439     {
440         this.name = name;
441     } //-- void setName( String )
442 
443     /**
444      * Set checks if the section is optional.
445      * 
446      * @param optional
447      */
448     public void setOptional( boolean optional )
449     {
450         this.optional = optional;
451     } //-- void setOptional( boolean )
452 
453     /**
454      * Set the shortcuts that need to be created in this section.
455      * 
456      * @param shortcuts
457      */
458     public void setShortcuts( java.util.List/*<ShortCut>*/ shortcuts )
459     {
460         this.shortcuts = shortcuts;
461     } //-- void setShortcuts( java.util.List )
462 
463 
464 }