fipaos.platform.df
Class SubscriptionHandlerTask

java.lang.Object
  |
  +--fipaos.agent.task.Task
        |
        +--fipaos.platform.df.SubscriptionHandlerTask

public class SubscriptionHandlerTask
extends Task

This Task provides a mechanism for informing subscribed Agents about the something that has changed within the DF - DFListenerTask is the counterpart to this Task.

Currently this Task (and its counterpart) only support intra-platform communication over a transport which maintains message content as objects (i.e. RMI).


Fields inherited from class fipaos.agent.task.Task
_children, _lock, _owner, _tm
 
Constructor Summary
SubscriptionHandlerTask(Conversation conv)
          Creates a SubscribeAction - once the Task has started, it will attempt to "agree" and "inform" the subscribing Agent that the subscription has been started OK
 
Method Summary
 void handleCancel(Conversation conv)
          Invoked when agree messages are received - generally indicates that DF will allow us to subscribe
 void handleNotUnderstood(Conversation conv)
          Deal with not-understood messages here
 void startTask()
          Invoked when the Task starts - sends subscription message to target DF
 
Methods inherited from class fipaos.agent.task.Task
DFSearchResults, done, done, doneDFSearchTask, errorDFSearchTask, forward, forward, getContext, getNewConversation, getState, handleAcceptProposal, handleAgree, handleCfp, handleConfirm, handleDisconfirm, handleFailure, handleInform, handleInformIf, handleInformRef, handleLateMessage, handleOther, handlePropagate, handlePropose, handleProxy, handleQueryIf, handleQueryRef, handleRefuse, handleRejectProposal, handleRequest, handleRequestWhen, handleRequestWhenever, handleSubscribe, handleUndeliverableMessage, newTask, newTask, newTask, newTask, newTask, newTask, newTask, newTask, notify, notifyDone, notifyError, notifyMessageFailure, notifyMessageForEndedConversation, notifyTimeout, searchDF, searchDF, searchDF, searchDF, searchDF, sendNotUnderstood, setContext, timeoutDFSearchTask
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SubscriptionHandlerTask

public SubscriptionHandlerTask(Conversation conv)
Creates a SubscribeAction - once the Task has started, it will attempt to "agree" and "inform" the subscribing Agent that the subscription has been started OK
Parameters:
conv - Conversation associated with this subscription
Method Detail

startTask

public void startTask()
Invoked when the Task starts - sends subscription message to target DF
Overrides:
startTask in class Task

handleCancel

public void handleCancel(Conversation conv)
Invoked when agree messages are received - generally indicates that DF will allow us to subscribe
Parameters:
conv - The subscription conversation

handleNotUnderstood

public void handleNotUnderstood(Conversation conv)
Deal with not-understood messages here
Overrides:
handleNotUnderstood in class Task