001/*
002 Licensed to the Apache Software Foundation (ASF) under one
003 or more contributor license agreements.  See the NOTICE file
004 distributed with this work for additional information
005 regarding copyright ownership.  The ASF licenses this file
006 to you under the Apache License, Version 2.0 (the
007 "License"); you may not use this file except in compliance
008 with the License.  You may obtain a copy of the License at
009 
010     http://www.apache.org/licenses/LICENSE-2.0
011 
012 Unless required by applicable law or agreed to in writing,
013 software distributed under the License is distributed on an
014 "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
015 KIND, either express or implied.  See the License for the
016 specific language governing permissions and limitations
017 under the License.
018 =================== DO NOT EDIT THIS FILE ====================
019 Generated by Modello 2.5.1,
020 any modifications will be overwritten.
021 ==============================================================
022 */
023
024package org.apache.maven.tools.plugin.extractor.model;
025
026/**
027 * Mojo descriptor definition.
028 * 
029 * @version $Revision$ $Date$
030 */
031@SuppressWarnings( "all" )
032public class Mojo
033    implements java.io.Serializable
034{
035
036      //--------------------------/
037     //- Class/Member Variables -/
038    //--------------------------/
039
040    /**
041     * The name of the goal used to invoke this mojo.
042     */
043    private String goal;
044
045    /**
046     * The phase to which this mojo should be bound by default.
047     */
048    private String phase;
049
050    /**
051     * Whether this mojo operates as an aggregator when the reactor
052     * is run. That is, only runs once.
053     *           
054     */
055    private boolean aggregator = false;
056
057    /**
058     * The scope of dependencies that this mojo requires to have
059     * resolved.
060     */
061    private String requiresDependencyResolution;
062
063    /**
064     * Whether this mojo requires a project instance in order to
065     * execute.
066     */
067    private boolean requiresProject = false;
068
069    /**
070     * Whether this mojo requires a reports section in the POM.
071     */
072    private boolean requiresReports = false;
073
074    /**
075     * Whether this mojo requires online mode to operate normally.
076     */
077    private boolean requiresOnline = false;
078
079    /**
080     * Whether this mojo's configuration should propagate down the
081     * POM inheritance chain by default.
082     *           
083     */
084    private boolean inheritByDefault = false;
085
086    /**
087     * If true, this mojo can only be directly invoked (eg.
088     * specified directly on the command line).
089     *           
090     */
091    private boolean requiresDirectInvocation = false;
092
093    /**
094     * Information about a sub-execution of the Maven lifecycle
095     * which should be processed.
096     */
097    private LifecycleExecution execution;
098
099    /**
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}