logist.simulation
Interface Vehicle


public interface Vehicle

Collection of useful information about a vehicle.

A get-prefix indicates that the return value of the method may change over time. All other methods return constant values.

Author:
Robin Steiger

Method Summary
 int capacity()
          The capacity of the vehicle
 java.awt.Color color()
          The color of the vehicle
 int costPerKm()
          The cost/km of the vehicle
 Topology.City getCurrentCity()
          The current city of the vehicle
 TaskSet getCurrentTasks()
          The tasks that are currently being transported by the vehicle.
 double getDistance()
          The total distance (in km) traveled by the vehicle
 long getDistanceUnits()
          The total distance (in units) traveled by the vehicle.
 long getReward()
          The sum of rewards for all delivered tasks
 Topology.City homeCity()
          The starting location of the vehicle
 int id()
          A unique id for each vehicle of the same agent/company, in the range [0,numVehiclesOfAgent).
 java.lang.String name()
          The name of the vehicle
 double speed()
          The speed of the vehicle
 

Method Detail

id

int id()
A unique id for each vehicle of the same agent/company, in the range [0,numVehiclesOfAgent).


name

java.lang.String name()
The name of the vehicle


capacity

int capacity()
The capacity of the vehicle


homeCity

Topology.City homeCity()
The starting location of the vehicle


speed

double speed()
The speed of the vehicle


costPerKm

int costPerKm()
The cost/km of the vehicle


getCurrentCity

Topology.City getCurrentCity()
The current city of the vehicle


getCurrentTasks

TaskSet getCurrentTasks()
The tasks that are currently being transported by the vehicle. These tasks have been picked up but have not yet been delivered.


getReward

long getReward()
The sum of rewards for all delivered tasks


getDistanceUnits

long getDistanceUnits()
The total distance (in units) traveled by the vehicle.

See Also:
Measures

getDistance

double getDistance()
The total distance (in km) traveled by the vehicle


color

java.awt.Color color()
The color of the vehicle