jadex.micro.examples
Class CountingAgent

java.lang.Object
  extended by jadex.micro.MicroAgent
      extended by jadex.micro.examples.CountingAgent
All Implemented Interfaces:
IInternalAccess, IMicroAgent

public class CountingAgent
extends MicroAgent

An agent that is counting to infinity. Used to demonstrate "semantic" breakpoints.


Nested Class Summary
 
Nested classes/interfaces inherited from class jadex.micro.MicroAgent
MicroAgent.TimerWrapper
 
Field Summary
protected  int cnt
          The counter.
 
Fields inherited from class jadex.micro.MicroAgent
interpreter, longtime, timers
 
Constructor Summary
CountingAgent()
           
 
Method Summary
 void executeBody()
          Execute a series of steps.
static Object getMetaInfo()
          Add the 'testresults' marking this agent as a testcase.
 boolean isAtBreakpoint(String[] breakpoints)
          Return true, when a breakpoint was hit.
 
Methods inherited from class jadex.micro.MicroAgent
addComponentListener, addDirectService, addService, agentCreated, agentKilled, createComponentIdentifier, createComponentIdentifier, createComponentIdentifier, createReply, createResultListener, createServiceContainer, getAgentAdapter, getAgentName, getArgument, getArguments, getChildren, getComponentIdentifier, getConfiguration, getExternalAccess, getLogger, getModel, getParent, getServiceProvider, getTime, init, killAgent, killComponent, messageArrived, removeComponentListener, removeService, scheduleStep, sendMessage, setResultValue, waitFor, waitForTick
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cnt

protected int cnt
The counter.

Constructor Detail

CountingAgent

public CountingAgent()
Method Detail

executeBody

public void executeBody()
Execute a series of steps.

Specified by:
executeBody in interface IMicroAgent
Overrides:
executeBody in class MicroAgent

isAtBreakpoint

public boolean isAtBreakpoint(String[] breakpoints)
Return true, when a breakpoint was hit.

Overrides:
isAtBreakpoint in class MicroAgent

getMetaInfo

public static Object getMetaInfo()
Add the 'testresults' marking this agent as a testcase.



Copyright © 2010. All Rights Reserved.