|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Object | +--taxisrus.implementation.Zone
| Constructor Summary | |
Zone()
Zone default constructor -- never call this. |
|
Zone(int zoneID)
Zone constructor |
|
| Method Summary | |
void |
addCabToBack(Cab cab)
Adds an open cab to the back of the cab list within the zone. |
void |
addCabToFront(Cab cab)
Adds an open cab to the front of the cab list; for example, if a customer cancels right after the cab is scheduled. |
void |
clearCabList()
Clears the cab list. |
Cab |
getCab(int cabID)
Returns the cab object corresponding to the cabID. |
Vector |
getCabList()
Returns the cab list from the zone. |
Cab |
getNextCab()
Removes and returns the next cab. |
int |
getNumCabs()
Returns how many cabs are in the zone. |
int |
getZoneID()
Returns the zone id. |
Cab |
removeCab(int cabID)
Removes a cab from the zone's cab list |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public Zone()
public Zone(int zoneID)
zoneID - the ID of this zone| Method Detail |
public int getZoneID()
public void addCabToFront(Cab cab)
cab - the cab to add to the front of the cab listpublic void addCabToBack(Cab cab)
cab - the cab to add to the back of the cab listpublic Cab getNextCab()
public Vector getCabList()
public int getNumCabs()
public Cab removeCab(int cabID)
cabID - the cab ID of the cab to remove from zonepublic Cab getCab(int cabID)
cabID - the cab ID of the cab to be retrievepublic void clearCabList()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||