|
Jadex 0.96-beta1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjadex.runtime.AbstractPlan
public abstract class AbstractPlan
The abstract plan is the abstract superclass for standard plans and mobile plans.
Constructor Summary | |
---|---|
AbstractPlan()
Create a new plan. |
Method Summary | |
---|---|
void |
addPlanListener(IPlanListener listener,
boolean async)
Add a plan listener. |
ICondition |
createCondition(String expression)
Create a condition, that is triggered whenever the expression value changes to true. |
ICondition |
createCondition(String expression,
String trigger,
String[] paramnames,
Class[] paramtypes)
Create a condition. |
IExpression |
createExpression(String expression)
Create a precompiled expression. |
IExpression |
createExpression(String expression,
String[] paramnames,
Class[] paramtypes)
Create a precompiled expression. |
IGoal |
createGoal(String type)
Create a goal from a template goal. |
IInternalEvent |
createInternalEvent(String type)
Create a new intenal event. |
IInternalEvent |
createInternalEvent(String type,
Object content)
Deprecated. Convenience method for easy conversion to new explicit internal events. Will be removed in later releases. |
IMessageEvent |
createMessageEvent(String type)
Create a new message event. |
IExpression |
createQuery(String query)
Deprecated. Use @link{#createExpression(String)} instead. |
void |
dispatchInternalEvent(IInternalEvent event)
Dispatch an internal event. |
IFilter |
dispatchSubgoal(IGoal subgoal)
Dispatch a new subgoal. |
void |
dispatchTopLevelGoal(IGoal goal)
Dispatch a new top-level goal. |
void |
endAtomic()
End an atomic transaction. |
void |
fail()
Let a plan fail. |
void |
fail(String message,
Throwable cause)
Let a plan fail. |
void |
fail(Throwable cause)
Let a plan fail. |
BasicAgentIdentifier |
getAgentIdentifier()
Get the agent identifier. |
String |
getAgentName()
Get the agent name. |
IBeliefbase |
getBeliefbase()
Get the belief base. |
ICondition |
getCondition(String name)
Get a condition predefined in the ADF. |
IEventbase |
getEventbase()
Get the event base. |
Exception |
getException()
Get the uncatched exception that occurred in the body (if any). |
IExpression |
getExpression(String name)
Get an instance of a predefined expression. |
IExpressionbase |
getExpressionbase()
Get the expression base. |
IExternalAccess |
getExternalAccess()
Get the scope. |
IGoalbase |
getGoalbase()
Get the goal base. |
Logger |
getLogger()
Get the logger. |
String |
getName()
Get the name. |
IParameter |
getParameter(String name)
Get a parameter. |
IParameter[] |
getParameters()
Get all parameters. |
IParameterSet |
getParameterSet(String name)
Get a parameter. |
IParameterSet[] |
getParameterSets()
Get all parameter sets. |
IPlanbase |
getPlanbase()
Get the plan base. |
IPropertybase |
getPropertybase()
Get the property base. |
IExpression |
getQuery(String name)
Deprecated. Use @link{#getExpression(String)} instead. |
IProcessGoal |
getRootGoal()
Deprecated. |
jadex.runtime.impl.RPlan |
getRPlan()
Get the plan instance info. |
ICapability |
getScope()
Get the scope. |
IWaitqueue |
getWaitqueue()
Get the waitqueue. |
boolean |
hasParameter(String name)
Has the element a parameter element. |
boolean |
hasParameterSet(String name)
Has the element a parameter set element. |
boolean |
isAbortedOnSuccess()
Check if the corresponding plan was aborted because the proprietary goal succeeded during the plan was running. |
void |
killAgent()
Kill this agent. |
void |
removePlanListener(IPlanListener listener)
Remove a plan listener. |
IFilter |
sendMessage(IMessageEvent me)
Send a message after some delay. |
void |
startAtomic()
Start an atomic transaction. |
String |
toString()
Get the string representation. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public AbstractPlan()
Method Detail |
---|
public void fail()
public void fail(Throwable cause)
cause
- The cause.public void fail(String message, Throwable cause)
message
- The message.cause
- The cause.public ICapability getScope()
public Logger getLogger()
public void startAtomic()
endAtomic()
public void endAtomic()
startAtomic()
public IFilter dispatchSubgoal(IGoal subgoal)
subgoal
- The new subgoal.
public String getName()
public IProcessGoal getRootGoal()
public IWaitqueue getWaitqueue()
public String toString()
toString
in class Object
public String getAgentName()
public BasicAgentIdentifier getAgentIdentifier()
public boolean isAbortedOnSuccess()
public Exception getException()
public void killAgent()
public IBeliefbase getBeliefbase()
public IGoalbase getGoalbase()
public IPlanbase getPlanbase()
public IEventbase getEventbase()
public IExpressionbase getExpressionbase()
public IPropertybase getPropertybase()
public void dispatchTopLevelGoal(IGoal goal)
goal
- The new goal.
Note: plan step is interrupted after call.public IGoal createGoal(String type)
type
- The template goal name as specified in the ADF.
public IFilter sendMessage(IMessageEvent me)
me
- The message event.
public void dispatchInternalEvent(IInternalEvent event)
event
- The event.
Note: plan step is interrupted after call.public IMessageEvent createMessageEvent(String type)
public IInternalEvent createInternalEvent(String type)
public IInternalEvent createInternalEvent(String type, Object content)
public IExternalAccess getExternalAccess()
public IExpression getQuery(String name)
name
- The name of an expression defined in the ADF.
public IExpression getExpression(String name)
name
- The name of an expression defined in the ADF.
public ICondition getCondition(String name)
name
- The name of a condition defined in the ADF.
public IExpression createQuery(String query)
query
- The query string.
public IExpression createExpression(String expression)
expression
- The expression string.
public IExpression createExpression(String expression, String[] paramnames, Class[] paramtypes)
expression
- The expression string.
public ICondition createCondition(String expression)
expression
- The condition expression.
public ICondition createCondition(String expression, String trigger, String[] paramnames, Class[] paramtypes)
expression
- The condition expression.trigger
- The condition trigger.
public IParameter[] getParameters()
public IParameterSet[] getParameterSets()
public IParameter getParameter(String name)
name
- The name.
public IParameterSet getParameterSet(String name)
name
- The name.
public boolean hasParameter(String name)
name
- The name.
public boolean hasParameterSet(String name)
name
- The name.
public jadex.runtime.impl.RPlan getRPlan()
public void addPlanListener(IPlanListener listener, boolean async)
listener
- The plan listener.async
- True, if the notification should be done on a separate thread.public void removePlanListener(IPlanListener listener)
listener
- The plan listener.
|
Jadex 0.96-beta1 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright (C) 2002-2007 Lars Braubach, Alexander Pokahr - University of Hamburg. Use is subject to license terms.