Interface Series
-
- All Superinterfaces:
java.lang.Iterable<java.util.Map<java.lang.String,java.lang.String>>
public interface Series extends java.lang.Iterable<java.util.Map<java.lang.String,java.lang.String>>
With a series thejobs
andresultActions
can be executed multiple times each with a defined set of properties.The
Series
implementation is responsible to return a set of properties; for each of those properties all jobs are executed and all actions are run is the same way they would run in a task without series. Each map returned by the series's iterator is one task-execution. The properties from the series can affect the jobs and actions: their properties can have placeholders which are replaced with the value from the series on execution.
Format:{PlaceHolderName}
Example: execute one report for different users: The series produces a property 'email', which the Address of the user to send the email to. In theEmailResultAction
we specify as email receiver:admin@company.com;{email}
For each series it will create an Email (probably with the results of configuredjobs
which also uses placeholders) to admin and the user from the series.If you implement custom jobs or resultActions please keep in mind that only properties which have a corresponding
Field
will get its placeholders replaced. SeeAbstractFactory.getInformation(com.inet.id.GUID)
.There can only be one series per task, or none. Note that if the iterator() of this class does not return any elements then no job or action is executed.
- Since:
- taskplanner 3.0
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
cleanUp(boolean previewOnly)
Perform some cleanup.
-
-
-
Method Detail
-
cleanUp
void cleanUp(boolean previewOnly) throws java.lang.Exception
Perform some cleanup.This is guaranteed to be called if
Iterable.iterator()
was called.- Parameters:
previewOnly
- true if this series was used temporarily as a preview only, false if it was for a full run of a task.- Throws:
java.lang.Exception
- if some problems occurred- Since:
- taskplanner 3.0
-
-