Class ContractNetProtocol

java.lang.Object
com.tnsai.protocols.fipa.ContractNetProtocol
All Implemented Interfaces:
ConversationProtocol

public class ContractNetProtocol extends Object implements ConversationProtocol
FIPA Contract Net Interaction Protocol.

Implements the contract net protocol for task delegation through a bidding process. An initiator issues a CFP (call for proposals) and selects the best proposal.

Protocol Flow

 Initiator                    Participant(s)
     |                            |
     |--- CFP ------------------->| (to all)
     |                            |
     |invalid input: '<'-- PROPOSE ----------------|
     |    or REFUSE               |
     |                            |
     |--- ACCEPT-PROPOSAL ------->| (to winner)
     |--- REJECT-PROPOSAL ------->| (to others)
     |                            |
     |invalid input: '<'-- INFORM/FAILURE ---------|
     |                            |