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.tools.plugin.extractor.model;
25  
26  /**
27   * Mojo descriptor definition.
28   * 
29   * @version $Revision$ $Date$
30   */
31  @SuppressWarnings( "all" )
32  public class Mojo
33      implements java.io.Serializable
34  {
35  
36        //--------------------------/
37       //- Class/Member Variables -/
38      //--------------------------/
39  
40      /**
41       * The name of the goal used to invoke this mojo.
42       */
43      private String goal;
44  
45      /**
46       * The phase to which this mojo should be bound by default.
47       */
48      private String phase;
49  
50      /**
51       * Whether this mojo operates as an aggregator when the reactor
52       * is run. That is, only runs once.
53       *           
54       */
55      private boolean aggregator = false;
56  
57      /**
58       * The scope of dependencies that this mojo requires to have
59       * resolved.
60       */
61      private String requiresDependencyResolution;
62  
63      /**
64       * Whether this mojo requires a project instance in order to
65       * execute.
66       */
67      private boolean requiresProject = false;
68  
69      /**
70       * Whether this mojo requires a reports section in the POM.
71       */
72      private boolean requiresReports = false;
73  
74      /**
75       * Whether this mojo requires online mode to operate normally.
76       */
77      private boolean requiresOnline = false;
78  
79      /**
80       * Whether this mojo's configuration should propagate down the
81       * POM inheritance chain by default.
82       *           
83       */
84      private boolean inheritByDefault = false;
85  
86      /**
87       * If true, this mojo can only be directly invoked (eg.
88       * specified directly on the command line).
89       *           
90       */
91      private boolean requiresDirectInvocation = false;
92  
93      /**
94       * Information about a sub-execution of the Maven lifecycle
95       * which should be processed.
96       */
97      private LifecycleExecution execution;
98  
99      /**
100      * Field components.
101      */
102     private java.util.List<Component> components;
103 
104     /**
105      * Field parameters.
106      */
107     private java.util.List<Parameter> parameters;
108 
109     /**
110      * The description for this parameter.
111      */
112     private String description;
113 
114     /**
115      * A deprecation message for this mojo parameter.
116      */
117     private String deprecation;
118 
119     /**
120      * Version when the mojo was added to the API.
121      */
122     private String since;
123 
124     /**
125      * The target/method within the script to call when this mojo
126      * executes.
127      */
128     private String call;
129 
130 
131       //-----------/
132      //- Methods -/
133     //-----------/
134 
135     /**
136      * Method addComponent.
137      * 
138      * @param component a component object.
139      */
140     public void addComponent( Component component )
141     {
142         getComponents().add( component );
143     } //-- void addComponent( Component )
144 
145     /**
146      * Method addParameter.
147      * 
148      * @param parameter a parameter object.
149      */
150     public void addParameter( Parameter parameter )
151     {
152         getParameters().add( parameter );
153     } //-- void addParameter( Parameter )
154 
155     /**
156      * Get the target/method within the script to call when this
157      * mojo executes.
158      * 
159      * @return String
160      */
161     public String getCall()
162     {
163         return this.call;
164     } //-- String getCall()
165 
166     /**
167      * Method getComponents.
168      * 
169      * @return List
170      */
171     public java.util.List<Component> getComponents()
172     {
173         if ( this.components == null )
174         {
175             this.components = new java.util.ArrayList<Component>();
176         }
177 
178         return this.components;
179     } //-- java.util.List<Component> getComponents()
180 
181     /**
182      * Get a deprecation message for this mojo parameter.
183      * 
184      * @return String
185      */
186     public String getDeprecation()
187     {
188         return this.deprecation;
189     } //-- String getDeprecation()
190 
191     /**
192      * Get the description for this parameter.
193      * 
194      * @return String
195      */
196     public String getDescription()
197     {
198         return this.description;
199     } //-- String getDescription()
200 
201     /**
202      * Get information about a sub-execution of the Maven lifecycle
203      * which should be processed.
204      * 
205      * @return LifecycleExecution
206      */
207     public LifecycleExecution getExecution()
208     {
209         return this.execution;
210     } //-- LifecycleExecution getExecution()
211 
212     /**
213      * Get the name of the goal used to invoke this mojo.
214      * 
215      * @return String
216      */
217     public String getGoal()
218     {
219         return this.goal;
220     } //-- String getGoal()
221 
222     /**
223      * Method getParameters.
224      * 
225      * @return List
226      */
227     public java.util.List<Parameter> getParameters()
228     {
229         if ( this.parameters == null )
230         {
231             this.parameters = new java.util.ArrayList<Parameter>();
232         }
233 
234         return this.parameters;
235     } //-- java.util.List<Parameter> getParameters()
236 
237     /**
238      * Get the phase to which this mojo should be bound by default.
239      * 
240      * @return String
241      */
242     public String getPhase()
243     {
244         return this.phase;
245     } //-- String getPhase()
246 
247     /**
248      * Get the scope of dependencies that this mojo requires to
249      * have resolved.
250      * 
251      * @return String
252      */
253     public String getRequiresDependencyResolution()
254     {
255         return this.requiresDependencyResolution;
256     } //-- String getRequiresDependencyResolution()
257 
258     /**
259      * Get version when the mojo was added to the API.
260      * 
261      * @return String
262      */
263     public String getSince()
264     {
265         return this.since;
266     } //-- String getSince()
267 
268     /**
269      * Get whether this mojo operates as an aggregator when the
270      * reactor is run. That is, only runs once.
271      * 
272      * @return boolean
273      */
274     public boolean isAggregator()
275     {
276         return this.aggregator;
277     } //-- boolean isAggregator()
278 
279     /**
280      * Get whether this mojo's configuration should propagate down
281      * the POM inheritance chain by default.
282      * 
283      * @return boolean
284      */
285     public boolean isInheritByDefault()
286     {
287         return this.inheritByDefault;
288     } //-- boolean isInheritByDefault()
289 
290     /**
291      * Get if true, this mojo can only be directly invoked (eg.
292      * specified directly on the command line).
293      * 
294      * @return boolean
295      */
296     public boolean isRequiresDirectInvocation()
297     {
298         return this.requiresDirectInvocation;
299     } //-- boolean isRequiresDirectInvocation()
300 
301     /**
302      * Get whether this mojo requires online mode to operate
303      * normally.
304      * 
305      * @return boolean
306      */
307     public boolean isRequiresOnline()
308     {
309         return this.requiresOnline;
310     } //-- boolean isRequiresOnline()
311 
312     /**
313      * Get whether this mojo requires a project instance in order
314      * to execute.
315      * 
316      * @return boolean
317      */
318     public boolean isRequiresProject()
319     {
320         return this.requiresProject;
321     } //-- boolean isRequiresProject()
322 
323     /**
324      * Get whether this mojo requires a reports section in the POM.
325      * 
326      * @return boolean
327      */
328     public boolean isRequiresReports()
329     {
330         return this.requiresReports;
331     } //-- boolean isRequiresReports()
332 
333     /**
334      * Method removeComponent.
335      * 
336      * @param component a component object.
337      */
338     public void removeComponent( Component component )
339     {
340         getComponents().remove( component );
341     } //-- void removeComponent( Component )
342 
343     /**
344      * Method removeParameter.
345      * 
346      * @param parameter a parameter object.
347      */
348     public void removeParameter( Parameter parameter )
349     {
350         getParameters().remove( parameter );
351     } //-- void removeParameter( Parameter )
352 
353     /**
354      * Set whether this mojo operates as an aggregator when the
355      * reactor is run. That is, only runs once.
356      * 
357      * @param aggregator a aggregator object.
358      */
359     public void setAggregator( boolean aggregator )
360     {
361         this.aggregator = aggregator;
362     } //-- void setAggregator( boolean )
363 
364     /**
365      * Set the target/method within the script to call when this
366      * mojo executes.
367      * 
368      * @param call a call object.
369      */
370     public void setCall( String call )
371     {
372         this.call = call;
373     } //-- void setCall( String )
374 
375     /**
376      * Set list of plexus components required by this mojo.
377      * 
378      * @param components a components object.
379      */
380     public void setComponents( java.util.List<Component> components )
381     {
382         this.components = components;
383     } //-- void setComponents( java.util.List )
384 
385     /**
386      * Set a deprecation message for this mojo parameter.
387      * 
388      * @param deprecation a deprecation object.
389      */
390     public void setDeprecation( String deprecation )
391     {
392         this.deprecation = deprecation;
393     } //-- void setDeprecation( String )
394 
395     /**
396      * Set the description for this parameter.
397      * 
398      * @param description a description object.
399      */
400     public void setDescription( String description )
401     {
402         this.description = description;
403     } //-- void setDescription( String )
404 
405     /**
406      * Set information about a sub-execution of the Maven lifecycle
407      * which should be processed.
408      * 
409      * @param execution a execution object.
410      */
411     public void setExecution( LifecycleExecution execution )
412     {
413         this.execution = execution;
414     } //-- void setExecution( LifecycleExecution )
415 
416     /**
417      * Set the name of the goal used to invoke this mojo.
418      * 
419      * @param goal a goal object.
420      */
421     public void setGoal( String goal )
422     {
423         this.goal = goal;
424     } //-- void setGoal( String )
425 
426     /**
427      * Set whether this mojo's configuration should propagate down
428      * the POM inheritance chain by default.
429      * 
430      * @param inheritByDefault a inheritByDefault object.
431      */
432     public void setInheritByDefault( boolean inheritByDefault )
433     {
434         this.inheritByDefault = inheritByDefault;
435     } //-- void setInheritByDefault( boolean )
436 
437     /**
438      * Set list of parameters used by this mojo.
439      * 
440      * @param parameters a parameters object.
441      */
442     public void setParameters( java.util.List<Parameter> parameters )
443     {
444         this.parameters = parameters;
445     } //-- void setParameters( java.util.List )
446 
447     /**
448      * Set the phase to which this mojo should be bound by default.
449      * 
450      * @param phase a phase object.
451      */
452     public void setPhase( String phase )
453     {
454         this.phase = phase;
455     } //-- void setPhase( String )
456 
457     /**
458      * Set the scope of dependencies that this mojo requires to
459      * have resolved.
460      * 
461      * @param requiresDependencyResolution a
462      * requiresDependencyResolution object.
463      */
464     public void setRequiresDependencyResolution( String requiresDependencyResolution )
465     {
466         this.requiresDependencyResolution = requiresDependencyResolution;
467     } //-- void setRequiresDependencyResolution( String )
468 
469     /**
470      * Set if true, this mojo can only be directly invoked (eg.
471      * specified directly on the command line).
472      * 
473      * @param requiresDirectInvocation a requiresDirectInvocation
474      * object.
475      */
476     public void setRequiresDirectInvocation( boolean requiresDirectInvocation )
477     {
478         this.requiresDirectInvocation = requiresDirectInvocation;
479     } //-- void setRequiresDirectInvocation( boolean )
480 
481     /**
482      * Set whether this mojo requires online mode to operate
483      * normally.
484      * 
485      * @param requiresOnline a requiresOnline object.
486      */
487     public void setRequiresOnline( boolean requiresOnline )
488     {
489         this.requiresOnline = requiresOnline;
490     } //-- void setRequiresOnline( boolean )
491 
492     /**
493      * Set whether this mojo requires a project instance in order
494      * to execute.
495      * 
496      * @param requiresProject a requiresProject object.
497      */
498     public void setRequiresProject( boolean requiresProject )
499     {
500         this.requiresProject = requiresProject;
501     } //-- void setRequiresProject( boolean )
502 
503     /**
504      * Set whether this mojo requires a reports section in the POM.
505      * 
506      * @param requiresReports a requiresReports object.
507      */
508     public void setRequiresReports( boolean requiresReports )
509     {
510         this.requiresReports = requiresReports;
511     } //-- void setRequiresReports( boolean )
512 
513     /**
514      * Set version when the mojo was added to the API.
515      * 
516      * @param since a since object.
517      */
518     public void setSince( String since )
519     {
520         this.since = since;
521     } //-- void setSince( String )
522 
523 }