Package org.apache.camel.support.task
Class ForegroundTask.ForegroundTaskBuilder
java.lang.Object
org.apache.camel.support.task.AbstractTaskBuilder<ForegroundTask>
org.apache.camel.support.task.ForegroundTask.ForegroundTaskBuilder
- All Implemented Interfaces:
TaskBuilder<ForegroundTask>
- Enclosing class:
- ForegroundTask
public static class ForegroundTask.ForegroundTaskBuilder
extends AbstractTaskBuilder<ForegroundTask>
A builder helper for building new foreground tasks
-
Field Summary
Fields inherited from class org.apache.camel.support.task.AbstractTaskBuilder
DEFAULT_NAME -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds the task of the given type for the builderwithBudget(IterationBudget budget) Sets an iteration budget for the task (i.e.: the task will not run more than the given number of iterations)Sets the name of the taskMethods inherited from class org.apache.camel.support.task.AbstractTaskBuilder
getName
-
Constructor Details
-
ForegroundTaskBuilder
public ForegroundTaskBuilder()
-
-
Method Details
-
withName
Sets the name of the task- Overrides:
withNamein classAbstractTaskBuilder<ForegroundTask>- Parameters:
name- the name- Returns:
- an instance of this builder
-
withBudget
Sets an iteration budget for the task (i.e.: the task will not run more than the given number of iterations)- Parameters:
budget- the budget- Returns:
- an instance of this builder
-
build
Description copied from interface:TaskBuilderBuilds the task of the given type for the builder- Returns:
- a new instance of the task
-