| java.lang.Object demo.coordination.Main
Main | public class Main (Code) | | Sample to demonstrate how to instrument things like CyclicBarrier
and use them as a distributed mechanism.
|
Constructor Summary | |
public | Main(int expectedParticipants) Create an instance, setting the number of VMs expected to
participate in the demo. |
Method Summary | |
final public static void | main(String[] args) | public void | run() Start up multiple threads and wait. |
Main | public Main(int expectedParticipants)(Code) | | Create an instance, setting the number of VMs expected to
participate in the demo.
|
run | public void run()(Code) | | Start up multiple threads and wait. Once all the theads have
started, execute some code. When all threads have finished
executing the code, coordinate the shutdown of the participants.
|
|
|