org.hops.dm.tad
Class plan

java.lang.Object
  extended by org.hops.dm.tad.plan
All Implemented Interfaces:
java.io.Serializable

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

contains a list of actions. It is indexed by the TaskId and his parent is identified with the DepQ (dependent question) DepQ-TaskId is an attribute-value in somewhere in othe plan. Stores also a link to its parent (subplanof). typedef struct { word DepQ; word taskid; stackact actset; plantype type; word subplanof; }plan;

Version:
3.0
Author:
Meritxell Gonzalez
See Also:
Serialized Form

Field Summary
 stackact actset
          stack of actions
 java.lang.String DepQ
          dependent question
 java.lang.String subplanof
          parent plan name
 java.lang.String TaskId
          name of the plan, answer to the DepQ
 plantype type
          type of the plan
 
Constructor Summary
plan()
          Creates a new instance of plan
 
Method Summary
 void clear()
          remove the action stack of this plan
 java.lang.Object clone()
          Creates and returns a copy of this object.
 void copy(plan plansrc)
          becomes a copy of the input plan
 boolean equals(java.lang.Object o)
          Indicates whether some other object is "equal to" this one.
 boolean equalsTo(plan _o)
          Indicates whether a plan is "equal to" this one.
 int hashCode()
           
 boolean is_empty()
          Tests if this object has no values
 boolean is_executable(IS is)
          Test if this plan is not empty but none of its actions can be executables because the conditions are false
 java.lang.String toString()
          Returns a string representation of the object.
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

DepQ

public java.lang.String DepQ
dependent question


TaskId

public java.lang.String TaskId
name of the plan, answer to the DepQ


actset

public stackact actset
stack of actions


type

public plantype type
type of the plan


subplanof

public java.lang.String subplanof
parent plan name

Constructor Detail

plan

public plan()
Creates a new instance of plan

Method Detail

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Indicates whether some other object is "equal to" this one.

Overrides:
equals in class java.lang.Object

equalsTo

public boolean equalsTo(plan _o)
Indicates whether a plan is "equal to" this one.


is_empty

public boolean is_empty()
Tests if this object has no values


clone

public java.lang.Object clone()
Creates and returns a copy of this object.

Overrides:
clone in class java.lang.Object

copy

public void copy(plan plansrc)
becomes a copy of the input plan


toString

public java.lang.String toString()
Returns a string representation of the object.

Overrides:
toString in class java.lang.Object

clear

public void clear()
remove the action stack of this plan


is_executable

public boolean is_executable(IS is)
Test if this plan is not empty but none of its actions can be executables because the conditions are false