|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface MedicalAid
This interface defines an entity that can provide Medical Aid to an injured person. It can provide different types of treatments.
Method Summary | |
---|---|
boolean |
canTreatProblem(HealthProblem problem)
Checks if a health problem can be treated at this medical aid. |
java.util.List |
getProblemsAwaitingTreatment()
Gets the health problems awaiting treatment at the medical station. |
java.util.List |
getProblemsBeingTreated()
Gets the health problems currently being treated at the medical station. |
java.util.List |
getSupportedTreatments()
Get a list of supported Treatments at this medical aid. |
void |
requestTreatment(HealthProblem problem)
Add a health problem to the queue of problems awaiting treatment at this medical aid. |
void |
startTreatment(HealthProblem problem,
double treatmentDuration)
Starts the treatment of a health problem in the waiting queue. |
void |
stopTreatment(HealthProblem problem)
Stop a previously started treatment. |
Method Detail |
---|
java.util.List getProblemsAwaitingTreatment()
java.util.List getProblemsBeingTreated()
java.util.List getSupportedTreatments()
boolean canTreatProblem(HealthProblem problem)
problem
- The health problem to check treatment.
void requestTreatment(HealthProblem problem) throws java.lang.Exception
problem
- The health problem to await treatment.
java.lang.Exception
- if health problem cannot be treated here.void startTreatment(HealthProblem problem, double treatmentDuration) throws java.lang.Exception
problem
- the health problem to start treating.treatmentDuration
- the time required to perform the treatment.
java.lang.Exception
- if treatment cannot be started.void stopTreatment(HealthProblem problem) throws java.lang.Exception
problem
- Health problem stopping treatment on.
java.lang.Exception
- if health problem is not being treated.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |