com.irs.jam
Class APL

java.lang.Object
  |
  +--com.irs.jam.APL
All Implemented Interfaces:
java.io.Serializable

public class APL
extends java.lang.Object
implements java.io.Serializable

A JAM agent's Applicable Plans List (APL)

See Also:
Serialized Form

Field Summary
protected  DList _intentions
           
 
Constructor Summary
APL(PlanTable pt, WorldModelTable wm, IntentionStructure intentionStructure, int metaLevel)
          Generate an Applicable Plan List (APL) from the plans, current state of the world model, and the goals on the intention structure.
 
Method Summary
protected  APLElement add(Plan p, Goal g, Binding b)
          Append an applicable plan onto the list of possibilities
 APLElement getFirst()
          Retrieve the first applicable plan in the list
 APLElement getRandom()
          Retrieve a random applicable plan in the list
 int getSize()
          Determine the number of applicable plans
 APLElement getUtilityFirst()
          Retrieve the first applicable plan from a list of those with the highest utility
 APLElement getUtilityRandom()
          Retrieve a random applicable plan from a list of those with the highest utility
 void instantiate(Plan plan, Binding planBinding, Goal goal)
          Go through and find all combinations of variable bindings for the plan/goal combination
 APLElement nth(int num)
          Retrieve the nth element in the list
 void print(java.io.PrintStream s)
          Display information about the applicable plans
protected  int randomUniform(int range)
          Return a random number betweeon 0 and the indicated range
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

_intentions

protected DList _intentions
Constructor Detail

APL

public APL(PlanTable pt,
           WorldModelTable wm,
           IntentionStructure intentionStructure,
           int metaLevel)
Generate an Applicable Plan List (APL) from the plans, current state of the world model, and the goals on the intention structure.
Method Detail

add

protected APLElement add(Plan p,
                         Goal g,
                         Binding b)
Append an applicable plan onto the list of possibilities

randomUniform

protected int randomUniform(int range)
Return a random number betweeon 0 and the indicated range

getSize

public int getSize()
Determine the number of applicable plans

getFirst

public APLElement getFirst()
Retrieve the first applicable plan in the list

nth

public APLElement nth(int num)
Retrieve the nth element in the list

getRandom

public APLElement getRandom()
Retrieve a random applicable plan in the list

getUtilityRandom

public APLElement getUtilityRandom()
Retrieve a random applicable plan from a list of those with the highest utility

getUtilityFirst

public APLElement getUtilityFirst()
Retrieve the first applicable plan from a list of those with the highest utility

instantiate

public void instantiate(Plan plan,
                        Binding planBinding,
                        Goal goal)
Go through and find all combinations of variable bindings for the plan/goal combination

print

public void print(java.io.PrintStream s)
Display information about the applicable plans