Class FlowJobBuilder
java.lang.Object
org.springframework.batch.core.job.builder.JobBuilderHelper<FlowJobBuilder>
org.springframework.batch.core.job.builder.FlowJobBuilder
A job builder for
FlowJob
instances. A flow job delegates processing to a
nested flow composed of steps and conditional transitions between steps.- Since:
- 2.2
- Author:
- Dave Syer
-
Nested Class Summary
Nested classes/interfaces inherited from class org.springframework.batch.core.job.builder.JobBuilderHelper
JobBuilderHelper.CommonJobProperties
-
Field Summary
Fields inherited from class org.springframework.batch.core.job.builder.JobBuilderHelper
logger
-
Constructor Summary
ConstructorsConstructorDescriptionFlowJobBuilder
(JobBuilderHelper<?> parent) Create a new builder initialized with any properties in the parent. -
Method Summary
Modifier and TypeMethodDescriptionbuild()
Build a job that executes the flow provided, normally composed of other steps.protected FlowJobBuilder
Provide a single flow to execute as the job.Start a job with this flow, but expect to transition from there to other flows or steps.Start a job with this step, but expect to transition from there to other flows or steps.Methods inherited from class org.springframework.batch.core.job.builder.JobBuilderHelper
enhance, getJobRepository, getName, incrementer, isRestartable, listener, listener, meterRegistry, observationConvention, observationRegistry, preventRestart, repository, validator
-
Constructor Details
-
FlowJobBuilder
Create a new builder initialized with any properties in the parent. The parent is copied, so it can be re-used.- Parameters:
parent
- a parent helper containing common job properties
-
-
Method Details
-
start
Start a job with this flow, but expect to transition from there to other flows or steps.- Parameters:
flow
- the flow to start with- Returns:
- a builder to enable fluent chaining
-
start
Start a job with this step, but expect to transition from there to other flows or steps.- Parameters:
step
- the step to start with- Returns:
- a builder to enable fluent chaining
-
flow
Provide a single flow to execute as the job.- Parameters:
flow
- the flow to execute- Returns:
- this for fluent chaining
-
build
Build a job that executes the flow provided, normally composed of other steps.- Returns:
- a flow job
-