Examples of UnsupportedOrderType


Examples of com.activequant.exceptions.UnsupportedOrderType

     * @see com.activequant.trading.virtual.IExchange#prepareOrder()
     */
    @Override
    public IOrderTracker prepareOrder(Order order) throws UnsupportedOrderType, IncompleteOrderInstructions {
        if (!(order instanceof LimitOrder))
            throw new UnsupportedOrderType("Order type not supported by exchange: " + order);
        LimitOrder limitOrder = (LimitOrder) order;
        if(limitOrder.getQuantity()<=0.0)
            throw new IncompleteOrderInstructions("Invalid quantity given: " + limitOrder.getQuantity());
        if(limitOrder.getLimitPrice() == null)
            throw new IncompleteOrderInstructions("No limit price given.");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.