View Javadoc
1   // =================== DO NOT EDIT THIS FILE ====================
2   // Generated by Modello 2.0.0,
3   // any modifications will be overwritten.
4   // ==============================================================
5   
6   package org.apache.maven.plugins.assembly.model;
7   
8   /**
9    * 
10   *         
11   *         An assembly defines a collection of files usually
12   * distributed in an
13   *         archive format such as zip, tar, or tar.gz that is
14   * generated from a
15   *         project.  For example, a project could produce a ZIP
16   * assembly which
17   *         contains a project's JAR artifact in the root directory,
18   * the
19   *         runtime dependencies in a lib/ directory, and a shell
20   * script to launch
21   *         a stand-alone application.
22   *         
23   *       
24   * 
25   * @version $Revision$ $Date$
26   */
27  @SuppressWarnings( "all" )
28  public class Assembly
29      implements java.io.Serializable
30  {
31  
32        //--------------------------/
33       //- Class/Member Variables -/
34      //--------------------------/
35  
36      /**
37       * 
38       *             Sets the id of this assembly. This is a symbolic
39       * name for a
40       *             particular assembly of files from this project.
41       * Also, aside from
42       *             being used to distinctly name the assembled
43       * package by attaching
44       *             its value to the generated archive, the id is
45       * used as your
46       *             artifact's classifier when deploying.
47       *           
48       */
49      private String id;
50  
51      /**
52       * Field formats.
53       */
54      private java.util.List<String> formats;
55  
56      /**
57       * 
58       *             Includes a base directory in the final archive.
59       * For example,
60       *             if you are creating an assembly named
61       * "your-app", setting
62       *             includeBaseDirectory to true will create an
63       * archive that
64       *             includes this base directory. If this option is
65       * set to false
66       *             the archive created will unzip its content to
67       * the current
68       *             directory.
69       *           
70       */
71      private boolean includeBaseDirectory = true;
72  
73      /**
74       * 
75       *             Sets the base directory of the resulting
76       * assembly archive. If this is not
77       *             set and includeBaseDirectory == true,
78       * ${project.build.finalName} will be used instead.
79       *             (Since 2.2-beta-1)
80       *           .
81       */
82      private String baseDirectory;
83  
84      /**
85       * 
86       *             Includes a site directory in the final archive.
87       * The site directory
88       *             location of a project is determined by the
89       * siteDirectory parameter
90       *             of the Assembly Plugin.
91       *           
92       */
93      private boolean includeSiteDirectory = false;
94  
95      /**
96       * Field containerDescriptorHandlers.
97       */
98      private java.util.List<ContainerDescriptorHandlerConfig> containerDescriptorHandlers;
99  
100     /**
101      * Field moduleSets.
102      */
103     private java.util.List<ModuleSet> moduleSets;
104 
105     /**
106      * Field fileSets.
107      */
108     private java.util.List<FileSet> fileSets;
109 
110     /**
111      * Field files.
112      */
113     private java.util.List<FileItem> files;
114 
115     /**
116      * Field dependencySets.
117      */
118     private java.util.List<DependencySet> dependencySets;
119 
120     /**
121      * Field repositories.
122      */
123     private java.util.List<Repository> repositories;
124 
125     /**
126      * Field componentDescriptors.
127      */
128     private java.util.List<String> componentDescriptors;
129 
130     /**
131      * Field modelEncoding.
132      */
133     private String modelEncoding = "UTF-8";
134 
135 
136       //-----------/
137      //- Methods -/
138     //-----------/
139 
140     /**
141      * Method addComponentDescriptor.
142      * 
143      * @param string a string object.
144      */
145     public void addComponentDescriptor( String string )
146     {
147         getComponentDescriptors().add( string );
148     } //-- void addComponentDescriptor( String )
149 
150     /**
151      * Method addContainerDescriptorHandler.
152      * 
153      * @param containerDescriptorHandlerConfig a
154      * containerDescriptorHandlerConfig object.
155      */
156     public void addContainerDescriptorHandler( ContainerDescriptorHandlerConfig containerDescriptorHandlerConfig )
157     {
158         getContainerDescriptorHandlers().add( containerDescriptorHandlerConfig );
159     } //-- void addContainerDescriptorHandler( ContainerDescriptorHandlerConfig )
160 
161     /**
162      * Method addDependencySet.
163      * 
164      * @param dependencySet a dependencySet object.
165      */
166     public void addDependencySet( DependencySet dependencySet )
167     {
168         getDependencySets().add( dependencySet );
169     } //-- void addDependencySet( DependencySet )
170 
171     /**
172      * Method addFile.
173      * 
174      * @param fileItem a fileItem object.
175      */
176     public void addFile( FileItem fileItem )
177     {
178         getFiles().add( fileItem );
179     } //-- void addFile( FileItem )
180 
181     /**
182      * Method addFileSet.
183      * 
184      * @param fileSet a fileSet object.
185      */
186     public void addFileSet( FileSet fileSet )
187     {
188         getFileSets().add( fileSet );
189     } //-- void addFileSet( FileSet )
190 
191     /**
192      * Method addFormat.
193      * 
194      * @param string a string object.
195      */
196     public void addFormat( String string )
197     {
198         getFormats().add( string );
199     } //-- void addFormat( String )
200 
201     /**
202      * Method addModuleSet.
203      * 
204      * @param moduleSet a moduleSet object.
205      */
206     public void addModuleSet( ModuleSet moduleSet )
207     {
208         getModuleSets().add( moduleSet );
209     } //-- void addModuleSet( ModuleSet )
210 
211     /**
212      * Method addRepository.
213      * 
214      * @param repository a repository object.
215      */
216     public void addRepository( Repository repository )
217     {
218         getRepositories().add( repository );
219     } //-- void addRepository( Repository )
220 
221     /**
222      * Get sets the base directory of the resulting assembly
223      * archive. If this is not
224      *             set and includeBaseDirectory == true,
225      * ${project.build.finalName} will be used instead.
226      *             (Since 2.2-beta-1).
227      * 
228      * @return String
229      */
230     public String getBaseDirectory()
231     {
232         return this.baseDirectory;
233     } //-- String getBaseDirectory()
234 
235     /**
236      * Method getComponentDescriptors.
237      * 
238      * @return List
239      */
240     public java.util.List<String> getComponentDescriptors()
241     {
242         if ( this.componentDescriptors == null )
243         {
244             this.componentDescriptors = new java.util.ArrayList<String>();
245         }
246 
247         return this.componentDescriptors;
248     } //-- java.util.List<String> getComponentDescriptors()
249 
250     /**
251      * Method getContainerDescriptorHandlers.
252      * 
253      * @return List
254      */
255     public java.util.List<ContainerDescriptorHandlerConfig> getContainerDescriptorHandlers()
256     {
257         if ( this.containerDescriptorHandlers == null )
258         {
259             this.containerDescriptorHandlers = new java.util.ArrayList<ContainerDescriptorHandlerConfig>();
260         }
261 
262         return this.containerDescriptorHandlers;
263     } //-- java.util.List<ContainerDescriptorHandlerConfig> getContainerDescriptorHandlers()
264 
265     /**
266      * Method getDependencySets.
267      * 
268      * @return List
269      */
270     public java.util.List<DependencySet> getDependencySets()
271     {
272         if ( this.dependencySets == null )
273         {
274             this.dependencySets = new java.util.ArrayList<DependencySet>();
275         }
276 
277         return this.dependencySets;
278     } //-- java.util.List<DependencySet> getDependencySets()
279 
280     /**
281      * Method getFileSets.
282      * 
283      * @return List
284      */
285     public java.util.List<FileSet> getFileSets()
286     {
287         if ( this.fileSets == null )
288         {
289             this.fileSets = new java.util.ArrayList<FileSet>();
290         }
291 
292         return this.fileSets;
293     } //-- java.util.List<FileSet> getFileSets()
294 
295     /**
296      * Method getFiles.
297      * 
298      * @return List
299      */
300     public java.util.List<FileItem> getFiles()
301     {
302         if ( this.files == null )
303         {
304             this.files = new java.util.ArrayList<FileItem>();
305         }
306 
307         return this.files;
308     } //-- java.util.List<FileItem> getFiles()
309 
310     /**
311      * Method getFormats.
312      * 
313      * @return List
314      */
315     public java.util.List<String> getFormats()
316     {
317         if ( this.formats == null )
318         {
319             this.formats = new java.util.ArrayList<String>();
320         }
321 
322         return this.formats;
323     } //-- java.util.List<String> getFormats()
324 
325     /**
326      * Get sets the id of this assembly. This is a symbolic name
327      * for a
328      *             particular assembly of files from this project.
329      * Also, aside from
330      *             being used to distinctly name the assembled
331      * package by attaching
332      *             its value to the generated archive, the id is
333      * used as your
334      *             artifact's classifier when deploying.
335      * 
336      * @return String
337      */
338     public String getId()
339     {
340         return this.id;
341     } //-- String getId()
342 
343     /**
344      * Get the modelEncoding field.
345      * 
346      * @return String
347      */
348     public String getModelEncoding()
349     {
350         return this.modelEncoding;
351     } //-- String getModelEncoding()
352 
353     /**
354      * Method getModuleSets.
355      * 
356      * @return List
357      */
358     public java.util.List<ModuleSet> getModuleSets()
359     {
360         if ( this.moduleSets == null )
361         {
362             this.moduleSets = new java.util.ArrayList<ModuleSet>();
363         }
364 
365         return this.moduleSets;
366     } //-- java.util.List<ModuleSet> getModuleSets()
367 
368     /**
369      * Method getRepositories.
370      * 
371      * @return List
372      */
373     public java.util.List<Repository> getRepositories()
374     {
375         if ( this.repositories == null )
376         {
377             this.repositories = new java.util.ArrayList<Repository>();
378         }
379 
380         return this.repositories;
381     } //-- java.util.List<Repository> getRepositories()
382 
383     /**
384      * Get includes a base directory in the final archive. For
385      * example,
386      *             if you are creating an assembly named
387      * "your-app", setting
388      *             includeBaseDirectory to true will create an
389      * archive that
390      *             includes this base directory. If this option is
391      * set to false
392      *             the archive created will unzip its content to
393      * the current
394      *             directory.
395      * 
396      * @return boolean
397      */
398     public boolean isIncludeBaseDirectory()
399     {
400         return this.includeBaseDirectory;
401     } //-- boolean isIncludeBaseDirectory()
402 
403     /**
404      * Get includes a site directory in the final archive. The site
405      * directory
406      *             location of a project is determined by the
407      * siteDirectory parameter
408      *             of the Assembly Plugin.
409      * 
410      * @return boolean
411      */
412     public boolean isIncludeSiteDirectory()
413     {
414         return this.includeSiteDirectory;
415     } //-- boolean isIncludeSiteDirectory()
416 
417     /**
418      * Method removeComponentDescriptor.
419      * 
420      * @param string a string object.
421      */
422     public void removeComponentDescriptor( String string )
423     {
424         getComponentDescriptors().remove( string );
425     } //-- void removeComponentDescriptor( String )
426 
427     /**
428      * Method removeContainerDescriptorHandler.
429      * 
430      * @param containerDescriptorHandlerConfig a
431      * containerDescriptorHandlerConfig object.
432      */
433     public void removeContainerDescriptorHandler( ContainerDescriptorHandlerConfig containerDescriptorHandlerConfig )
434     {
435         getContainerDescriptorHandlers().remove( containerDescriptorHandlerConfig );
436     } //-- void removeContainerDescriptorHandler( ContainerDescriptorHandlerConfig )
437 
438     /**
439      * Method removeDependencySet.
440      * 
441      * @param dependencySet a dependencySet object.
442      */
443     public void removeDependencySet( DependencySet dependencySet )
444     {
445         getDependencySets().remove( dependencySet );
446     } //-- void removeDependencySet( DependencySet )
447 
448     /**
449      * Method removeFile.
450      * 
451      * @param fileItem a fileItem object.
452      */
453     public void removeFile( FileItem fileItem )
454     {
455         getFiles().remove( fileItem );
456     } //-- void removeFile( FileItem )
457 
458     /**
459      * Method removeFileSet.
460      * 
461      * @param fileSet a fileSet object.
462      */
463     public void removeFileSet( FileSet fileSet )
464     {
465         getFileSets().remove( fileSet );
466     } //-- void removeFileSet( FileSet )
467 
468     /**
469      * Method removeFormat.
470      * 
471      * @param string a string object.
472      */
473     public void removeFormat( String string )
474     {
475         getFormats().remove( string );
476     } //-- void removeFormat( String )
477 
478     /**
479      * Method removeModuleSet.
480      * 
481      * @param moduleSet a moduleSet object.
482      */
483     public void removeModuleSet( ModuleSet moduleSet )
484     {
485         getModuleSets().remove( moduleSet );
486     } //-- void removeModuleSet( ModuleSet )
487 
488     /**
489      * Method removeRepository.
490      * 
491      * @param repository a repository object.
492      */
493     public void removeRepository( Repository repository )
494     {
495         getRepositories().remove( repository );
496     } //-- void removeRepository( Repository )
497 
498     /**
499      * Set sets the base directory of the resulting assembly
500      * archive. If this is not
501      *             set and includeBaseDirectory == true,
502      * ${project.build.finalName} will be used instead.
503      *             (Since 2.2-beta-1).
504      * 
505      * @param baseDirectory a baseDirectory object.
506      */
507     public void setBaseDirectory( String baseDirectory )
508     {
509         this.baseDirectory = baseDirectory;
510     } //-- void setBaseDirectory( String )
511 
512     /**
513      * Set specifies the shared components xml file locations to
514      * include in the
515      *             assembly. The locations specified must be
516      * relative to the base location
517      *             of the descriptor. If the descriptor was found
518      * via a &lt;descriptorRef/&gt;
519      *             element in the
520      *             classpath, any components it specifies will also
521      * be found on the classpath.
522      *             If it is found by pathname via a
523      * &lt;descriptor/&gt; element
524      *             the value here will be interpreted
525      *             as a path relative to the project basedir.
526      *             When multiple componentDescriptors are found,
527      * their
528      *             contents are merged. Check out the <a
529      * href="assembly-component.html">
530      *             descriptor components</a> for more information.
531      * A
532      *             componentDescriptor is specified by providing
533      * one or more of
534      *             &lt;componentDescriptor&gt; subelements.
535      * 
536      * @param componentDescriptors a componentDescriptors object.
537      */
538     public void setComponentDescriptors( java.util.List<String> componentDescriptors )
539     {
540         this.componentDescriptors = componentDescriptors;
541     } //-- void setComponentDescriptors( java.util.List )
542 
543     /**
544      * Set set of components which filter various container
545      * descriptors out of
546      *             the normal archive stream, so they can be
547      * aggregated then added.
548      * 
549      * @param containerDescriptorHandlers a
550      * containerDescriptorHandlers object.
551      */
552     public void setContainerDescriptorHandlers( java.util.List<ContainerDescriptorHandlerConfig> containerDescriptorHandlers )
553     {
554         this.containerDescriptorHandlers = containerDescriptorHandlers;
555     } //-- void setContainerDescriptorHandlers( java.util.List )
556 
557     /**
558      * Set specifies which dependencies to include in the assembly.
559      * A
560      *             dependencySet is specified by providing one or
561      * more of
562      *             &lt;dependencySet&gt; subelements.
563      * 
564      * @param dependencySets a dependencySets object.
565      */
566     public void setDependencySets( java.util.List<DependencySet> dependencySets )
567     {
568         this.dependencySets = dependencySets;
569     } //-- void setDependencySets( java.util.List )
570 
571     /**
572      * Set specifies which groups of files to include in the
573      * assembly. A
574      *             fileSet is specified by providing one or more of
575      * &lt;fileSet&gt;
576      *             subelements.
577      * 
578      * @param fileSets a fileSets object.
579      */
580     public void setFileSets( java.util.List<FileSet> fileSets )
581     {
582         this.fileSets = fileSets;
583     } //-- void setFileSets( java.util.List )
584 
585     /**
586      * Set specifies which single files to include in the assembly.
587      * A file
588      *             is specified by providing one or more of
589      * &lt;file&gt;
590      *             subelements.
591      * 
592      * @param files a files object.
593      */
594     public void setFiles( java.util.List<FileItem> files )
595     {
596         this.files = files;
597     } //-- void setFiles( java.util.List )
598 
599     /**
600      * Set specifies the formats of the assembly.
601      * 
602      *             It is often better to specify the formats via
603      * the goal parameter rather
604      *             than here. For example, that allows different
605      * profiles to generate
606      *             different types of archives.
607      * 
608      *             Multiple formats can be
609      *             supplied and the Assembly Plugin will generate
610      * an archive for each
611      *             of the desired formats. When deploying your
612      * project, all file formats
613      *             specified will also be deployed. A format is
614      * specified by supplying
615      *             one of the following values in a &lt;format&gt;
616      * subelement:
617      *             <ul>
618      *               <li><b>"zip"</b> - Creates a ZIP file
619      * format</li>
620      *               <li><b>"tar"</b> - Creates a TAR format</li>
621      *               <li><b>"tar.gz"</b> or <b>"tgz"</b> - Creates
622      * a gzip'd TAR format</li>
623      *               <li><b>"tar.bz2"</b> or <b>"tbz2"</b> -
624      * Creates a bzip'd TAR format</li>
625      *               <li><b>"tar.snappy"</b> - Creates a snappy'd
626      * TAR format</li>
627      *               <li><b>"tar.xz"</b> or <b>"txz"</b> - Creates
628      * a xz'd TAR format</li>
629      *               <li><b>"jar"</b> - Creates a JAR format</li>
630      *               <li><b>"dir"</b> - Creates an exploded
631      * directory format</li>
632      *               <li><b>"war"</b> - Creates a WAR format</li>
633      *             </ul>
634      * 
635      * @param formats a formats object.
636      */
637     public void setFormats( java.util.List<String> formats )
638     {
639         this.formats = formats;
640     } //-- void setFormats( java.util.List )
641 
642     /**
643      * Set sets the id of this assembly. This is a symbolic name
644      * for a
645      *             particular assembly of files from this project.
646      * Also, aside from
647      *             being used to distinctly name the assembled
648      * package by attaching
649      *             its value to the generated archive, the id is
650      * used as your
651      *             artifact's classifier when deploying.
652      * 
653      * @param id a id object.
654      */
655     public void setId( String id )
656     {
657         this.id = id;
658     } //-- void setId( String )
659 
660     /**
661      * Set includes a base directory in the final archive. For
662      * example,
663      *             if you are creating an assembly named
664      * "your-app", setting
665      *             includeBaseDirectory to true will create an
666      * archive that
667      *             includes this base directory. If this option is
668      * set to false
669      *             the archive created will unzip its content to
670      * the current
671      *             directory.
672      * 
673      * @param includeBaseDirectory a includeBaseDirectory object.
674      */
675     public void setIncludeBaseDirectory( boolean includeBaseDirectory )
676     {
677         this.includeBaseDirectory = includeBaseDirectory;
678     } //-- void setIncludeBaseDirectory( boolean )
679 
680     /**
681      * Set includes a site directory in the final archive. The site
682      * directory
683      *             location of a project is determined by the
684      * siteDirectory parameter
685      *             of the Assembly Plugin.
686      * 
687      * @param includeSiteDirectory a includeSiteDirectory object.
688      */
689     public void setIncludeSiteDirectory( boolean includeSiteDirectory )
690     {
691         this.includeSiteDirectory = includeSiteDirectory;
692     } //-- void setIncludeSiteDirectory( boolean )
693 
694     /**
695      * Set the modelEncoding field.
696      * 
697      * @param modelEncoding a modelEncoding object.
698      */
699     public void setModelEncoding( String modelEncoding )
700     {
701         this.modelEncoding = modelEncoding;
702     } //-- void setModelEncoding( String )
703 
704     /**
705      * Set specifies which module files to include in the assembly.
706      * A moduleSet
707      *             is specified by providing one or more of
708      * &lt;moduleSet&gt;
709      *             subelements.
710      * 
711      * @param moduleSets a moduleSets object.
712      */
713     public void setModuleSets( java.util.List<ModuleSet> moduleSets )
714     {
715         this.moduleSets = moduleSets;
716     } //-- void setModuleSets( java.util.List )
717 
718     /**
719      * Set <b>Deprecated since model version 2.1.1</b>.
720      *             Specifies which repository files to include in
721      * the assembly. A
722      *             repository is specified by providing one or more
723      * of
724      *             &lt;repository&gt; subelements.
725      * 
726      * @param repositories a repositories object.
727      */
728     public void setRepositories( java.util.List<Repository> repositories )
729     {
730         this.repositories = repositories;
731     } //-- void setRepositories( java.util.List )
732 
733 }