model

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2020 License: GPL-3.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 CalculatedStockInfo

type CalculatedStockInfo struct {
	Ticker         string  `json:"ticker"`
	Price          float64 `json:"price"`
	OptInPrice     float64 `json:"optInPrice"`
	PriceColor     string  `json:"priceColor"`
	AnnualDividend float64 `json:"dividend"`
	DividendYield  float64 `json:"dividendYield"`
	OptInYield     float64 `json:"optInYield"`
	DividendColor  string  `json:"dividendColor"`
	CurrentPe      float64 `json:"currentPe"`
	OptInPe        float64 `json:"optInPe"`
	PeColor        string  `json:"pecolor"`
}

CalculatedStockInfo holds the data calculated for investment suggestions

type StockData

type StockData struct {
	Ticker           string            `json:"ticker"`
	Price            float64           `json:"price"`
	Eps              float64           `json:"eps"`
	Dividend         float64           `json:"dividend"`
	PeRatio5yr       pERatioInfo       `json:"peRatio5yr"`
	DividendYield5yr dividendYieldInfo `json:"dividendYield5yr"`
}

StockData holds the information for one stock

type Watchlist

type Watchlist struct {
	ID     primitive.ObjectID `bson:"_id" json:"id"`
	Name   string             `bson:"name" json:"name"`
	Stocks []string           `bson:"stocks" json:"stocks"`
	UserID string             `bson:"userId" json:"userId"`
}

type WatchlistRequest

type WatchlistRequest struct {
	Name   string   `bson:"name" json:"name"`
	Stocks []string `bson:"stocks" json:"stocks"`
	UserID string   `bson:"userId"`
}

Jump to

Keyboard shortcuts

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