Created
April 6, 2013 03:31
-
-
Save inhies/5324634 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Package trade provides generic interfaces and helper functions for working | |
// with assets. | |
package trade | |
import ( | |
"time" | |
) | |
// A single order that has been placed, with timestamp if available | |
type Order struct { | |
Amount float64 | |
Price float64 | |
Timestamp time.Time | |
} | |
// All buy and sell orders | |
type OrderBook struct { | |
Buy []Order | |
Sell []Order | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment