madkit.kernel
Class Watcher

java.lang.Object
  extended by madkit.kernel.AbstractAgent
      extended by madkit.kernel.Watcher
All Implemented Interfaces:
java.io.Serializable
Direct Known Subclasses:
BeeEnvironment, BeeWorldViewer, DebugViewer, MapViewer, Observer

public abstract class Watcher
extends AbstractAgent

This class defines a generic watcher agent. It holds a collection of probes to explore agents' internal properties.

Since:
MadKit 2.0
Version:
3.0
Author:
Fabien Michel (MadKit 3.0 05/09/01) and 2.0 (Overlooker)., Olivier Gutknecht version 1.0
See Also:
Serialized Form

Constructor Summary
Watcher()
           
 
Method Summary
 void addProbe(Probe p)
           
 void addProbe(Probe p, java.lang.Object accessCard)
           
 void end()
          This method is called by the agent micro-kernel at the end of the agent lifecycle.
 Probe[] getProbes()
           
 void removeAllProbes()
           
 void removeProbe(Probe p)
           
 void update()
          Deprecated. since MadKit 2.1 : update is now useless as the Probe's agents variable is updated automatically
 
Methods inherited from class madkit.kernel.AbstractAgent
activate, broadcastMessage, broadcastMessage, connectedWithCommunity, createGroup, createGroup, debug, disposeMyGUI, foundGroup, getAddress, getAgentInformation, getAgentsWithRole, getAgentsWithRole, getAgentWithRole, getAgentWithRole, getAvailableCommunities, getBean, getController, getCurrentKernelAddress, getDebug, getExistingGroups, getExistingGroups, getExistingRoles, getExistingRoles, getGroups, getGUIObject, getMessageBoxSize, getMyGroups, getMyGroups, getMyRoles, getMyRoles, getName, getRoles, hasGUI, initGUI, isBelongingToGroup, isBelongingToGroup, isCommunity, isGroup, isGroup, isMemberOf, isMemberOf, isMessageBoxEmpty, isRole, isRole, joinGroup, killAgent, launchAgent, launchAgent, leaveGroup, leaveGroup, leaveRole, leaveRole, nextMessage, print, println, receiveMessage, redisplayMyGUI, requestRole, requestRole, requestRole, restoreAgent, sendMessage, sendMessage, sendMessage, setBean, setController, setDebug, setGUIObject, setName, setOutput, setOutputWriter, windowClosing
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Watcher

public Watcher()
Method Detail

addProbe

public final void addProbe(Probe p)

addProbe

public final void addProbe(Probe p,
                           java.lang.Object accessCard)

removeProbe

public final void removeProbe(Probe p)

getProbes

public final Probe[] getProbes()

removeAllProbes

public final void removeAllProbes()

end

public void end()
Description copied from class: AbstractAgent
This method is called by the agent micro-kernel at the end of the agent lifecycle. If the the agent is killed from the outside, it is the last opportunity for the agent to cleanly shutdown its operations.

Overrides:
end in class AbstractAgent

update

public void update()
Deprecated. since MadKit 2.1 : update is now useless as the Probe's agents variable is updated automatically



Copyright © Madkit Team (O. Gutknecht, J. Ferber, F. Michel et al.) All Rights Reserved.