com.agentfactory.cldc
Class Module

java.lang.Object
  extended by com.agentfactory.cldc.Module

public abstract class Module
extends java.lang.Object

Modules represent an information space that is shared between actuators and perceptors within an agent.

Author:
Conor Muldoon

Constructor Summary
Module(java.lang.Object identifier)
          Creates an instance of Module.
 
Method Summary
abstract  FOS processAction(int actionID, FOS data)
          Enables agents to perform an action on the module.
abstract  FOS processPer(int perceptionID)
          Enables the agent to perceive information within the module.
 void register(java.util.Hashtable table)
          Adds the module to the table using the module ID as the key.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Module

public Module(java.lang.Object identifier)
Creates an instance of Module.

Parameters:
identifier - the ID of the module.
Method Detail

register

public void register(java.util.Hashtable table)
Adds the module to the table using the module ID as the key.

Parameters:
table - the table the module is to be added to.

processPer

public abstract FOS processPer(int perceptionID)
                        throws MalformedLogicException
Enables the agent to perceive information within the module.

Parameters:
perceptionID - the ID of the information that is to be perceived.
Returns:
a first order structure that represents the information that has been perceived in the module.
Throws:
MalformedLogicException - if there is a logic error.

processAction

public abstract FOS processAction(int actionID,
                                  FOS data)
                           throws MalformedLogicException
Enables agents to perform an action on the module.

Parameters:
actionID - the ID of the action that is to be performed.
data - that data that is to be used in performing the action.
Returns:
true if the action was performed successfully, false otherwise.
Throws:
MalformedLogicException - if there is a logic error.