Futures Exchanges, I guess I know something about this.
In terms of Fill Priority, what Black Diamond described is called the FIFO (first-in-first-out) matching Algorithm. But a lot Futures products such as the EuroDollar and Treasury complex uses the Pro-Rata matching algorithm, which is essentially a first-price, then *size"-oriented allocation of the first FIFO "window". I will let the official CME description do the explanation.
http://www.cme.com/trading/get/abt/functionality/allocation.html
and FIFO
http://www.cme.com/trading/get/abt/functionality/fifo.html
Also, when the OP asked for a 10 contract trade at 99.00, where it is filled first a 5 contract, then a second contract, and some1 replied there will be two trade message in the raw tick. The real answer is, "not necessarily".
Yes, *in absence* of other fills at the same time, there will be 2 trade messages (in CME Globex, under RLC, these would be M6 messages). However, if there are other trades in 99.00 at the same time, this will NOT be the case, see the CME document on "M6 Message Compression":
http://www.cme.com/files/SDKMDPCore.pdf
Basically, *IF* the first 5 contract trade is the 1st order in the matching queue, then it will be disseminated, and then *IF* there are no other trades at 99.00, the 2nd trade message will be send out, otherwise, it will be grouped.
Let's say your 10 contract trade is still a 5-5 fill sequence, but there is a 100 contract fill immediately after (at the same time). The trade message sent out by Globex (or LIFFE or Eurex, they all behave pretty much the same) will be:
5 at 99.00
105 at 99.00
Oh, ALL of the above assumes you have access to the RAW exchange feeds (Globex, LIFFE Connect, etc). there are only a handful of brokers and vendors that does not filter the raw ticks from the exchange, and forward it to the clients.
Quote from black diamond:
They use first price and then time priority rules to match incoming orders with resting orders in the book. If the incoming order is a market order or a limit order that can trade immediately, it trades with the opposite order in the book at the best price. If there is more than one order at the best price, the one that was there first gets the fill. If the incoming order is a limit order and can't be matched, it goes into the book behind resting orders at that price that were there first.