@Target(value=TYPE)
@Retention(value=RUNTIME)
public @interface Goal
Goals
annotation to refer to external classes.
Settings of this annotation give detailed control over the means-end reasoning
and goal deliberation processes (see Deliberation
) with regard to the annotated goal.
The means-end reasoning is the process of plan selection and execution and is based
on the notion of an "applicable plans list" (APL). When the goal needs processing,
the agent determines the applicable plans and stores them in the APL.
By default the plans are tried sequentially in the given order.
Several goal flags like randomselection
and posttoall
allow changing this behavior.Modifier and Type | Optional Element and Description |
---|---|
java.lang.Class<?> |
clazz
The goal class, when used inside a
Goals annotation. |
Deliberation |
deliberation
The deliberation settings.
|
MProcessableElement.ExcludeMode |
excludemode
When to exclude a plan from the APL after it has been executed.
|
boolean |
orsuccess
Should a procedural goal succeed when first plan executed successfully
or after all plans have been executed (with at least one passed plan).
|
boolean |
posttoall
Post the goal to all plans of the APL in parallel.
|
Publish |
publish
The publication settings can be used to export goal
as a component service.
|
boolean |
randomselection
Select a plan randomly.
|
boolean |
rebuild
Rebuild the APL on each retry;
|
boolean |
recur
If true (defaults to false), a new round of means-end reasoning is started after each plan execution.
|
long |
recurdelay
The delay (default 0 for no delay) before restarting goal processing if recur is set to true (in milliseconds).
|
boolean |
retry
If true (default) means-end reasoning is allowed to select another plan after a plan has already been executed.
|
long |
retrydelay
The delay between two plan executions (in milliseconds).
|
java.lang.Class<?>[] |
triggergoals
The goal trigger is used in case the goal should be considered as plan for another goal.
|
boolean |
unique
Should the goal be unique (no other goal is allowed that is the same).
|
public abstract java.lang.Class<?> clazz
Goals
annotation.public abstract boolean posttoall
public abstract MProcessableElement.ExcludeMode excludemode
public abstract boolean retry
public abstract boolean recur
public abstract long retrydelay
public abstract long recurdelay
public abstract boolean orsuccess
public abstract boolean unique
public abstract Deliberation deliberation
public abstract Publish publish