接口 BootArchive
- 所有超级接口:
Comparable<Task>
,ExtensionAware
,Named
,Task
A Spring Boot "fat" archive task.
- 从以下版本开始:
- 2.0.0
- 作者:
- Andy Wilkinson, Moritz Halbritter
-
嵌套类概要
从接口继承的嵌套类/接口 org.gradle.api.Task
Task.Namer
-
字段概要
从接口继承的字段 org.gradle.api.Task
TASK_ACTION, TASK_CONSTRUCTOR_ARGS, TASK_DEPENDS_ON, TASK_DESCRIPTION, TASK_GROUP, TASK_NAME, TASK_OVERWRITE, TASK_TYPE
-
方法概要
修饰符和类型方法说明void
Adds files to the classpath to include in the archive.Returns the classpath that will be included in the archive.Returns whether the JAR tools should be included as a dependency in the layered archive.Returns theLaunchScriptConfiguration
that will control the script that is prepended to the archive.Property
<org.springframework.boot.loader.tools.LoaderImplementation> The loader implementation that should be used with the archive.Returns the fully-qualified name of the application's main class.Returns the target Java version of the project (e.g. as provided by thetargetCompatibility
build property).void
Configures the archive to have a prepended launch script.void
launchScript
(Action<LaunchScriptConfiguration> action) Configures the archive to have a prepended launch script, customizing its configuration using the givenaction
.void
requiresUnpack
(String... patterns) Adds Ant-style patterns that identify files that must be unpacked from the archive when it is launched.void
requiresUnpack
(Spec<FileTreeElement> spec) Adds a spec that identifies files that must be unpacked from the archive when it is launched.void
resolvedArtifacts
(Provider<Set<ResolvedArtifactResult>> resolvedArtifacts) Registers the given lazily providedresolvedArtifacts
.void
setClasspath
(Object classpath) Sets the classpath to include in the archive.void
setClasspath
(FileCollection classpath) Sets the classpath to include in the archive.从接口继承的方法 java.lang.Comparable
compareTo
从接口继承的方法 org.gradle.api.plugins.ExtensionAware
getExtensions
从接口继承的方法 org.gradle.api.Task
configure, dependsOn, doFirst, doFirst, doFirst, doLast, doLast, doLast, doNotTrackState, finalizedBy, getActions, getAnt, getConvention, getDependsOn, getDescription, getDestroyables, getDidWork, getEnabled, getFinalizedBy, getGroup, getInputs, getLocalState, getLogger, getLogging, getMustRunAfter, getName, getOutputs, getPath, getProject, getShouldRunAfter, getState, getTaskDependencies, getTemporaryDir, getTimeout, hasProperty, mustRunAfter, notCompatibleWithConfigurationCache, onlyIf, onlyIf, onlyIf, property, setActions, setDependsOn, setDescription, setDidWork, setEnabled, setFinalizedBy, setGroup, setMustRunAfter, setOnlyIf, setOnlyIf, setOnlyIf, setProperty, setShouldRunAfter, shouldRunAfter, usesService
-
方法详细资料
-
getMainClass
Returns the fully-qualified name of the application's main class.- 返回:
- the fully-qualified name of the application's main class
- 从以下版本开始:
- 2.4.0
-
requiresUnpack
Adds Ant-style patterns that identify files that must be unpacked from the archive when it is launched.- 参数:
patterns
- the patterns
-
requiresUnpack
Adds a spec that identifies files that must be unpacked from the archive when it is launched.- 参数:
spec
- the spec
-
getLaunchScript
Returns theLaunchScriptConfiguration
that will control the script that is prepended to the archive.- 返回:
- the launch script configuration, or
null
if the launch script has not been configured.
-
launchScript
void launchScript()Configures the archive to have a prepended launch script. -
launchScript
Configures the archive to have a prepended launch script, customizing its configuration using the givenaction
.- 参数:
action
- the action to apply
-
getClasspath
Returns the classpath that will be included in the archive.- 返回:
- the classpath
-
classpath
Adds files to the classpath to include in the archive. The givenclasspath
is evaluated as perProject.files(Object...)
.- 参数:
classpath
- the additions to the classpath
-
setClasspath
Sets the classpath to include in the archive. The givenclasspath
is evaluated as perProject.files(Object...)
.- 参数:
classpath
- the classpath- 从以下版本开始:
- 2.0.7
-
setClasspath
Sets the classpath to include in the archive.- 参数:
classpath
- the classpath- 从以下版本开始:
- 2.0.7
-
getTargetJavaVersion
Returns the target Java version of the project (e.g. as provided by thetargetCompatibility
build property).- 返回:
- the target Java version
-
resolvedArtifacts
Registers the given lazily providedresolvedArtifacts
. They are used to map from the files in theclasspath
to their dependency coordinates.- 参数:
resolvedArtifacts
- the lazily provided resolved artifacts- 从以下版本开始:
- 3.0.7
-
getLoaderImplementation
@Input @Optional Property<org.springframework.boot.loader.tools.LoaderImplementation> getLoaderImplementation()The loader implementation that should be used with the archive.- 返回:
- the loader implementation
- 从以下版本开始:
- 3.2.0
-
getIncludeTools
Returns whether the JAR tools should be included as a dependency in the layered archive.- 返回:
- whether the JAR tools should be included
- 从以下版本开始:
- 3.3.0
-