Documentation ¶
Index ¶
- type Builder
- func (b *Builder[T]) Build() *ExecutionReport[T]
- func (b *Builder[T]) SetAccount(account string) *Builder[T]
- func (b *Builder[T]) SetAvgPrice(avgPrice float64) *Builder[T]
- func (b *Builder[T]) SetCumQty(cumQty float64) *Builder[T]
- func (b *Builder[T]) SetErrorReason(errorReason string) *Builder[T]
- func (b *Builder[T]) SetFilledQty(filledQty float64) *Builder[T]
- func (b *Builder[T]) SetLastPrice(lastPrice float64) *Builder[T]
- func (b *Builder[T]) SetLeavesQty(leavesQty float64) *Builder[T]
- func (b *Builder[T]) SetRejectReason(rejectReason string) *Builder[T]
- func (b *Builder[T]) SetTotalFee(totalFee float64) *Builder[T]
- func (b *Builder[T]) SetVersion(version uint8) *Builder[T]
- type ExecutionReport
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Builder ¶
type Builder[T instr.Instrument] struct { // contains filtered or unexported fields }
func NewBuilder ¶
func (*Builder[T]) Build ¶
func (b *Builder[T]) Build() *ExecutionReport[T]
func (*Builder[T]) SetAccount ¶
func (*Builder[T]) SetAvgPrice ¶
func (*Builder[T]) SetErrorReason ¶
func (*Builder[T]) SetFilledQty ¶
func (*Builder[T]) SetLastPrice ¶
func (*Builder[T]) SetLeavesQty ¶
func (*Builder[T]) SetRejectReason ¶
func (*Builder[T]) SetTotalFee ¶
func (*Builder[T]) SetVersion ¶
type ExecutionReport ¶
type ExecutionReport[T instr.Instrument] struct { Instrument T // Instrument of the order. Exchange exchange.Exchange // Exchange of the order. ClientOrderID string // Unique ID for the order assigned by the client (us). OrderID string // Unique ID for the order assigned by the exchange. Price float64 // Price of the order. Qty float64 // Qty of the order. Side side.OrderSide // Side of the order. OrderStatus ordstatus.OrderStatus // OrderStatus of the order. OrderType ordtypes.OrderType // Type of the order. TimeInForce tif.TimeInForce // Time in force of the order. TransactTime time.Time // Transact time of the order Account *string // Account of the order (optional). TotalFee *float64 // Total fee of the order (optional). FilledQty *float64 // Qty of the order that has been filled. LeavesQty *float64 // Leaves qty of the order (optional). CumQty *float64 // Cumulative qty of the order (optional). AvgPrice *float64 // Average price of the order (optional). LastPrice *float64 // Last price of the order (optional). Version *uint8 // Exchange version of the order (optional). RejectReason *string // Reason for the order being rejected (optional). ErrorReason *string // Reason for the order being errored (optional). }
Note: Optionals are indicated as pointers
Click to show internal directories.
Click to hide internal directories.