|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--ciagent.CIAgent | +--marketplace.BuyerAgent | +--marketplace.BetterBuyerAgent
The BetterBuyerAgent
class implements a buyer agent that
uses hard-coded logic when negotiating.
Fields inherited from class marketplace.BuyerAgent |
current,
inventory,
msg,
negotiations,
pending,
totalSpent,
wishList |
Fields inherited from class ciagent.CIAgent |
agentPlatform,
children,
DEFAULT_ASYNCTIME,
DEFAULT_SLEEPTIME,
name,
parent,
traceLevel |
Constructor Summary | |
BetterBuyerAgent()
Creates a BetterBuyerAgent object. |
|
BetterBuyerAgent(java.lang.String name)
Creates a BetterBuyerAgent object with the given name. |
Method Summary | |
(package private) void |
negotiate(Offer offer,
BuySellMessage msg)
Negotiates by accepting an offer if it is less than the current strike price or making a counter offer that is $50 less than the most recent offer. |
Methods inherited from class marketplace.BuyerAgent |
getTaskDescription,
initialize,
process,
processCIAgentEvent,
processMessage,
processTimerPop |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public BetterBuyerAgent()
BetterBuyerAgent
object.public BetterBuyerAgent(java.lang.String name)
BetterBuyerAgent
object with the given name.name
- the String object that contains the name of the agentMethod Detail |
void negotiate(Offer offer, BuySellMessage msg)
offer
- the Offer object that contains the current offermsg
- the BuySellMessage object
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |