Package rinde.sim.pdptw.common

Examples of rinde.sim.pdptw.common.VehicleDTO


  public static FabriRechtScenario fromJson(String json, int numVehicles,
      int vehicleCapacity) {
    final FabriRechtScenario scen = fromJson(json);
    final List<TimedEvent> events = newArrayList();
    for (int i = 0; i < numVehicles; i++) {
      events.add(new AddVehicleEvent(0, new VehicleDTO(
          scen.defaultVehicle.startPosition, scen.defaultVehicle.speed,
          vehicleCapacity, scen.defaultVehicle.availabilityTimeWindow)));
    }
    events.addAll(scen.asList());
    return new FabriRechtScenario(events, scen.getPossibleEventTypes(),
View Full Code Here


  public static FabriRechtScenario fromJson(Reader reader, int numVehicles,
      int vehicleCapacity) {
    final FabriRechtScenario scen = fromJson(reader);
    final List<TimedEvent> events = newArrayList();
    for (int i = 0; i < numVehicles; i++) {
      events.add(new AddVehicleEvent(0, new VehicleDTO(
          scen.defaultVehicle.startPosition, scen.defaultVehicle.speed,
          vehicleCapacity, scen.defaultVehicle.availabilityTimeWindow)));
    }
    events.addAll(scen.asList());
    return new FabriRechtScenario(events, scen.getPossibleEventTypes(),
View Full Code Here

      // important than customer satisfaction.
      checkArgument(
          scenarioLength > maxRequiredTime,
          "The scenario length must be long enough such that there is enough time for a vehicle to service a pickup at one end of the environment and to service a delivery at an opposite end of the environment and be back in time at the depot.");

      final VehicleDTO vehicleDto = new VehicleDTO(depotLocation,
          vehicleSpeed,
          VEHICLE_CAPACITY, new TimeWindow(0, scenarioLength));

      if (arrivalTimesGenerator == null) {
        arrivalTimesGenerator = new PoissonProcessArrivalTimes(
View Full Code Here

    final Point depotPosition = new Point(2.0, 2.5);
    final double truckSpeed = 30;
    events.add(new AddDepotEvent(-1, depotPosition));
    for (int i = 0; i < numVehicles; i++) {
      events.add(new AddVehicleEvent(-1, new VehicleDTO(depotPosition,
          truckSpeed, 0, TimeWindow.ALWAYS)));
    }

    events.addAll(asList(parcelEvents));
View Full Code Here

TOP

Related Classes of rinde.sim.pdptw.common.VehicleDTO

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.