To learn more about Limit Orders, please read What are Limit orders?

Long/Buy Limit Order
For a long/buy order, if the order price is equal or greater than the best ask price, the order will be filled immediately. The executed price will be the best ask price. If the order price is lower than the best ask price, the order will be added to the order book where it will wait to be filled. When the best ask price drops to the limit order’s price, it will then be filled.
Special Cases
Short/Sell Limit Order
For a short/sell order, if the order price is equal to or lower than the best bid price, the order will be filled immediately. The executed price will be the best bid price. If the order price is greater than the best bid price, the order will be added to the order book where it will wait to be filled. When the best bid price increases to the limit order’s price, it will then be filled.