- All Implemented Interfaces:
Runner
Para
is a class to runs
Runner
(s) in parallel.
-
Nested Class Summary
Nested Classes
static final record
An error reason which indicates some runner which is runned in parallel
failed.
static final record
An error reason which indicates that an exception occurs in parallelized
runner.
-
Constructor Summary
Constructors
The constructor which takes an array of
Runner
(s) as arguments.
-
Method Summary
void
Runs the
Runner
(s) holding in this object in parallel.
static void
Runs the specified
Runner
(s) in parallel.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Para
public Para(Runner... runners)
The constructor which takes an array of
Runner
(s) as arguments.
- Parameters:
runners
- Runner
's variadic arguments.
-
Method Details
-
run
public void run()
throws
Err
Runs the
Runner
(s) holding in this object in parallel.
- Specified by:
run
in interface Runner
- Throws:
Err
- If it is failed to run some of the runners.
-
run
public static void run(Runner... runners)
throws Err
Runs the specified
Runner
(s) in parallel.
- Parameters:
runners
- Runner
's variadic arguments.
- Throws:
Err
- If it is failed to run some of the runners.