gotrade: Index | Files

package orderbook

import ""

A simulated order book bid offer matching by bloomberg pricefeed quotes

this is to give our sell side FIX engine simulate a false feel of reality,
so as to support MARKET or LIMIT orders


Package Files



var (
    //Public Variables
    PXMessageBus    *nats.Conn
    OrderUpdateChan chan *ems.Order

func Close Uses

func Close()

func DoTrade Uses

func DoTrade(order *ems.Order, quantity float64, price float64)

func RegisterOrder Uses

func RegisterOrder(order *ems.Order)

func UnRegisterOrder Uses

func UnRegisterOrder(order *ems.Order)

type OrderBook Uses

type OrderBook struct {
    OrdersList map[int32]*ems.Order
    Symbol     string
    Quote      *marketdata.Quote
    Subscriber *nats.Subscription

func (*OrderBook) ConstrucOrderBookLinkedList Uses

func (m *OrderBook) ConstrucOrderBookLinkedList() (*QuoteBand, *QuoteBand)

func (*OrderBook) ProcessOrderBookUpdate Uses

func (m *OrderBook) ProcessOrderBookUpdate(triggerQuote *marketdata.Quote)

type QuoteBand Uses

type QuoteBand struct {
    // contains filtered or unexported fields

Package orderbook imports 10 packages (graph). Updated 2016-07-20. Refresh now. Tools for package owners. This is an inactive package (no imports and no commits in at least two years).