Current

There are five kinds of messages needed for the system.

Rule Message
In the beginning of the simulation each of the Industies gets sent the rules.
No message sent. The Industries get the message as parameters from psyclone.

Buy Messages
Buyer sends out this message to the market wich then will respond to the buyer saying if it is able to buy or not.

<Buy
    name="The buyers name same as in type of industry"
    units="How many units(tons) it wants to buy"
    price="The Max price it is willing to pay"

/>

Sell Messages
Seller sends out this message to the market which then will respond to the seller saying if it is able to sell or not.
Each bid is processed in the market where the market holds all of the bids information (Stores Second highest and the highest bid)

<Sell
    name="The sellers name same as in type of industry"
    units"How many units(tons) it is willing to sell"
    price="The Min price it is willing to sell for"

/>

Market Respond Messages
The market sends two kinds of messages: a respond to buyer and respond to seller.
The respond to buyer tells the buyer if he has bought something or not and how much.
The respond to seller tells the seller if he is allowed to sell or if he has sold any and how much.

<buyer
    sendTo="The buyers name same as in type of industry"
    bought="Yes/No"
    units="How many units bought"
    price="What price he paid for the units"

/>

<seller
    sendTo="The sellers name same as in type of industry"
    sold="Yes/No"
    units="How many units sold"
    price="The price it was sold for"

/> </box>