sim.register(new DefaultPDPModel());
sim.register(new PDPRoadModel(new PlaneRoadModel(new Point(0, 0),
new Point(10, 10), 50), false));
sim.configure();
final RouteFollowingVehicle rfv = new RouteFollowingVehicle(new VehicleDTO(
new Point(1, 1), 50, 10, new TimeWindow(0, 1000000)), false);
final Depot depot = new DefaultDepot(new Point(5, 5));
final DefaultParcel dp1 = new DefaultParcel(new ParcelDTO(new Point(2, 2),
new Point(3, 3), new TimeWindow(0, 1000), new TimeWindow(0, 1000), 0,
0L, 5L, 5L));
final DefaultParcel dp2 = new DefaultParcel(new ParcelDTO(new Point(2, 2),
new Point(3, 3), new TimeWindow(0, 1000), new TimeWindow(0, 1000), 0,
0L, 5L, 5L));
sim.register(depot);
sim.register(rfv);
sim.register(dp1);
sim.register(dp2);
rfv.setRoute(asList(dp1, dp2));
while (rfv.getRoute().size() > 0) {
sim.tick();
}
final SimulationConverter simConv = Solvers.converterBuilder().with(sim)
.build();