|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Object
|
+--cad.simcad.worldsimulator.objects.SimulatedObject
|
+--cad.simcad.worldsimulator.objects.units.MyUnit
|
+--cad.simcad.worldsimulator.objects.units.Ambulance
Implementation of SimAmbulance
| Field Summary | |
protected boolean |
_autoProcess
|
protected Incident |
_currentIncident
|
protected EmergencyVehicule |
_ev
|
protected GPSPosition |
_gp
|
protected GPSSim |
_gps
|
protected MDTSim |
_mdt
|
protected boolean |
_nextToMyIncident
|
static int |
ARRIVED
|
static int |
FREE
|
static int |
IN_MISSION
|
static int |
UNAVAILABLE
|
| Fields inherited from class cad.simcad.worldsimulator.objects.units.MyUnit |
_baseTurnIncrement, _boundingRadius, _pp, _previousOne, _recomputing, _savedMovPoints, _state, _uc, _um, _velocity, IncrementWaypoint, ReachedGoal, WaitingForPath |
| Fields inherited from class cad.simcad.worldsimulator.objects.SimulatedObject |
_am, _className, _height, _id, _name, _om, _owner, _serial, _sime, _stateId, _width |
| Constructor Summary | |
Ambulance(SimEnvironment sime,
PathPlace mp,
UnitMediator um,
Owner owner)
Creates new Ambulance |
|
| Method Summary | |
void |
autoProcessIndicentArrival()
|
boolean |
getAutoProcess()
Returns true if Ambulance process incidents automatically |
double |
getDeformFactor()
Returns the deform factor of the Path user. |
EmergencyVehicule |
getEmergencyVehicule()
Returns the EmergencyVehicule for this Ambulance |
GPSSim |
getGPSSim()
Returns the simulated GPS of this ambulance |
double |
getMaxSteepNessRatio()
Return the maximum slope ratio the PathUser can walk on. |
MDTSim |
getMDTSim()
Returns the simulated MDT of this ambulance |
void |
manualProcessIncidentArrival()
|
void |
move()
Top of movement state loop: { If we're in IncrementWaypoint state: Increment our waypoint. |
void |
processIndicent(Incident p)
Ask the SimAmbulance to process an Incident |
void |
processIndicentPlace()
Ambulance moves to the Place of the Incident if it has one in cache |
void |
processIndicentPlace(Place p)
|
void |
setAutoProcess(boolean b)
Ask the SimAmbulance to process an Incident automatically or not |
void |
setGPSSim(GPSSim gps)
Set the simulated GPS of this ambulance |
void |
setMDTSim(MDTSim mdt)
Set the simulated MDT of this ambulance |
java.lang.String |
toString()
|
| Methods inherited from class cad.simcad.worldsimulator.objects.units.MyUnit |
debug, firePathComputed, getBoundingCircleRadius, getCurrentPathPlace, getHeight, getMiniMapColor, getObjectType, getOwner, getUnitControler, getVelocity, getWidth, getX, getY, isCollision, resolveNewMove, setState, setVelocity, stopObject, stopUnit, takeTurn, updateStateId |
| Methods inherited from class cad.simcad.worldsimulator.objects.SimulatedObject |
getClassName, getId, getName, getSerialNumber, getStateId, setStateId |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface cad.simcad.objectserver.spec.sim.SimAmbulance |
getVelocity, setVelocity |
| Methods inherited from interface cad.simcad.objectserver.spec.sim.SimObject |
getBoundingCircleRadius, getClassName, getCurrentPathPlace, getHeight, getId, getName, getObjectType, getSerialNumber, getStateId, getWidth, setStateId, stopObject, takeTurn |
| Methods inherited from interface cad.simcad.objectserver.spec.pathfinding.PathUser |
getId, getName |
| Field Detail |
public static int IN_MISSION
public static int FREE
public static int UNAVAILABLE
public static int ARRIVED
protected MDTSim _mdt
protected GPSSim _gps
protected EmergencyVehicule _ev
protected GPSPosition _gp
protected boolean _autoProcess
protected Incident _currentIncident
protected boolean _nextToMyIncident
| Constructor Detail |
public Ambulance(SimEnvironment sime,
PathPlace mp,
UnitMediator um,
Owner owner)
| Method Detail |
public double getMaxSteepNessRatio()
PathUser
getMaxSteepNessRatio in interface PathUserpublic double getDeformFactor()
getDeformFactor in interface PathUserpublic GPSSim getGPSSim()
getGPSSim in interface SimAmbulancepublic MDTSim getMDTSim()
getMDTSim in interface SimAmbulancepublic EmergencyVehicule getEmergencyVehicule()
SimAmbulance
getEmergencyVehicule in interface SimAmbulancepublic void move()
MyUnit
move in class MyUnitpublic void autoProcessIndicentArrival()
public void manualProcessIncidentArrival()
public void setGPSSim(GPSSim gps)
setGPSSim in interface SimAmbulancepublic void setMDTSim(MDTSim mdt)
setMDTSim in interface SimAmbulancepublic void setAutoProcess(boolean b)
SimAmbulance
setAutoProcess in interface SimAmbulancepublic boolean getAutoProcess()
SimAmbulance
getAutoProcess in interface SimAmbulancepublic void processIndicent(Incident p)
SimAmbulance
processIndicent in interface SimAmbulancepublic void processIndicentPlace(Place p)
public void processIndicentPlace()
SimAmbulance
processIndicentPlace in interface SimAmbulancepublic java.lang.String toString()
toString in class java.lang.Object
|
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||