|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.irs.jam.Goal
Represents an agent's goals
Field Summary | |
protected Relation |
_concludeRelation
|
protected GoalAction |
_goalAction
|
protected APLElement |
_intention
|
protected IntentionStructure |
_intentionStructure
|
protected int |
_newGoal
|
protected Goal |
_prevGoal
|
protected PlanRuntimeState |
_runtimeState
|
protected int |
_status
|
protected Goal |
_subgoal
|
Constructor Summary | |
Goal(GoalAction ga,
Relation concludeRel,
Goal prev,
IntentionStructure is)
Constructor with the goal specification, conclude relation, parent goal, and intention structure as parameters |
Method Summary | |
int |
clearNew()
|
boolean |
confirmContext()
Verify that the plan's context is valid. |
double |
evalUtility()
This function should be defined in this goal class because it must use the binding of the subgoaling plan, not the candidate plans for this goal. |
int |
execute()
Execute the procedure associated with a plan's BODY specification. |
int |
executeEffects()
Execute the procedure associated with a plan's EFFECTS specification. |
int |
executeFailure()
Execute the procedure associated with a plan's FAILURE specification. |
void |
format(java.io.PrintStream s)
Format output to the given stream so that it can be in-line with other output. |
boolean |
generateAPL()
Check whether the goal should have an Applicable Plan List created for it. |
Relation |
getConcludeRelation()
|
GoalAction |
getGoalAction()
|
Binding |
getGoalBinding()
Get the binding of the goal arguments based upon the parent goal (if it exists). |
APLElement |
getIntention()
|
Binding |
getIntentionBinding()
Get the binding of the goal arguments based upon the plan's goal (if it exists). |
IntentionStructure |
getIntentionStructure()
Return the agent's intention structure |
java.lang.String |
getName()
Return the goal's relation label |
Goal |
getPrevGoal()
|
Relation |
getRelation()
Return the goal specification |
PlanRuntimeState |
getRuntimeState()
|
int |
getStatus()
|
Goal |
getSubgoal()
|
boolean |
isLeafGoal()
|
boolean |
isNew()
|
boolean |
isStackBlocked()
Check to see if the stack in which this goal is part is blocked. |
boolean |
isToplevelGoal()
|
boolean |
isValid()
Return whether the goal is still worth considering. |
boolean |
matchGoal(GoalAction goalAction,
Binding goalActionBinding)
Check whether the goal's specification compares to the parameters |
boolean |
matchRelation(Relation dstRelation,
Binding dstBinding)
Find matches between bound and unbound variables |
void |
print(java.io.PrintStream s)
Format output to the given stream without considering having the output in-line with other output. |
void |
removeIntention(boolean failed)
Remove the goal's intention and all subgoal intentions |
APLElement |
setIntention(APLElement se)
|
int |
setNew()
|
Goal |
setPrevGoal(Goal g)
|
PlanRuntimeState |
setRuntimeState(PlanRuntimeState r)
|
int |
setStatus(int st)
|
Goal |
setSubgoal(Goal g)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
protected GoalAction _goalAction
protected Relation _concludeRelation
protected Goal _subgoal
protected Goal _prevGoal
protected int _newGoal
protected int _status
protected APLElement _intention
protected PlanRuntimeState _runtimeState
protected IntentionStructure _intentionStructure
Constructor Detail |
public Goal(GoalAction ga, Relation concludeRel, Goal prev, IntentionStructure is)
Method Detail |
public boolean isNew()
public boolean isToplevelGoal()
public boolean isLeafGoal()
public GoalAction getGoalAction()
public Relation getConcludeRelation()
public int setNew()
public int clearNew()
public Goal getSubgoal()
public Goal setSubgoal(Goal g)
public Goal getPrevGoal()
public Goal setPrevGoal(Goal g)
public APLElement getIntention()
public APLElement setIntention(APLElement se)
public int getStatus()
public int setStatus(int st)
public PlanRuntimeState getRuntimeState()
public PlanRuntimeState setRuntimeState(PlanRuntimeState r)
public boolean confirmContext()
public int execute()
public int executeFailure()
public int executeEffects()
public java.lang.String getName()
public Relation getRelation()
public boolean generateAPL()
public Binding getGoalBinding()
public Binding getIntentionBinding()
public boolean isValid()
public boolean isStackBlocked()
public double evalUtility()
public boolean matchRelation(Relation dstRelation, Binding dstBinding)
public boolean matchGoal(GoalAction goalAction, Binding goalActionBinding)
public IntentionStructure getIntentionStructure()
public void removeIntention(boolean failed)
public void print(java.io.PrintStream s)
public void format(java.io.PrintStream s)
|
|||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |