|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.activemath.feedback.therapies.Therapy
public class Therapy
This class is supposed to hold the 'therapy' following a certain 'diagnose' inferred by the
org.activemath.feedback.SuggestionEngine.
It contains messages to be displayed to the user, as well as a list of
Prescriptions. These are
basically presentation actions that are not immediately displayed, but instead have to be requested
by the user, e.g. by following a generated link.
A Therapy keeps also track of the diagnoses that caused its generation in its anamnesis.
| Field Summary | |
|---|---|
static String |
CONTENT_PRESENTATION
|
static String |
GUIDE_NAVIGATION
|
protected String |
message
|
protected String |
name
|
static String |
SKIPPED_BEGINNING
|
protected boolean |
smile
|
| Constructor Summary | |
|---|---|
Therapy(String name,
String type)
|
|
| Method Summary | |
|---|---|
void |
addDiagnose(Diagnose diagnose)
Adds a Diagnose to this Therapy's anamnesis. |
void |
addPrescription(Prescription p)
|
int |
compareTo(Object therapy)
Compares two therapies. |
List |
getAnamnesis()
Returns this Therapy's anamnesis. |
String |
getMessage()
|
String |
getName()
|
List |
getPrescriptions()
|
boolean |
getSmile()
|
long |
getTimestamp()
|
String |
getType()
|
void |
setAnamnesis(List l)
Sets this Therapy's anamnesis List. |
void |
setMessage(String message)
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final String GUIDE_NAVIGATION
public static final String SKIPPED_BEGINNING
public static final String CONTENT_PRESENTATION
protected String name
protected String message
protected boolean smile
| Constructor Detail |
|---|
public Therapy(String name,
String type)
| Method Detail |
|---|
public void addPrescription(Prescription p)
public void addDiagnose(Diagnose diagnose)
Diagnose to this Therapy's anamnesis.
diagnose - the Diagnose to add to this Therapy's anamnesis.public List getAnamnesis()
Diagnose objects responsible for the generation of this Therapy.public void setAnamnesis(List l)
Diagnose objects responsible for the generation of this Therapy.
l - The Anamnesis List to be set for this Therapy.public int compareTo(Object therapy)
timestamp field is subject to comparison.
compareTo in interface Comparabletherapy - The Object that is to be compared to this Therapy.
therapy.timestamp-this.timestamp), or -1 if therapy is not instanceof Therapypublic String toString()
toString in class Objectpublic long getTimestamp()
public List getPrescriptions()
public String getName()
public String getType()
public String getMessage()
public void setMessage(String message)
message - The message to set.public boolean getSmile()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||