View Javadoc
1   /*
2    Licensed to the Apache Software Foundation (ASF) under one
3    or more contributor license agreements.  See the NOTICE file
4    distributed with this work for additional information
5    regarding copyright ownership.  The ASF licenses this file
6    to you under the Apache License, Version 2.0 (the
7    "License"); you may not use this file except in compliance
8    with the License.  You may obtain a copy of the License at
9    
10       http://www.apache.org/licenses/LICENSE-2.0
11   
12   Unless required by applicable law or agreed to in writing,
13   software distributed under the License is distributed on an
14   "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15   KIND, either express or implied.  See the License for the
16   specific language governing permissions and limitations
17   under the License.
18   =================== DO NOT EDIT THIS FILE ====================
19   Generated by Modello 2.5.1,
20   any modifications will be overwritten.
21   ==============================================================
22   */
23  
24  package org.apache.maven.plugins.assembly.model;
25  
26  /**
27   * 
28   *         Contains configuration options for including the source
29   * files of a
30   *         project module in an assembly.
31   *       
32   * 
33   * @version $Revision$ $Date$
34   */
35  @SuppressWarnings( "all" )
36  public class ModuleSources
37      implements java.io.Serializable
38  {
39  
40        //--------------------------/
41       //- Class/Member Variables -/
42      //--------------------------/
43  
44      /**
45       * 
46       *             Whether standard exclusion patterns, such as
47       * those matching CVS and Subversion
48       *             metadata files, should be used when calculating
49       * the files affected by this set.
50       *             For backward compatibility, the default value is
51       * true. (Since 2.2)
52       *           .
53       */
54      private boolean useDefaultExcludes = true;
55  
56      /**
57       * 
58       *             Sets the output directory relative to the root
59       *             of the root directory of the assembly. For
60       * example,
61       *             "log" will put the specified files in the log
62       * directory.
63       *           
64       */
65      private String outputDirectory;
66  
67      /**
68       * Field includes.
69       */
70      private java.util.List<String> includes;
71  
72      /**
73       * Field excludes.
74       */
75      private java.util.List<String> excludes;
76  
77      /**
78       * 
79       *             
80       *             Similar to a UNIX permission, sets the file mode
81       * of the files included.
82       *             THIS IS AN OCTAL VALUE.
83       *             Format: (User)(Group)(Other) where each
84       * component is a sum of Read = 4,
85       *             Write = 2, and Execute = 1.  For example, the
86       * value 0644
87       *             translates to User read-write, Group and Other
88       * read-only. The default value is 0644.
89       *             <a
90       * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
91       * on unix-style permissions)</a>
92       *             
93       *           
94       */
95      private String fileMode;
96  
97      /**
98       * 
99       *             
100      *             Similar to a UNIX permission, sets the directory
101      * mode of the directories
102      *             included.
103      *             THIS IS AN OCTAL VALUE.
104      *             Format: (User)(Group)(Other) where each
105      * component is a sum of
106      *             Read = 4, Write = 2, and Execute = 1.  For
107      * example, the value
108      *             0755 translates to User read-write, Group and
109      * Other read-only. The default value is 0755.
110      *             <a
111      * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
112      * on unix-style permissions)</a>
113      *             
114      *           
115      */
116     private String directoryMode;
117 
118     /**
119      * Field fileSets.
120      */
121     private java.util.List<FileSet> fileSets;
122 
123     /**
124      * 
125      *             
126      *             Specifies whether the module's finalName should
127      * be prepended to the outputDirectory
128      *             values of any fileSets applied to it. Default
129      * value is true. (Since 2.2)
130      *             
131      *           .
132      */
133     private boolean includeModuleDirectory = true;
134 
135     /**
136      * 
137      *             
138      *             Specifies whether sub-module directories below
139      * the current module should be excluded
140      *             from fileSets applied to that module. This might
141      * be useful if you only mean to copy
142      *             the sources for the exact module list matched by
143      * this ModuleSet, ignoring (or processing
144      *             separately) the modules which exist in
145      * directories below the current one.
146      *             Default value is true. (Since 2.2)
147      *             
148      *           .
149      */
150     private boolean excludeSubModuleDirectories = true;
151 
152     /**
153      * 
154      *             Sets the mapping pattern for all module
155      * base-directories included in this assembly.
156      *             NOTE: This field is only used if
157      * includeModuleDirectory == true.
158      *             Default is the module's ${artifactId} in
159      * 2.2-beta-1, and ${module.artifactId} in subsequent versions.
160      * (Since 2.2)
161      *           .
162      */
163     private String outputDirectoryMapping = "${module.artifactId}";
164 
165 
166       //-----------/
167      //- Methods -/
168     //-----------/
169 
170     /**
171      * Method addExclude.
172      * 
173      * @param string a string object.
174      */
175     public void addExclude( String string )
176     {
177         getExcludes().add( string );
178     } //-- void addExclude( String )
179 
180     /**
181      * Method addFileSet.
182      * 
183      * @param fileSet a fileSet object.
184      */
185     public void addFileSet( FileSet fileSet )
186     {
187         getFileSets().add( fileSet );
188     } //-- void addFileSet( FileSet )
189 
190     /**
191      * Method addInclude.
192      * 
193      * @param string a string object.
194      */
195     public void addInclude( String string )
196     {
197         getIncludes().add( string );
198     } //-- void addInclude( String )
199 
200     /**
201      * Get similar to a UNIX permission, sets the directory mode of
202      * the directories
203      *             included.
204      *             THIS IS AN OCTAL VALUE.
205      *             Format: (User)(Group)(Other) where each
206      * component is a sum of
207      *             Read = 4, Write = 2, and Execute = 1.  For
208      * example, the value
209      *             0755 translates to User read-write, Group and
210      * Other read-only. The default value is 0755.
211      *             <a
212      * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
213      * on unix-style permissions)</a>
214      * 
215      * @return String
216      */
217     public String getDirectoryMode()
218     {
219         return this.directoryMode;
220     } //-- String getDirectoryMode()
221 
222     /**
223      * Method getExcludes.
224      * 
225      * @return List
226      */
227     public java.util.List<String> getExcludes()
228     {
229         if ( this.excludes == null )
230         {
231             this.excludes = new java.util.ArrayList<String>();
232         }
233 
234         return this.excludes;
235     } //-- java.util.List<String> getExcludes()
236 
237     /**
238      * Get similar to a UNIX permission, sets the file mode of the
239      * files included.
240      *             THIS IS AN OCTAL VALUE.
241      *             Format: (User)(Group)(Other) where each
242      * component is a sum of Read = 4,
243      *             Write = 2, and Execute = 1.  For example, the
244      * value 0644
245      *             translates to User read-write, Group and Other
246      * read-only. The default value is 0644.
247      *             <a
248      * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
249      * on unix-style permissions)</a>
250      * 
251      * @return String
252      */
253     public String getFileMode()
254     {
255         return this.fileMode;
256     } //-- String getFileMode()
257 
258     /**
259      * Method getFileSets.
260      * 
261      * @return List
262      */
263     public java.util.List<FileSet> getFileSets()
264     {
265         if ( this.fileSets == null )
266         {
267             this.fileSets = new java.util.ArrayList<FileSet>();
268         }
269 
270         return this.fileSets;
271     } //-- java.util.List<FileSet> getFileSets()
272 
273     /**
274      * Method getIncludes.
275      * 
276      * @return List
277      */
278     public java.util.List<String> getIncludes()
279     {
280         if ( this.includes == null )
281         {
282             this.includes = new java.util.ArrayList<String>();
283         }
284 
285         return this.includes;
286     } //-- java.util.List<String> getIncludes()
287 
288     /**
289      * Get sets the output directory relative to the root
290      *             of the root directory of the assembly. For
291      * example,
292      *             "log" will put the specified files in the log
293      * directory.
294      * 
295      * @return String
296      */
297     public String getOutputDirectory()
298     {
299         return this.outputDirectory;
300     } //-- String getOutputDirectory()
301 
302     /**
303      * Get sets the mapping pattern for all module base-directories
304      * included in this assembly.
305      *             NOTE: This field is only used if
306      * includeModuleDirectory == true.
307      *             Default is the module's ${artifactId} in
308      * 2.2-beta-1, and ${module.artifactId} in subsequent versions.
309      * (Since 2.2).
310      * 
311      * @return String
312      */
313     public String getOutputDirectoryMapping()
314     {
315         return this.outputDirectoryMapping;
316     } //-- String getOutputDirectoryMapping()
317 
318     /**
319      * Get specifies whether sub-module directories below the
320      * current module should be excluded
321      *             from fileSets applied to that module. This might
322      * be useful if you only mean to copy
323      *             the sources for the exact module list matched by
324      * this ModuleSet, ignoring (or processing
325      *             separately) the modules which exist in
326      * directories below the current one.
327      *             Default value is true. (Since 2.2).
328      * 
329      * @return boolean
330      */
331     public boolean isExcludeSubModuleDirectories()
332     {
333         return this.excludeSubModuleDirectories;
334     } //-- boolean isExcludeSubModuleDirectories()
335 
336     /**
337      * Get specifies whether the module's finalName should be
338      * prepended to the outputDirectory
339      *             values of any fileSets applied to it. Default
340      * value is true. (Since 2.2).
341      * 
342      * @return boolean
343      */
344     public boolean isIncludeModuleDirectory()
345     {
346         return this.includeModuleDirectory;
347     } //-- boolean isIncludeModuleDirectory()
348 
349     /**
350      * Get whether standard exclusion patterns, such as those
351      * matching CVS and Subversion
352      *             metadata files, should be used when calculating
353      * the files affected by this set.
354      *             For backward compatibility, the default value is
355      * true. (Since 2.2).
356      * 
357      * @return boolean
358      */
359     public boolean isUseDefaultExcludes()
360     {
361         return this.useDefaultExcludes;
362     } //-- boolean isUseDefaultExcludes()
363 
364     /**
365      * Method removeExclude.
366      * 
367      * @param string a string object.
368      */
369     public void removeExclude( String string )
370     {
371         getExcludes().remove( string );
372     } //-- void removeExclude( String )
373 
374     /**
375      * Method removeFileSet.
376      * 
377      * @param fileSet a fileSet object.
378      */
379     public void removeFileSet( FileSet fileSet )
380     {
381         getFileSets().remove( fileSet );
382     } //-- void removeFileSet( FileSet )
383 
384     /**
385      * Method removeInclude.
386      * 
387      * @param string a string object.
388      */
389     public void removeInclude( String string )
390     {
391         getIncludes().remove( string );
392     } //-- void removeInclude( String )
393 
394     /**
395      * Set similar to a UNIX permission, sets the directory mode of
396      * the directories
397      *             included.
398      *             THIS IS AN OCTAL VALUE.
399      *             Format: (User)(Group)(Other) where each
400      * component is a sum of
401      *             Read = 4, Write = 2, and Execute = 1.  For
402      * example, the value
403      *             0755 translates to User read-write, Group and
404      * Other read-only. The default value is 0755.
405      *             <a
406      * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
407      * on unix-style permissions)</a>
408      * 
409      * @param directoryMode a directoryMode object.
410      */
411     public void setDirectoryMode( String directoryMode )
412     {
413         this.directoryMode = directoryMode;
414     } //-- void setDirectoryMode( String )
415 
416     /**
417      * Set specifies whether sub-module directories below the
418      * current module should be excluded
419      *             from fileSets applied to that module. This might
420      * be useful if you only mean to copy
421      *             the sources for the exact module list matched by
422      * this ModuleSet, ignoring (or processing
423      *             separately) the modules which exist in
424      * directories below the current one.
425      *             Default value is true. (Since 2.2).
426      * 
427      * @param excludeSubModuleDirectories a
428      * excludeSubModuleDirectories object.
429      */
430     public void setExcludeSubModuleDirectories( boolean excludeSubModuleDirectories )
431     {
432         this.excludeSubModuleDirectories = excludeSubModuleDirectories;
433     } //-- void setExcludeSubModuleDirectories( boolean )
434 
435     /**
436      * Set when &lt;exclude&gt; subelements are present, they
437      * define a set of
438      *             files and directory to exclude. If none is
439      * present, then
440      *             &lt;excludes&gt; represents no exclusions.
441      * 
442      * @param excludes a excludes object.
443      */
444     public void setExcludes( java.util.List<String> excludes )
445     {
446         this.excludes = excludes;
447     } //-- void setExcludes( java.util.List )
448 
449     /**
450      * Set similar to a UNIX permission, sets the file mode of the
451      * files included.
452      *             THIS IS AN OCTAL VALUE.
453      *             Format: (User)(Group)(Other) where each
454      * component is a sum of Read = 4,
455      *             Write = 2, and Execute = 1.  For example, the
456      * value 0644
457      *             translates to User read-write, Group and Other
458      * read-only. The default value is 0644.
459      *             <a
460      * href="http://www.onlamp.com/pub/a/bsd/2000/09/06/FreeBSD_Basics.html">(more
461      * on unix-style permissions)</a>
462      * 
463      * @param fileMode a fileMode object.
464      */
465     public void setFileMode( String fileMode )
466     {
467         this.fileMode = fileMode;
468     } //-- void setFileMode( String )
469 
470     /**
471      * Set specifies which groups of files from each included
472      * module to include in the assembly. A
473      *             fileSet is specified by providing one or more of
474      * &lt;fileSet&gt; subelements. (Since 2.2).
475      * 
476      * @param fileSets a fileSets object.
477      */
478     public void setFileSets( java.util.List<FileSet> fileSets )
479     {
480         this.fileSets = fileSets;
481     } //-- void setFileSets( java.util.List )
482 
483     /**
484      * Set specifies whether the module's finalName should be
485      * prepended to the outputDirectory
486      *             values of any fileSets applied to it. Default
487      * value is true. (Since 2.2).
488      * 
489      * @param includeModuleDirectory a includeModuleDirectory object
490      */
491     public void setIncludeModuleDirectory( boolean includeModuleDirectory )
492     {
493         this.includeModuleDirectory = includeModuleDirectory;
494     } //-- void setIncludeModuleDirectory( boolean )
495 
496     /**
497      * Set when &lt;include&gt; subelements are present, they
498      * define a set of
499      *             files and directory to include. If none is
500      * present, then
501      *             &lt;includes&gt; represents all valid values.
502      * 
503      * @param includes a includes object.
504      */
505     public void setIncludes( java.util.List<String> includes )
506     {
507         this.includes = includes;
508     } //-- void setIncludes( java.util.List )
509 
510     /**
511      * Set sets the output directory relative to the root
512      *             of the root directory of the assembly. For
513      * example,
514      *             "log" will put the specified files in the log
515      * directory.
516      * 
517      * @param outputDirectory a outputDirectory object.
518      */
519     public void setOutputDirectory( String outputDirectory )
520     {
521         this.outputDirectory = outputDirectory;
522     } //-- void setOutputDirectory( String )
523 
524     /**
525      * Set sets the mapping pattern for all module base-directories
526      * included in this assembly.
527      *             NOTE: This field is only used if
528      * includeModuleDirectory == true.
529      *             Default is the module's ${artifactId} in
530      * 2.2-beta-1, and ${module.artifactId} in subsequent versions.
531      * (Since 2.2).
532      * 
533      * @param outputDirectoryMapping a outputDirectoryMapping object
534      */
535     public void setOutputDirectoryMapping( String outputDirectoryMapping )
536     {
537         this.outputDirectoryMapping = outputDirectoryMapping;
538     } //-- void setOutputDirectoryMapping( String )
539 
540     /**
541      * Set whether standard exclusion patterns, such as those
542      * matching CVS and Subversion
543      *             metadata files, should be used when calculating
544      * the files affected by this set.
545      *             For backward compatibility, the default value is
546      * true. (Since 2.2).
547      * 
548      * @param useDefaultExcludes a useDefaultExcludes object.
549      */
550     public void setUseDefaultExcludes( boolean useDefaultExcludes )
551     {
552         this.useDefaultExcludes = useDefaultExcludes;
553     } //-- void setUseDefaultExcludes( boolean )
554 
555 }