trade

package
v0.0.0-...-afd3e11 Latest Latest
Warning

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

Go to latest
Published: Feb 28, 2021 License: AGPL-3.0 Imports: 11 Imported by: 0

Documentation

Index

Constants

View Source
const (
	TypeBuy  = "Buy"
	TypeSell = "Sell"
)

Type

View Source
const (
	DateColumn              = "Date"
	MarketColumn            = "Market"
	CategoryColumn          = "Category"
	TypeColumn              = "Type"
	PriceColumn             = "Price"
	AmountColumn            = "Amount"
	TotalColumn             = "Total"
	FeeColumn               = "Fee"
	OrderNumberColumn       = "Order Number"
	BaseTotalLessFeeColumn  = "Base Total Less Fee"
	QuoteTotalLessFeeColumn = "Quote Total Less Fee"
	FeeCurrencyColumn       = "Fee Currency"
	FeeTotalColumn          = "Fee Total"
)

Column names

Variables

This section is empty.

Functions

func ValidateColumnNames

func ValidateColumnNames(names []string) error

ValidateColumnNames checks columns

Types

type Extractor

type Extractor struct {
}

Extractor for Poloniex trades

func NewExtractor

func NewExtractor() *Extractor

NewExtractor create an executor for Poloniex trades

func (*Extractor) Execute

func (e *Extractor) Execute(ctx context.Context, db boil.ContextExecutor, reader io.Reader, options ...eupholio.Option) error

Execute performs ETL

type Record

type Record map[string]string

func MakeRecords

func MakeRecords(head []string, rows [][]string) ([]Record, error)

func (Record) Date

func (r Record) Date() (time.Time, error)

func (Record) Get

func (r Record) Get(name string) string

func (Record) GetAsDecimal

func (r Record) GetAsDecimal(name string) (*decimal.Big, error)

Jump to

Keyboard shortcuts

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