|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectaim4.vehicle.VehicleSpecDatabase
public class VehicleSpecDatabase
The vehicle specification database.
Method Summary | |
---|---|
static int |
getIdByName(String name)
Get the id of the vehicle specification. |
static int |
getIdOfVehicleSpec(VehicleSpec spec)
Get the id of the vehicle specification. |
static int |
getNumOfSpec()
Get the total number of vehicle specifications in the database |
static VehicleSpec |
getVehicleSpecById(int id)
Get the vehicle specification. |
static VehicleSpec |
getVehicleSpecByName(String name)
Get the vehicle specification. |
static void |
registerSpec(VehicleSpec spec)
Register a vehicle specification. |
static boolean |
replaceSpec(VehicleSpec spec)
Place an registered vehicle spec with a new one. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static int getNumOfSpec()
public static void registerSpec(VehicleSpec spec)
spec
- the vehicle specificationpublic static boolean replaceSpec(VehicleSpec spec)
spec
- the new spec
public static int getIdOfVehicleSpec(VehicleSpec spec)
spec
- the vehicle specification
public static int getIdByName(String name)
name
- the name of the vehicle specification
public static VehicleSpec getVehicleSpecById(int id)
id
- the id of the vehicle specification
public static VehicleSpec getVehicleSpecByName(String name)
name
- the name of the vehicle specification
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |