|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.processmining.framework.models.recommendation.Recommendation
public class Recommendation
A simple data structure for storing recommendations, i.e. that a specific task should be executed and the confidence with which this is recommended. Optionally, the recommendation may also contain the resource specification for which it applies.
Field Summary | |
---|---|
double |
confidence
|
java.lang.String |
eventType
|
protected java.util.SortedSet<java.lang.String> |
groups
|
java.lang.String |
rationale
|
protected java.util.SortedSet<java.lang.String> |
roles
|
java.lang.String |
task
|
protected java.util.SortedSet<java.lang.String> |
users
|
double |
weight
|
Constructor Summary | |
---|---|
Recommendation()
Creates a new, pristine recommendation. |
|
Recommendation(java.lang.String task,
double confidence,
java.lang.String rationale,
java.lang.String eventType,
java.util.SortedSet<java.lang.String> users,
java.util.SortedSet<java.lang.String> roles,
java.util.SortedSet<java.lang.String> groups,
int support)
Creates a new recommendation. |
Method Summary | |
---|---|
void |
addGroup(java.lang.String aGroup)
Adds a group for which this recommendation holds |
void |
addRecomendation(Recommendation r)
|
void |
addRole(java.lang.String aRole)
Adds a role for which this recommendation holds |
void |
addUser(java.lang.String aUser)
Adds a user for which this recommendation holds |
int |
compareTo(Recommendation rec)
The compareTo method is implemented based on the confidence of the recommendation. |
boolean |
equals(java.lang.Object o)
|
double |
getConfidence()
|
java.lang.String |
getEventType()
optional: may return null if not set! |
java.util.SortedSet<java.lang.String> |
getGroups()
optional: may return null if not set! |
java.lang.String |
getRationale()
optional: may return null if not set! |
java.util.SortedSet<java.lang.String> |
getRoles()
optional: may return null if not set! |
java.lang.String |
getTask()
|
java.util.SortedSet<java.lang.String> |
getUsers()
optional: may return null if not set! |
double |
getWeight()
|
void |
setConfidence(double aConfidence)
Sets the confidence of this recommendation |
void |
setEventType(java.lang.String anEventType)
Sets the recommended event type |
void |
setRationale(java.lang.String aRationale)
Sets the rationale for this recommendation |
void |
setTask(java.lang.String aTask)
Sets the recommended task |
void |
setWeight(double aSup)
Sets the support of this recommendation |
java.lang.String |
toString()
|
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public java.lang.String task
public java.lang.String eventType
public double confidence
public java.lang.String rationale
protected java.util.SortedSet<java.lang.String> users
protected java.util.SortedSet<java.lang.String> roles
protected java.util.SortedSet<java.lang.String> groups
public double weight
Constructor Detail |
---|
public Recommendation()
public Recommendation(java.lang.String task, double confidence, java.lang.String rationale, java.lang.String eventType, java.util.SortedSet<java.lang.String> users, java.util.SortedSet<java.lang.String> roles, java.util.SortedSet<java.lang.String> groups, int support)
task
- The name of the task which is recommended.confidence
- Confidence of the recommendation (should be within [0, 1])rationale
- optional: A human-readable description of why this is recommendedeventType
- optional: The suggested event type to be triggered.users
- optional: the set of users to which this recommendation applies.roles
- optional: the set of roles to which this recommendation applies.groups
- optional: the set of groups to which this recommendation applies.support
- optional: a weight for the basis of this decision.Method Detail |
---|
public void setTask(java.lang.String aTask)
aTask
- public void setEventType(java.lang.String anEventType)
anEventType
- public void setConfidence(double aConfidence)
aConfidence
- double value within [0, 1]public void setWeight(double aSup)
aConfidence
- double value within [0, 1]public void setRationale(java.lang.String aRationale)
aRationale
- human-readable justification or explanation stringpublic void addUser(java.lang.String aUser)
aUser
- public void addRole(java.lang.String aRole)
aRole
- public void addGroup(java.lang.String aGroup)
aGroup
- public java.lang.String getTask()
public java.lang.String getEventType()
null
if not set!
public double getConfidence()
public double getWeight()
public java.lang.String getRationale()
null
if not set!
public java.util.SortedSet<java.lang.String> getUsers()
null
if not set!
public java.util.SortedSet<java.lang.String> getRoles()
null
if not set!
public java.util.SortedSet<java.lang.String> getGroups()
null
if not set!
public java.lang.String toString()
toString
in class java.lang.Object
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int compareTo(Recommendation rec)
equals()
method's results!
compareTo
in interface java.lang.Comparable<Recommendation>
public void addRecomendation(Recommendation r) throws NotEqualRecommendationException
NotEqualRecommendationException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |