ocean.negotiation
Class BuyersAgent
java.lang.Object
|
+--ocean.negotiation.BuyersAgent
- All Implemented Interfaces:
- Agent
- public class BuyersAgent
- extends java.lang.Object
- implements Agent
Implementation of the Agent interface that submits
a BidList to an Auction.
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
BuyersAgent
public BuyersAgent()
setWriter
public void setWriter(OCEANWriter ow)
- Description copied from interface:
Agent
- Set the
OCEANWriter of the agent, for writing output to log files.
- Specified by:
setWriter in interface Agent
FormTradeProposals
protected BidList FormTradeProposals(OCEANDoc doc)
- Form a
BidList from a trade proposal document.
- Parameters:
the - document to parse.- Returns:
- a new list of bids.
createOCEANDoc
public OCEANDoc createOCEANDoc(java.lang.String docContent)
- Create a trade proposal document from string content.
- Specified by:
createOCEANDoc in interface Agent
- Parameters:
the - content of the document.- Returns:
- a newly created proposal document.
SubmitProposalToAuction
public void SubmitProposalToAuction(Auction auc,
OCEANDoc doc,
long to)
- Submit trade proposals in a proposal document to an auction.
- Specified by:
SubmitProposalToAuction in interface Agent
- Parameters:
auc - the auction to which proposals are submitteddoc - the proposal documentto - timeout for the proposals