<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<!--NewPage-->
<HTML>
<HEAD>
<!-- Generated by javadoc (build 1.6.0_17) on Sun Jan 31 23:53:46 EST 2010 -->
<TITLE>
PlanInstance
</TITLE>
<META NAME="date" CONTENT="2010-01-31">
<LINK REL ="stylesheet" TYPE="text/css" HREF="../../../../../../stylesheet.css" TITLE="Style">
<SCRIPT type="text/javascript">
function windowTitle()
{
if (location.href.indexOf('is-external=true') == -1) {
parent.document.title="PlanInstance";
}
}
</SCRIPT>
<NOSCRIPT>
</NOSCRIPT>
</HEAD>
<BODY BGCOLOR="white" onload="windowTitle();">
<HR>
<!-- ========= START OF TOP NAVBAR ======= -->
<A NAME="navbar_top"><!-- --></A>
<A HREF="#skip-navbar_top" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_top_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/PlanInstance.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanBody.html" title="interface in br.pucrio.inf.les.bdijade.plan"><B>PREV CLASS</B></A>
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../../index.html?br/pucrio/inf/les/bdijade/plan/PlanInstance.html" target="_top"><B>FRAMES</B></A>
<A HREF="PlanInstance.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: <A HREF="#nested_class_summary">NESTED</A> | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_top"></A>
<!-- ========= END OF TOP NAVBAR ========= -->
<HR>
<!-- ======== START OF CLASS DATA ======== -->
<H2>
<FONT SIZE="-1">
br.pucrio.inf.les.bdijade.plan</FONT>
<BR>
Class PlanInstance</H2>
<PRE>
java.lang.Object
<IMG SRC="../../../../../../resources/inherit.gif" ALT="extended by "><B>br.pucrio.inf.les.bdijade.plan.PlanInstance</B>
</PRE>
<DL>
<DT><B>All Implemented Interfaces:</B> <DD><A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html" title="interface in br.pucrio.inf.les.bdijade.event">GoalListener</A>, java.util.EventListener</DD>
</DL>
<HR>
<DL>
<DT><PRE>public class <B>PlanInstance</B><DT>extends java.lang.Object<DT>implements <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html" title="interface in br.pucrio.inf.les.bdijade.event">GoalListener</A></DL>
</PRE>
<P>
This class represents a plan that has been instantiated to be executed, with
an associated plan body (a behavior).
<P>
<P>
<DL>
<DT><B>Author:</B></DT>
<DD>ingrid</DD>
</DL>
<HR>
<P>
<!-- ======== NESTED CLASS SUMMARY ======== -->
<A NAME="nested_class_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Nested Class Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>static class</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan">PlanInstance.EndState</A></B></CODE>
<BR>
This enumuration represents the possible end states of a plan execution.</TD>
</TR>
</TABLE>
<!-- =========== FIELD SUMMARY =========== -->
<A NAME="field_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Field Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private jade.core.behaviours.Behaviour</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#behaviour">behaviour</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan">PlanInstance.EndState</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#endState">endState</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private java.util.List<<A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A>></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#goalEventQueue">goalEventQueue</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/Intention.html" title="class in br.pucrio.inf.les.bdijade.core">Intention</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#intention">intention</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#plan">plan</A></B></CODE>
<BR>
</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private java.util.List<<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A>></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#subgoals">subgoals</A></B></CODE>
<BR>
</TD>
</TR>
</TABLE>
<!-- ======== CONSTRUCTOR SUMMARY ======== -->
<A NAME="constructor_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Constructor Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#PlanInstance(br.pucrio.inf.les.bdijade.plan.Plan, br.pucrio.inf.les.bdijade.core.Intention)">PlanInstance</A></B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A> plan,
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/Intention.html" title="class in br.pucrio.inf.les.bdijade.core">Intention</A> intention)</CODE>
<BR>
Creates a new plan instance.</TD>
</TR>
</TABLE>
<!-- ========== METHOD SUMMARY =========== -->
<A NAME="method_summary"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="2"><FONT SIZE="+2">
<B>Method Summary</B></FONT></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#dispatchGoal(br.pucrio.inf.les.bdijade.goal.Goal)">dispatchGoal</A></B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> goal)</CODE>
<BR>
Dispatches a goal to be achieved.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#dispatchSubgoal(br.pucrio.inf.les.bdijade.goal.Goal)">dispatchSubgoal</A></B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> subgoal)</CODE>
<BR>
Dispatches a subgoal to be achieved.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#dispatchSubgoalAndListen(br.pucrio.inf.les.bdijade.goal.Goal)">dispatchSubgoalAndListen</A></B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> subgoal)</CODE>
<BR>
Dispatches a subgoal to be achieved and registers itself as a listener to
receive a notification of the end of execution of the goal.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#dropSubgoals()">dropSubgoals</A></B>()</CODE>
<BR>
Drops all current subgoals dispatched by this plan.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/BeliefBase.html" title="class in br.pucrio.inf.les.bdijade.core">BeliefBase</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getBeliefBase()">getBeliefBase</A></B>()</CODE>
<BR>
Returns the belief base of the capability.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan">PlanInstance.EndState</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getEndState()">getEndState</A></B>()</CODE>
<BR>
Returns the end state of plan.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getGoal()">getGoal</A></B>()</CODE>
<BR>
Returns the goal to be achieved by this plan instance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getGoalEvent()">getGoalEvent</A></B>()</CODE>
<BR>
Returns a goal event from the queue.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getGoalEvent(boolean)">getGoalEvent</A></B>(boolean block)</CODE>
<BR>
Returns a goal event from the queue.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE>private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getGoalEvent(boolean, long)">getGoalEvent</A></B>(boolean block,
long ms)</CODE>
<BR>
Returns a goal event from the queue.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getGoalEvent(long)">getGoalEvent</A></B>(long ms)</CODE>
<BR>
Returns a goal event from the queue.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A></CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#getPlan()">getPlan</A></B>()</CODE>
<BR>
Returns the <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan"><CODE>Plan</CODE></A> that is associated with this plan instance.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)">goalPerformed</A></B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalEvent</A> event)</CODE>
<BR>
Notifies the listener that the goal was performed.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#startPlan()">startPlan</A></B>()</CODE>
<BR>
Starts the plan body, a <CODE>Behaviour</CODE>, associated with this plan.</TD>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1">
<CODE> void</CODE></FONT></TD>
<TD><CODE><B><A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.html#stopPlan()">stopPlan</A></B>()</CODE>
<BR>
Stops the plan body, a <CODE>Behaviour</CODE>, associated with this plan.</TD>
</TR>
</TABLE>
<A NAME="methods_inherited_from_class_java.lang.Object"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#EEEEFF" CLASS="TableSubHeadingColor">
<TH ALIGN="left"><B>Methods inherited from class java.lang.Object</B></TH>
</TR>
<TR BGCOLOR="white" CLASS="TableRowColor">
<TD><CODE>clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait</CODE></TD>
</TR>
</TABLE>
<P>
<!-- ============ FIELD DETAIL =========== -->
<A NAME="field_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Field Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="behaviour"><!-- --></A><H3>
behaviour</H3>
<PRE>
private final jade.core.behaviours.Behaviour <B>behaviour</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="endState"><!-- --></A><H3>
endState</H3>
<PRE>
private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan">PlanInstance.EndState</A> <B>endState</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="goalEventQueue"><!-- --></A><H3>
goalEventQueue</H3>
<PRE>
private final java.util.List<<A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A>> <B>goalEventQueue</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="intention"><!-- --></A><H3>
intention</H3>
<PRE>
private final <A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/Intention.html" title="class in br.pucrio.inf.les.bdijade.core">Intention</A> <B>intention</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="plan"><!-- --></A><H3>
plan</H3>
<PRE>
private final <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A> <B>plan</B></PRE>
<DL>
<DL>
</DL>
</DL>
<HR>
<A NAME="subgoals"><!-- --></A><H3>
subgoals</H3>
<PRE>
private final java.util.List<<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A>> <B>subgoals</B></PRE>
<DL>
<DL>
</DL>
</DL>
<!-- ========= CONSTRUCTOR DETAIL ======== -->
<A NAME="constructor_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Constructor Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="PlanInstance(br.pucrio.inf.les.bdijade.plan.Plan, br.pucrio.inf.les.bdijade.core.Intention)"><!-- --></A><H3>
PlanInstance</H3>
<PRE>
public <B>PlanInstance</B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A> plan,
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/Intention.html" title="class in br.pucrio.inf.les.bdijade.core">Intention</A> intention)
throws <A HREF="../../../../../../br/pucrio/inf/les/bdijade/exception/PlanInstantiationException.html" title="class in br.pucrio.inf.les.bdijade.exception">PlanInstantiationException</A></PRE>
<DL>
<DD>Creates a new plan instance. It is associated with a plan definition (
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan"><CODE>Plan</CODE></A>) and an <A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/Intention.html" title="class in br.pucrio.inf.les.bdijade.core"><CODE>Intention</CODE></A>. It creates an instance of the
plan body defined in the plan and throws an exception if an error occurs
in this process.
<P>
<DL>
<DT><B>Parameters:</B><DD><CODE>plan</CODE> - the plan associated this this plan instance.<DD><CODE>intention</CODE> - the intention that this plan instance have to achieve.
<DT><B>Throws:</B>
<DD><CODE>PlanBodyInstantiationException</CODE> - in an error occurred during the instantiation.
<DD><CODE><A HREF="../../../../../../br/pucrio/inf/les/bdijade/exception/PlanInstantiationException.html" title="class in br.pucrio.inf.les.bdijade.exception">PlanInstantiationException</A></CODE></DL>
</DL>
<!-- ============ METHOD DETAIL ========== -->
<A NAME="method_detail"><!-- --></A>
<TABLE BORDER="1" WIDTH="100%" CELLPADDING="3" CELLSPACING="0" SUMMARY="">
<TR BGCOLOR="#CCCCFF" CLASS="TableHeadingColor">
<TH ALIGN="left" COLSPAN="1"><FONT SIZE="+2">
<B>Method Detail</B></FONT></TH>
</TR>
</TABLE>
<A NAME="dispatchGoal(br.pucrio.inf.les.bdijade.goal.Goal)"><!-- --></A><H3>
dispatchGoal</H3>
<PRE>
public void <B>dispatchGoal</B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> goal)</PRE>
<DL>
<DD>Dispatches a goal to be achieved.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>goal</CODE> - the goal to be dispatched.</DL>
</DD>
</DL>
<HR>
<A NAME="dispatchSubgoal(br.pucrio.inf.les.bdijade.goal.Goal)"><!-- --></A><H3>
dispatchSubgoal</H3>
<PRE>
public void <B>dispatchSubgoal</B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> subgoal)</PRE>
<DL>
<DD>Dispatches a subgoal to be achieved.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>subgoal</CODE> - the subgoal to be dispatched.</DL>
</DD>
</DL>
<HR>
<A NAME="dispatchSubgoalAndListen(br.pucrio.inf.les.bdijade.goal.Goal)"><!-- --></A><H3>
dispatchSubgoalAndListen</H3>
<PRE>
public void <B>dispatchSubgoalAndListen</B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> subgoal)</PRE>
<DL>
<DD>Dispatches a subgoal to be achieved and registers itself as a listener to
receive a notification of the end of execution of the goal.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>subgoal</CODE> - the subgoal to be dispatched.</DL>
</DD>
</DL>
<HR>
<A NAME="dropSubgoals()"><!-- --></A><H3>
dropSubgoals</H3>
<PRE>
private void <B>dropSubgoals</B>()</PRE>
<DL>
<DD>Drops all current subgoals dispatched by this plan.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="getBeliefBase()"><!-- --></A><H3>
getBeliefBase</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/core/BeliefBase.html" title="class in br.pucrio.inf.les.bdijade.core">BeliefBase</A> <B>getBeliefBase</B>()</PRE>
<DL>
<DD>Returns the belief base of the capability.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the belief base containing the beliefs.</DL>
</DD>
</DL>
<HR>
<A NAME="getEndState()"><!-- --></A><H3>
getEndState</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan">PlanInstance.EndState</A> <B>getEndState</B>()</PRE>
<DL>
<DD>Returns the end state of plan. A null value means that the plan is still
in execution. If the plan body has come to a successful end state, it
invokes the method to set the output parameters of the goal, in case the
plan body implements the <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/OutputPlanBody.html" title="interface in br.pucrio.inf.les.bdijade.plan"><CODE>OutputPlanBody</CODE></A> interface (this is
invoked only once). If the plan body has come to a failed state, it sets
all of its subgoals as no longer desired.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the end state of the plan.</DL>
</DD>
</DL>
<HR>
<A NAME="getGoal()"><!-- --></A><H3>
getGoal</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/goal/Goal.html" title="interface in br.pucrio.inf.les.bdijade.goal">Goal</A> <B>getGoal</B>()</PRE>
<DL>
<DD>Returns the goal to be achieved by this plan instance.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the goal.</DL>
</DD>
</DL>
<HR>
<A NAME="getGoalEvent()"><!-- --></A><H3>
getGoalEvent</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A> <B>getGoalEvent</B>()</PRE>
<DL>
<DD>Returns a goal event from the queue. If the queue is empty, the behavior
associated with this plan instance is blocked.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the goal event or null if the queue is empty.</DL>
</DD>
</DL>
<HR>
<A NAME="getGoalEvent(boolean)"><!-- --></A><H3>
getGoalEvent</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A> <B>getGoalEvent</B>(boolean block)</PRE>
<DL>
<DD>Returns a goal event from the queue. If the queue is empty, the behavior
associated with this plan instance is going to be blocked if the
parameter passed to this method is true.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>block</CODE> - true if the behavior must be blocked if the queue is empty.
<DT><B>Returns:</B><DD>the goal event or null if the queue is empty.</DL>
</DD>
</DL>
<HR>
<A NAME="getGoalEvent(boolean, long)"><!-- --></A><H3>
getGoalEvent</H3>
<PRE>
private <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A> <B>getGoalEvent</B>(boolean block,
long ms)</PRE>
<DL>
<DD>Returns a goal event from the queue. If the block parameter is true, the
behavior associated with this plan instance is going to be blocked if the
queue is empty according to the specified milliseconds. specified
milliseconds. If the time is lower then zero, the behavior is going to be
blocked until an event happens (<CODE>Behaviour.block()</CODE>).
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>block</CODE> - true if the behavior must be blocked if the queue is empty.<DD><CODE>ms</CODE> - the maximum amount of time that the behavior must be blocked.
<DT><B>Returns:</B><DD>the goal event or null if the queue is empty.</DL>
</DD>
</DL>
<HR>
<A NAME="getGoalEvent(long)"><!-- --></A><H3>
getGoalEvent</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalFinishedEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalFinishedEvent</A> <B>getGoalEvent</B>(long ms)</PRE>
<DL>
<DD>Returns a goal event from the queue. If the queue is empty, the behavior
associated with this plan instance is going to be blocked for the
specified milliseconds.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>ms</CODE> - the maximum amount of time that the behavior must be blocked.
<DT><B>Returns:</B><DD>the goal event or null if the queue is empty.</DL>
</DD>
</DL>
<HR>
<A NAME="getPlan()"><!-- --></A><H3>
getPlan</H3>
<PRE>
public <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan">Plan</A> <B>getPlan</B>()</PRE>
<DL>
<DD>Returns the <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/Plan.html" title="class in br.pucrio.inf.les.bdijade.plan"><CODE>Plan</CODE></A> that is associated with this plan instance.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
<DT><B>Returns:</B><DD>the plan.</DL>
</DD>
</DL>
<HR>
<A NAME="goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)"><!-- --></A><H3>
goalPerformed</H3>
<PRE>
public void <B>goalPerformed</B>(<A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalEvent.html" title="class in br.pucrio.inf.les.bdijade.event">GoalEvent</A> event)</PRE>
<DL>
<DD><B>Description copied from interface: <CODE><A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html#goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)">GoalListener</A></CODE></B></DD>
<DD>Notifies the listener that the goal was performed.
<P>
<DD><DL>
<DT><B>Specified by:</B><DD><CODE><A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html#goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)">goalPerformed</A></CODE> in interface <CODE><A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html" title="interface in br.pucrio.inf.les.bdijade.event">GoalListener</A></CODE></DL>
</DD>
<DD><DL>
<DT><B>Parameters:</B><DD><CODE>event</CODE> - the performed goal event.<DT><B>See Also:</B><DD><A HREF="../../../../../../br/pucrio/inf/les/bdijade/event/GoalListener.html#goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)"><CODE>GoalListener.goalPerformed(br.pucrio.inf.les.bdijade.event.GoalEvent)</CODE></A></DL>
</DD>
</DL>
<HR>
<A NAME="startPlan()"><!-- --></A><H3>
startPlan</H3>
<PRE>
public void <B>startPlan</B>()</PRE>
<DL>
<DD>Starts the plan body, a <CODE>Behaviour</CODE>, associated with this plan.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<HR>
<A NAME="stopPlan()"><!-- --></A><H3>
stopPlan</H3>
<PRE>
public void <B>stopPlan</B>()</PRE>
<DL>
<DD>Stops the plan body, a <CODE>Behaviour</CODE>, associated with this plan. If
the body implements the <A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/DisposablePlanBody.html" title="interface in br.pucrio.inf.les.bdijade.plan"><CODE>DisposablePlanBody</CODE></A>, it invokes the method
to about the plan body, so it can perform finalizations.
<P>
<DD><DL>
</DL>
</DD>
<DD><DL>
</DL>
</DD>
</DL>
<!-- ========= END OF CLASS DATA ========= -->
<HR>
<!-- ======= START OF BOTTOM NAVBAR ====== -->
<A NAME="navbar_bottom"><!-- --></A>
<A HREF="#skip-navbar_bottom" title="Skip navigation links"></A>
<TABLE BORDER="0" WIDTH="100%" CELLPADDING="1" CELLSPACING="0" SUMMARY="">
<TR>
<TD COLSPAN=2 BGCOLOR="#EEEEFF" CLASS="NavBarCell1">
<A NAME="navbar_bottom_firstrow"><!-- --></A>
<TABLE BORDER="0" CELLPADDING="0" CELLSPACING="3" SUMMARY="">
<TR ALIGN="center" VALIGN="top">
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../overview-summary.html"><FONT CLASS="NavBarFont1"><B>Overview</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-summary.html"><FONT CLASS="NavBarFont1"><B>Package</B></FONT></A> </TD>
<TD BGCOLOR="#FFFFFF" CLASS="NavBarCell1Rev"> <FONT CLASS="NavBarFont1Rev"><B>Class</B></FONT> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="class-use/PlanInstance.html"><FONT CLASS="NavBarFont1"><B>Use</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="package-tree.html"><FONT CLASS="NavBarFont1"><B>Tree</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../deprecated-list.html"><FONT CLASS="NavBarFont1"><B>Deprecated</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../index-files/index-1.html"><FONT CLASS="NavBarFont1"><B>Index</B></FONT></A> </TD>
<TD BGCOLOR="#EEEEFF" CLASS="NavBarCell1"> <A HREF="../../../../../../help-doc.html"><FONT CLASS="NavBarFont1"><B>Help</B></FONT></A> </TD>
</TR>
</TABLE>
</TD>
<TD ALIGN="right" VALIGN="top" ROWSPAN=3><EM>
</EM>
</TD>
</TR>
<TR>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanBody.html" title="interface in br.pucrio.inf.les.bdijade.plan"><B>PREV CLASS</B></A>
<A HREF="../../../../../../br/pucrio/inf/les/bdijade/plan/PlanInstance.EndState.html" title="enum in br.pucrio.inf.les.bdijade.plan"><B>NEXT CLASS</B></A></FONT></TD>
<TD BGCOLOR="white" CLASS="NavBarCell2"><FONT SIZE="-2">
<A HREF="../../../../../../index.html?br/pucrio/inf/les/bdijade/plan/PlanInstance.html" target="_top"><B>FRAMES</B></A>
<A HREF="PlanInstance.html" target="_top"><B>NO FRAMES</B></A>
<SCRIPT type="text/javascript">
<!--
if(window==top) {
document.writeln('<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>');
}
//-->
</SCRIPT>
<NOSCRIPT>
<A HREF="../../../../../../allclasses-noframe.html"><B>All Classes</B></A>
</NOSCRIPT>
</FONT></TD>
</TR>
<TR>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
SUMMARY: <A HREF="#nested_class_summary">NESTED</A> | <A HREF="#field_summary">FIELD</A> | <A HREF="#constructor_summary">CONSTR</A> | <A HREF="#method_summary">METHOD</A></FONT></TD>
<TD VALIGN="top" CLASS="NavBarCell3"><FONT SIZE="-2">
DETAIL: <A HREF="#field_detail">FIELD</A> | <A HREF="#constructor_detail">CONSTR</A> | <A HREF="#method_detail">METHOD</A></FONT></TD>
</TR>
</TABLE>
<A NAME="skip-navbar_bottom"></A>
<!-- ======== END OF BOTTOM NAVBAR ======= -->
<HR>
</BODY>
</HTML>