structs

package
v0.0.0-...-58dd970 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 14, 2018 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type OrderWrapper

type OrderWrapper struct {
	*tradier.Order
	Filled *int
}

OrderWrapper is the wrapper on tradier.Order with the addition of the filled quantity.

func NewOrderWrapper

func NewOrderWrapper(order *tradier.Order) *OrderWrapper

NewOrderWrapper returns *OrderTemplate with the filled amount calculated.

type OrdersWrapper

type OrdersWrapper []*OrderWrapper

OrdersWrapper holds a collection of OrderWrapper.

func NewOrdersWrapper

func NewOrdersWrapper(orders *tradier.Orders) *OrdersWrapper

NewOrdersWrapper returns *OrdersTemplate with the filled amount calculated for earch *OrderTemplate.

type PositionWrapper

type PositionWrapper struct {
	*tradier.Position
	Last               *float64
	Change             *float64
	ChangePercentage   *float64
	Value              *float64
	GainLoss           *float64
	GainLossPercentage *float64
}

PositionWrapper is wrapper on tradier.Positions with additional fields used for positions output.

func NewPositionWrapper

func NewPositionWrapper(position *tradier.Position, quote *tradier.Quote) *PositionWrapper

NewPositionWrapper returns *OrderTemplate with the filled amount calculated.

type PositionsWrapper

type PositionsWrapper []*PositionWrapper

PositionsWrapper holds a collection of PositionWrapper.

func NewPositionsWrapper

func NewPositionsWrapper(positions *tradier.Positions, quotes *tradier.Quotes) *PositionsWrapper

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL