1import java.util.*;
2
3public class CircleSeeding extends StraightSeeding {
4
5 public CircleSeeding(Vector sw,
6 int lanes) {
7 super(sw, lanes); //straight seed first
8 seed();
9 }
10
11 protected void seed() {
12 super.seed(); //do straight seed as default
13
14 int circle;
15
16 if(numHeats>=2 ) {
17 if(numHeats>=3)
18 circle = 3;
19 else
20 circle = 2;
21
22 int i = 0;
23 for(int j=0; j<numLanes; ++j)
24 for(int k=0; k<circle; ++k) {
25 swmrs[i].setLane(lanes[j]);
26 swmrs[i++].setHeat(numHeats-k);
27 }
28 }
29 }
30
31}