2020-11-08 00:31:20 +01:00
|
|
|
|
|
|
|
public class SUV extends CivilVehicle {
|
2020-11-14 14:31:43 +01:00
|
|
|
private String UID;
|
|
|
|
private static int numeberOfSUV;
|
2020-11-08 00:31:20 +01:00
|
|
|
private final int TIME_TO_FIX = 15; //in minutes
|
2020-11-13 20:35:52 +01:00
|
|
|
public static final int MAX_FORWARD = 1300;
|
2020-11-08 00:31:20 +01:00
|
|
|
|
|
|
|
public SUV(double vehicleSize){
|
|
|
|
super(vehicleSize);
|
2020-11-14 14:31:43 +01:00
|
|
|
generateUID();
|
2020-11-08 00:31:20 +01:00
|
|
|
}
|
|
|
|
|
2020-11-22 23:20:48 +01:00
|
|
|
@Override
|
|
|
|
public int getMaxSpeed() {
|
|
|
|
return MAX_FORWARD;
|
|
|
|
}
|
|
|
|
|
2020-11-08 00:31:20 +01:00
|
|
|
public int getTimeToFix(){
|
|
|
|
return TIME_TO_FIX;
|
|
|
|
}
|
2020-11-14 14:31:43 +01:00
|
|
|
|
|
|
|
private void generateUID() {
|
|
|
|
numeberOfSUV++;
|
|
|
|
this.UID = String.format("SUV%04d", numeberOfSUV);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
public String getUID(){
|
|
|
|
return this.UID;
|
|
|
|
}
|
|
|
|
|
2020-11-08 00:31:20 +01:00
|
|
|
|
|
|
|
|
|
|
|
}
|