|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This interface implements the RELATE Goal.
Defines the minimum requirements for a RELATE Goal. Provides a mechanism to select from a collection of methods (rules) that affect an Agent's internal state or it's environment. These methods are selected based on the activeRule of a collection of Rules. The method, or action, taken is intended to satisfy the Goal. A feedback mechanism is provided in the assignCredit method to determine the health of the Goal as well as the current active Rule.
Method Summary | |
void |
addRule(Rule pRule)
Adds the passed in Rule to the ruleList Vector. |
void |
assignCredit(SensedEnvironment pPE)
Assigns credit to itself (i.e. |
Rule |
getActiveRule()
Gets the Goal active rule |
java.lang.String |
getGoalName()
Gets the Goal name |
int |
getGoalType()
Gets the Goal type |
Rule |
getPastActiveRule()
Gets the Goal past active rule |
java.util.Vector |
getRuleList()
Returns the ruleList Vector. |
boolean |
removeRule(Rule pRule)
Removes the Rule from the ruleList Vector. |
java.lang.Object |
runActiveRule(SensedEnvironment pPE)
Passes the PerceivedEnvironment to the activeRule in its calculate() method. |
void |
setActiveRule(Rule pRule)
Sets the ActiveRule, used for goal attainment. |
void |
setGoalType(int pType)
Sets the Goals type, the developer should designate specific goal types to be used in the RELATE architecture. |
void |
setPastActiveRule(Rule pRule)
Sets the PastActiveRule, used for comparison and rule weight calculation |
java.lang.String |
toString()
Returns a formated description of this Goal suitable for printing |
Method Detail |
public void addRule(Rule pRule)
public boolean removeRule(Rule pRule)
pRule
- The Rule that is to be removed
public java.util.Vector getRuleList()
public void assignCredit(SensedEnvironment pPE)
pPE
- The agent's perceived environment.public java.lang.Object runActiveRule(SensedEnvironment pPE)
public void setPastActiveRule(Rule pRule)
pRule
- The agent's past active rule.public void setGoalType(int pType)
pType
- Integer representing the goal type.public void setActiveRule(Rule pRule)
pRule
- The agent's active rule.public int getGoalType()
public java.lang.String getGoalName()
public Rule getActiveRule()
public Rule getPastActiveRule()
public java.lang.String toString()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |