Package rife.bld.extension
Class BootWarOperation
Builds and creates a Spring Boot executable web archive (WAR).
- Since:
- 1.0
- Author:
- Erik C. Thauvin
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
execute()
Performs the BootJar operation.protected void
executeCopyWebInfProvidedLib
(File stagingWebInfDirectory) Part of theexecute
operation, copies theWEB-INF/lib-provided
libraries.protected File
executeCreateWebInfDirectory
(File stagingDirectory) Part of theexecute
operation, creates theWEB-INF
staging directory.fromProject
(Project project) Configures the operation from aProject
.Retrieves the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibs
(File... jars) Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibs
(String... jars) Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibs
(Path... jars) Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibs
(Collection<File> jars) Provides libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibsPaths
(Collection<Path> jars) Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.providedLibsStrings
(Collection<String> jars) Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.Methods inherited from class rife.bld.extension.AbstractBootOperation
destinationDirectory, destinationDirectory, destinationDirectory, destinationDirectory, destinationFileName, destinationFileName, executeCopyBootLoader, executeCopyInfClassesFiles, executeCopyInfLibs, executeCreateArchive, executeCreateManifest, infLibs, infLibs, infLibs, infLibs, infLibs, infLibsPaths, infLibsStrings, launcherClass, launcherClass, launcherLibs, launcherLibs, launcherLibs, launcherLibs, launcherLibs, launcherLibsPaths, launcherLibsStrings, mainClass, mainClass, manifestAttribute, manifestAttributes, manifestAttributes, sourceDirectories, sourceDirectories, sourceDirectories, sourceDirectories, sourceDirectories, sourceDirectoriesPaths, sourceDirectoriesStrings, verifyExecute
Methods inherited from class rife.bld.operations.AbstractOperation
executeOnce, executeOnce, silent, silent
-
Constructor Details
-
BootWarOperation
public BootWarOperation()
-
-
Method Details
-
execute
Performs the BootJar operation.- Specified by:
execute
in classAbstractOperation<AbstractBootOperation<BootWarOperation>>
- Throws:
Exception
-
executeCopyWebInfProvidedLib
Part of theexecute
operation, copies theWEB-INF/lib-provided
libraries.- Parameters:
stagingWebInfDirectory
- the stagingWEB-INF/lib-provided
directory- Throws:
IOException
- if an error occurs
-
executeCreateWebInfDirectory
Part of theexecute
operation, creates theWEB-INF
staging directory.- Parameters:
stagingDirectory
- the staging directory- Returns:
- the
WEB-INF
directory location - Throws:
IOException
- if an error occurs
-
fromProject
Configures the operation from aProject
.Sets the following:
- The
destination file name
toarchiveBaseName
andversion
- The
INF libs
tocompileClasspathJars
,runtimeClasspathJars
andbuildDistDirectory
- The
launcher class
toWarLauncher
- The
launcher libs
tostandaloneClasspathJars
- The
main class
tomainClass
- The
Manifest-Version
,Main-Class
andStart-Class
manifest attributes
- The
source directories
tobuildMainDirectory
andsrcMainResourcesDirectory
- Specified by:
fromProject
in classAbstractBootOperation<BootWarOperation>
- Parameters:
project
- the project- Returns:
- this operation instance
- Throws:
IOException
- if an error occurs
- The
-
providedLibs
Provides libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- a collection of Java archive files- Returns:
- this operation instance
- See Also:
-
providedLibs
Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- one or more Java archive files- Returns:
- this operation instance
- See Also:
-
providedLibs
Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- one or more Java archive files- Returns:
- this operation instance
- See Also:
-
providedLibs
Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- one or more Java archive files- Returns:
- this operation instance
- See Also:
-
providedLibs
Retrieves the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Returns:
- the list of Java archive files.
-
providedLibsPaths
Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- one or more Java archive files- Returns:
- this operation instance
- See Also:
-
providedLibsStrings
Provides the libraries that will be used for the WAR creation in/WEB-INF/lib-provided
.- Parameters:
jars
- one or more Java archive files- Returns:
- this operation instance
- See Also:
-