1 package org.apache.maven.shared.invoker;
2
3 /*
4 * Licensed to the Apache Software Foundation (ASF) under one
5 * or more contributor license agreements. See the NOTICE file
6 * distributed with this work for additional information
7 * regarding copyright ownership. The ASF licenses this file
8 * to you under the Apache License, Version 2.0 (the
9 * "License"); you may not use this file except in compliance
10 * with the License. You may obtain a copy of the License at
11 *
12 * http://www.apache.org/licenses/LICENSE-2.0
13 *
14 * Unless required by applicable law or agreed to in writing,
15 * software distributed under the License is distributed on an
16 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17 * KIND, either express or implied. See the License for the
18 * specific language governing permissions and limitations
19 * under the License.
20 */
21
22 import java.io.File;
23 import java.io.InputStream;
24 import java.util.List;
25 import java.util.Map;
26 import java.util.Properties;
27
28 /**
29 * Specifies the parameters used to control a Maven invocation.
30 *
31 */
32 public interface InvocationRequest
33 {
34
35 /**
36 * By default, Maven is executed in batch mode. This mean no interaction with the Maven process can be done.
37 *
38 * @return <code>true</code> if Maven should be executed in batch mode, <code>false</code> if Maven is executed in
39 * interactive mode.
40 * @since 3.0.0
41 */
42 boolean isBatchMode();
43
44 /**
45 * Gets the network mode of the Maven invocation. By default, Maven is executed in online mode.
46 *
47 * @return <code>true</code> if Maven should be executed in offline mode, <code>false</code> if the online mode is
48 * used.
49 */
50 boolean isOffline();
51
52 /**
53 * Indicates whether Maven should enforce an update check for plugins and snapshots. By default, no update check is
54 * performed.
55 *
56 * @return <code>true</code> if plugins and snapshots should be updated, <code>false</code> otherwise.
57 */
58 boolean isUpdateSnapshots();
59
60 /**
61 * Gets the recursion behavior of a reactor invocation. By default, Maven will recursive the build into sub modules.
62 *
63 * @return <code>true</code> if sub modules should be build, <code>false</code> otherwise.
64 */
65 boolean isRecursive();
66
67 /**
68 * A list of specified reactor projects to build instead of all projects. A project can be specified by
69 * [groupId]:artifactId or by its relative path.
70 *
71 * @return the list of projects to add to reactor build, otherwise {@code null}
72 * @since 2.1
73 */
74 List<String> getProjects();
75
76 /**
77 * Get the value of the {@code also-make} argument.
78 *
79 * @return {@code true} if the argument {@code also-make} was specified, otherwise {@code false}
80 * @since 2.1
81 */
82 boolean isAlsoMake();
83
84 /**
85 * Get the value of the {@code also-make-dependents}
86 *
87 * @return {@code true} if the argument {@code also-make-dependents} was specified, otherwise {@code false}
88 * @since 2.1
89 */
90 boolean isAlsoMakeDependents();
91
92 /**
93 * Get the value of {@code resume-from}
94 *
95 * @return specified reactor project to resume from
96 * @since 2.1
97 */
98 String getResumeFrom();
99
100 /**
101 * Gets the debug mode of the Maven invocation. By default, Maven is executed in normal mode.
102 *
103 * @return <code>true</code> if Maven should be executed in debug mode, <code>false</code> if the normal mode should
104 * be used.
105 */
106 boolean isDebug();
107
108 /**
109 * Gets the exception output mode of the Maven invocation. By default, Maven will not print stack traces of build
110 * exceptions.
111 *
112 * @return <code>true</code> if Maven should print stack traces, <code>false</code> otherwise.
113 */
114 boolean isShowErrors();
115
116 /**
117 * Indicates whether the environment variables of the current process should be propagated to the Maven invocation.
118 * By default, the current environment variables are inherited by the new Maven invocation.
119 *
120 * @return <code>true</code> if the environment variables should be propagated, <code>false</code> otherwise.
121 */
122 boolean isShellEnvironmentInherited();
123
124 /**
125 * Indicates whether Maven should check for plugin updates. By default, plugin updates are not suppressed.
126 *
127 * @return <code>true</code> if plugin updates should be suppressed, <code>false</code> otherwise.
128 */
129 boolean isNonPluginUpdates();
130
131 /**
132 * Gets the failure mode of the Maven invocation. By default, the mode {@link ReactorFailureBehavior#FailFast} is
133 * used.
134 *
135 * @return The failure mode, one of {@link ReactorFailureBehavior#FailFast},
136 * {@link ReactorFailureBehavior#FailAtEnd} and {@link ReactorFailureBehavior#FailNever}.
137 * @since 3.0.0
138 */
139 ReactorFailureBehavior getReactorFailureBehavior();
140
141 /**
142 * Gets the path to the base directory of the local repository to use for the Maven invocation.
143 *
144 * @param defaultDirectory The default location to use if no location is configured for this request, may be
145 * <code>null</code>.
146 * @return The path to the base directory of the local repository or <code>null</code> to use the location from the
147 * <code>settings.xml</code>.
148 */
149 File getLocalRepositoryDirectory( File defaultDirectory );
150
151 /**
152 * Gets the input stream used to provide input for the invoked Maven build. This is in particular useful when
153 * invoking Maven in interactive mode.
154 *
155 * @param defaultStream the default {@link InputStream} to use
156 * @return The input stream used to provide input for the invoked Maven build or <code>null</code> if not set.
157 */
158 InputStream getInputStream( InputStream defaultStream );
159
160 /**
161 * Gets the handler used to capture the standard output from the Maven build.
162 *
163 * @param defaultHandler the default {@link InvocationOutputHandler} to use
164 * @return The output handler or <code>null</code> if not set.
165 */
166 InvocationOutputHandler getOutputHandler( InvocationOutputHandler defaultHandler );
167
168 /**
169 * Gets the handler used to capture the error output from the Maven build.
170 *
171 * @param defaultHandler the default {@link InvocationOutputHandler} to use
172 * @return The error handler or <code>null</code> if not set.
173 */
174 InvocationOutputHandler getErrorHandler( InvocationOutputHandler defaultHandler );
175
176 /**
177 * Gets the path to the POM for the Maven invocation. If no base directory is set, the parent directory of this POM
178 * will be used as the working directory for the Maven invocation.
179 *
180 * @return The path to the POM for the Maven invocation or <code>null</code> if not set.
181 */
182 File getPomFile();
183
184 /**
185 * Gets the (unqualified) filename of the POM for the Maven invocation. This setting is ignored if
186 * {@link #getPomFile()} does not return <code>null</code>. Otherwise, the base directory is assumed to contain a
187 * POM with this name. By default, a file named <code>pom.xml</code> is used.
188 *
189 * @return The (unqualified) filename of the POM for the Maven invocation or <code>null</code> if not set.
190 */
191 String getPomFileName();
192
193 /**
194 * Gets the path to the base directory of the POM for the Maven invocation. If {@link #getPomFile()} does not return
195 * <code>null</code>, this setting only affects the working directory for the Maven invocation.
196 *
197 * @return The path to the base directory of the POM or <code>null</code> if not set.
198 */
199 File getBaseDirectory();
200
201 /**
202 * Gets the path to the base directory of the POM for the Maven invocation. If {@link #getPomFile()} does not return
203 * <code>null</code>, this setting only affects the working directory for the Maven invocation.
204 *
205 * @param defaultDirectory The default base directory to use if none is configured for this request, may be
206 * <code>null</code>.
207 * @return The path to the base directory of the POM or <code>null</code> if not set.
208 */
209 File getBaseDirectory( File defaultDirectory );
210
211 /**
212 * Gets the path to the base directory of the Java installation used to run Maven.
213 *
214 * @return The path to the base directory of the Java installation used to run Maven or <code>null</code> to use the
215 * default Java home.
216 */
217 File getJavaHome();
218
219 /**
220 * Gets the system properties for the Maven invocation.
221 *
222 * @return The system properties for the Maven invocation or <code>null</code> if not set.
223 */
224 Properties getProperties();
225
226 /**
227 * Gets the goals for the Maven invocation.
228 *
229 * @return The goals for the Maven invocation or <code>null</code> if not set.
230 */
231 List<String> getGoals();
232
233 /**
234 * Gets the path to the user settings for the Maven invocation.
235 *
236 * @return The path to the user settings for the Maven invocation or <code>null</code> to load the user settings
237 * from the default location.
238 */
239 File getUserSettingsFile();
240
241 /**
242 * Gets the path to the global settings for the Maven invocation.
243 *
244 * @return The path to the global settings for the Maven invocation or <code>null</code> to load the global settings
245 * from the default location.
246 * @since 2.1
247 */
248 File getGlobalSettingsFile();
249
250 /**
251 * Gets the path to the custom toolchains file
252 *
253 * @return The path to the custom toolchains file or <code>null</code> to load the toolchains from the default
254 * location
255 * @since 2.1
256 */
257 File getToolchainsFile();
258
259 /**
260 * Alternate path for the global toolchains file <b>Note. This is available since Maven 3.3.1</b>
261 *
262 * @return The path to the custom global toolchains file or <code>null</code> to load the global toolchains from the
263 * default location.
264 * @since 3.0.0
265 */
266 File getGlobalToolchainsFile();
267
268 /**
269 * Gets the checksum mode of the Maven invocation.
270 *
271 * @return The checksum mode, one of {@link CheckSumPolicy#Warn} and {@link CheckSumPolicy#Fail}.
272 * @since 3.0.0
273 */
274 CheckSumPolicy getGlobalChecksumPolicy();
275
276 /**
277 * Gets the profiles for the Maven invocation.
278 *
279 * @return The profiles for the Maven invocation or <code>null</code> if not set.
280 */
281 List<String> getProfiles();
282
283 /**
284 * Gets the environment variables for the Maven invocation.
285 *
286 * @return The environment variables for the Maven invocation or <code>null</code> if not set.
287 */
288 Map<String, String> getShellEnvironments();
289
290 /**
291 * Gets the value of the <code>MAVEN_OPTS</code> environment variable.
292 *
293 * @return The value of the <code>MAVEN_OPTS</code> environment variable or <code>null</code> if not set.
294 */
295 String getMavenOpts();
296
297 /**
298 * The show version behavior (-V option)
299 *
300 * @return The show version behavior
301 * @since 2.0.11
302 */
303 boolean isShowVersion();
304
305 /**
306 * Get the value of the {@code threads} argument.
307 *
308 * @return the value of the {@code threads} argument or {@code null} if not set
309 * @since 2.1
310 */
311 String getThreads();
312
313 // ----------------------------------------------------------------------
314 // Reactor Failure Mode
315 // ----------------------------------------------------------------------
316
317 /**
318 * The reactor failure behavior which to be used during Maven invocation.
319 */
320 enum ReactorFailureBehavior
321 {
322 /**
323 * Stop at first failure in reactor builds
324 */
325 FailFast( "ff", "fail-fast" ),
326 /**
327 * Only fail the build afterwards. allow all non-impacted builds to continue.
328 */
329 FailAtEnd( "fae", "fail-at-end" ),
330 /**
331 * <b>NEVER</b> fail the build, regardless of project result
332 */
333 FailNever( "fn", "fail-never" );
334
335 private String shortOption;
336
337 private String longOption;
338
339 ReactorFailureBehavior( String shortOption, String longOption )
340 {
341 this.shortOption = shortOption;
342 this.longOption = longOption;
343 }
344
345 public String getShortOption()
346 {
347 return this.shortOption;
348 }
349
350 public String getLongOption()
351 {
352 return this.longOption;
353 }
354
355 /**
356 * Returns the enumeration type which is related to the given long option.
357 *
358 * @param longOption The type which is searched for.
359 * @return The appropriate {@link ReactorFailureBehavior}
360 * @throws IllegalArgumentException in case of an long option which does not exists.
361 */
362 public static ReactorFailureBehavior valueOfByLongOption( String longOption )
363 {
364 for ( ReactorFailureBehavior item : ReactorFailureBehavior.values() )
365 {
366 if ( item.getLongOption().equals( longOption ) )
367 {
368 return item;
369 }
370 }
371 throw new IllegalArgumentException( "The string '" + longOption
372 + "' can not be converted to enumeration." );
373 }
374 };
375
376 // ----------------------------------------------------------------------
377 // Artifact repository policies
378 // ----------------------------------------------------------------------
379
380 /**
381 * The kind of checksum policy which should be used during Maven invocation.
382 */
383 enum CheckSumPolicy
384 {
385
386 /**
387 * Strict checksum checking equivalent of {@code --strict-checksums}
388 */
389 Fail,
390 /**
391 * Warn checksum failures equivalent {@code --lax-checksums}.
392 */
393 Warn;
394
395 }
396
397 // ----------------------------------------------------------------------
398 //
399 // ----------------------------------------------------------------------
400
401 /**
402 * Sets the interaction mode of the Maven invocation. Equivalent of {@code -B} and {@code --batch-mode}
403 *
404 * @param batchMode <code>true</code> if Maven should be executed in non-interactive mode, <code>false</code> if the
405 * interactive modes is used.
406 * @return This invocation request.
407 * @since 3.0.0
408 */
409 InvocationRequest setBatchMode( boolean batchMode );
410
411 /**
412 * Sets the network mode of the Maven invocation. Equivalent of {@code -o} and {@code --offline}
413 *
414 * @param offline <code>true</code> if Maven should be executed in offline mode, <code>false</code> if the online
415 * mode is used.
416 * @return This invocation request.
417 */
418 InvocationRequest setOffline( boolean offline );
419
420 /**
421 * Sets the debug mode of the Maven invocation. Equivalent of {@code -X} and {@code --debug}
422 *
423 * @param debug <code>true</code> if Maven should be executed in debug mode, <code>false</code> if the normal mode
424 * should be used.
425 * @return This invocation request.
426 */
427 InvocationRequest setDebug( boolean debug );
428
429 /**
430 * Sets the exception output mode of the Maven invocation. Equivalent of {@code -e} and {@code --errors}
431 *
432 * @param showErrors <code>true</code> if Maven should print stack traces, <code>false</code> otherwise.
433 * @return This invocation request.
434 */
435 InvocationRequest setShowErrors( boolean showErrors );
436
437 /**
438 * Specifies whether Maven should enforce an update check for plugins and snapshots. Equivalent of {@code -U} and
439 * {@code --update-snapshots}
440 *
441 * @param updateSnapshots <code>true</code> if plugins and snapshots should be updated, <code>false</code>
442 * otherwise.
443 * @return This invocation request.
444 */
445 InvocationRequest setUpdateSnapshots( boolean updateSnapshots );
446
447 /**
448 * Sets the failure mode of the Maven invocation. Equivalent of {@code -ff} and {@code --fail-fast}, {@code -fae}
449 * and {@code --fail-at-end}, {@code -fn} and {@code --fail-never}
450 *
451 * @param failureBehavior The failure mode, must be one of {@link ReactorFailureBehavior#FailFast},
452 * {@link ReactorFailureBehavior#FailAtEnd} and {@link ReactorFailureBehavior#FailNever}.
453 * @return This invocation request.
454 * @since 3.0.0
455 */
456 InvocationRequest setReactorFailureBehavior( ReactorFailureBehavior failureBehavior );
457
458 /**
459 * Sets the path to the base directory of the local repository to use for the Maven invocation.
460 *
461 * @param localRepository The path to the base directory of the local repository, may be <code>null</code>.
462 * @return This invocation request.
463 */
464 InvocationRequest setLocalRepositoryDirectory( File localRepository );
465
466 /**
467 * Sets the input stream used to provide input for the invoked Maven build. This is in particular useful when
468 * invoking Maven in interactive mode.
469 *
470 * @param inputStream The input stream used to provide input for the invoked Maven build, may be <code>null</code>
471 * if not required.
472 * @return This invocation request.
473 */
474 InvocationRequest setInputStream( InputStream inputStream );
475
476 /**
477 * Sets the handler used to capture the standard output from the Maven build.
478 *
479 * @param outputHandler The output handler, may be <code>null</code> if the output is not of interest.
480 * @return This invocation request.
481 */
482 InvocationRequest setOutputHandler( InvocationOutputHandler outputHandler );
483
484 /**
485 * Sets the handler used to capture the error output from the Maven build.
486 *
487 * @param errorHandler The error handler, may be <code>null</code> if the output is not of interest.
488 * @return This invocation request.
489 */
490 InvocationRequest setErrorHandler( InvocationOutputHandler errorHandler );
491
492 /**
493 * Sets the path to the POM for the Maven invocation. If no base directory is set, the parent directory of this POM
494 * will be used as the working directory for the Maven invocation.
495 *
496 * @param pomFile The path to the POM for the Maven invocation, may be <code>null</code> if not used.
497 * @return This invocation request.
498 */
499 InvocationRequest setPomFile( File pomFile );
500
501 /**
502 * Sets the (unqualified) filename of the POM for the Maven invocation. This setting is ignored if
503 * {@link #getPomFile()} does not return <code>null</code>. Otherwise, the base directory is assumed to contain a
504 * POM with this name.
505 *
506 * @param pomFilename The (unqualified) filename of the POM for the Maven invocation, may be <code>null</code> if
507 * not used.
508 * @return This invocation request.
509 */
510 InvocationRequest setPomFileName( String pomFilename );
511
512 /**
513 * Sets the path to the base directory of the POM for the Maven invocation. If {@link #getPomFile()} does not return
514 * <code>null</code>, this setting only affects the working directory for the Maven invocation.
515 *
516 * @param basedir The path to the base directory of the POM, may be <code>null</code> if not used.
517 * @return This invocation request.
518 */
519 InvocationRequest setBaseDirectory( File basedir );
520
521 /**
522 * Sets the path to the base directory of the Java installation used to run Maven.
523 *
524 * @param javaHome The path to the base directory of the Java installation used to run Maven, may be
525 * <code>null</code> to use the default Java home.
526 * @return This invocation request.
527 */
528 InvocationRequest setJavaHome( File javaHome );
529
530 /**
531 * Sets the system properties for the Maven invocation.
532 *
533 * @param properties The system properties for the Maven invocation, may be <code>null</code> if not set.
534 * @return This invocation request.
535 */
536 InvocationRequest setProperties( Properties properties );
537
538 /**
539 * Sets the goals for the Maven invocation.
540 *
541 * @param goals The goals for the Maven invocation, may be <code>null</code> to execute the POMs default goal.
542 * @return This invocation request.
543 */
544 InvocationRequest setGoals( List<String> goals );
545
546 /**
547 * Sets the profiles for the Maven invocation. Equivalent of {@code -P} and {@code --active-profiles}
548 *
549 * @param profiles The profiles for the Maven invocation, may be <code>null</code> to use the default profiles.
550 * @return This invocation request.
551 */
552 InvocationRequest setProfiles( List<String> profiles );
553
554 /**
555 * Specifies whether the environment variables of the current process should be propagated to the Maven invocation.
556 *
557 * @param shellEnvironmentInherited <code>true</code> if the environment variables should be propagated,
558 * <code>false</code> otherwise.
559 * @return This invocation request.
560 */
561 InvocationRequest setShellEnvironmentInherited( boolean shellEnvironmentInherited );
562
563 /**
564 * Sets the path to the user settings for the Maven invocation. Equivalent of {@code -s} and {@code --settings}
565 *
566 * @param userSettings The path to the user settings for the Maven invocation, may be <code>null</code> to load the
567 * user settings from the default location.
568 * @return This invocation request.
569 */
570 InvocationRequest setUserSettingsFile( File userSettings );
571
572 /**
573 * Sets the path to the global settings for the Maven invocation. Equivalent of {@code -gs} and
574 * {@code --global-settings}
575 *
576 * @param globalSettings The path to the global settings for the Maven invocation, may be <code>null</code> to load
577 * the global settings from the default location.
578 * @return This invocation request.
579 * @since 2.1
580 */
581 InvocationRequest setGlobalSettingsFile( File globalSettings );
582
583 /**
584 * Sets the alternate path for the user toolchains file Equivalent of {@code -t} or {@code --toolchains}
585 *
586 * @param toolchains the alternate path for the user toolchains file
587 * @return This invocation request
588 * @since 2.1
589 */
590 InvocationRequest setToolchainsFile( File toolchains );
591
592 /**
593 * Sets the alternate path for the global toolchains file Equivalent of {@code -gt} or {@code --global-toolchains}
594 *
595 * @param toolchains the alternate path for the global toolchains file
596 * @return This invocation request
597 * @since 3.0.0
598 */
599 InvocationRequest setGlobalToolchainsFile( File toolchains );
600
601 /**
602 * Sets the checksum mode of the Maven invocation. Equivalent of {@code -c} or {@code --lax-checksums}, {@code -C}
603 * or {@code --strict-checksums}
604 *
605 * @param globalChecksumPolicy The checksum mode, must be one of {@link CheckSumPolicy#Warn} and
606 * {@link CheckSumPolicy#Fail}.
607 * @return This invocation request.
608 * @since 3.0.0
609 */
610 InvocationRequest setGlobalChecksumPolicy( CheckSumPolicy globalChecksumPolicy );
611
612 /**
613 * Specifies whether Maven should check for plugin updates.
614 * <p>
615 * Equivalent of {@code -npu} or {@code --no-plugin-updates}
616 * </p>
617 * <p>
618 * <strong>note: </strong>Ineffective with Maven3, only kept for backward compatibility
619 * </p>
620 *
621 * @param nonPluginUpdates <code>true</code> if plugin updates should be suppressed, <code>false</code> otherwise.
622 * @return This invocation request.
623 */
624 InvocationRequest setNonPluginUpdates( boolean nonPluginUpdates );
625
626 /**
627 * Sets the recursion behavior of a reactor invocation. <em>Inverse</em> equivalent of {@code -N} and
628 * {@code --non-recursive}
629 *
630 * @param recursive <code>true</code> if sub modules should be build, <code>false</code> otherwise.
631 * @return This invocation request.
632 */
633 InvocationRequest setRecursive( boolean recursive );
634
635 /**
636 * Adds the specified environment variable to the Maven invocation.
637 *
638 * @param name The name of the environment variable, must not be <code>null</code>.
639 * @param value The value of the environment variable, must not be <code>null</code>.
640 * @return This invocation request.
641 */
642 InvocationRequest addShellEnvironment( String name, String value );
643
644 /**
645 * Sets the value of the <code>MAVEN_OPTS</code> environment variable.
646 *
647 * @param mavenOpts The value of the <code>MAVEN_OPTS</code> environment variable, may be <code>null</code> to use
648 * the default options.
649 * @return This invocation request.
650 */
651 InvocationRequest setMavenOpts( String mavenOpts );
652
653 /**
654 * enable displaying version without stopping the build Equivalent of {@code -V} or {@code --show-version}
655 *
656 * @param showVersion enable displaying version
657 * @return This invocation request.
658 * @since 2.0.11
659 */
660 InvocationRequest setShowVersion( boolean showVersion );
661
662 /**
663 * Thread count, for instance 2.0C where C is core multiplied Equivalent of {@code -T} or {@code --threads}
664 * <p>
665 * <strong>note: </strong>available since Maven3
666 * </p>
667 *
668 * @param threads the threadcount
669 * @return This invocation request.
670 * @since 2.1
671 */
672 InvocationRequest setThreads( String threads );
673
674 /**
675 * Sets the reactor project list. Equivalent of {@code -pl} or {@code --projects}
676 *
677 * @param projects the reactor project list
678 * @return This invocation request.
679 * @since 2.1
680 */
681 InvocationRequest setProjects( List<String> projects );
682
683 /**
684 * Enable the 'also make' mode. Equivalent of {@code -am} or {@code --also-make}
685 *
686 * @param alsoMake enable 'also make' mode
687 * @return This invocation request.
688 * @since 2.1
689 */
690 InvocationRequest setAlsoMake( boolean alsoMake );
691
692 /**
693 * Enable the 'also make dependents' mode. Equivalent of {@code -amd} or {@code --also-make-dependents}
694 *
695 * @param alsoMakeDependents enable 'also make' mode
696 * @return This invocation request.
697 * @since 2.1
698 */
699 InvocationRequest setAlsoMakeDependents( boolean alsoMakeDependents );
700
701 /**
702 * Resume reactor from specified project. Equivalent of {@code -rf} or {@code --resume-from}
703 *
704 * @param resumeFrom set the project to resume from
705 * @return This invocation request
706 * @since 2.1
707 */
708 InvocationRequest setResumeFrom( String resumeFrom );
709
710 /**
711 * The id of the build strategy to use. equivalent of {@code --builder id}. <b>Note. This is available since Maven
712 * 3.2.1</b>
713 *
714 * @param id The builder id.
715 * @return {@link InvocationRequest} FIXME: How to identify if this is a valid command line option?
716 * @since 3.0.0
717 */
718 InvocationRequest setBuilder( String id );
719
720 /**
721 * Get the current set builder strategy id equivalent of {@code --builder id}. <b>Note. This is available since
722 * Maven 3.2.1</b>
723 *
724 * @return The current set builder id.
725 * @since 3.0.0
726 */
727 String getBuilder();
728
729 int NO_TIMEOUT = 0;
730 /**
731 * @since 3.0.1
732 * @return the timeout in seconds to execute the project
733 */
734 int getTimeoutInSeconds();
735
736 /**
737 * @since 3.0.1
738 * @param timeoutInSeconds the timeout in seconds to execute the project
739 */
740 void setTimeoutInSeconds( int timeoutInSeconds );
741
742 }