Documentation ¶
Index ¶
- Constants
- func NewGoogleStockPriceAtDate(ctx context.Context) *googleStockPriceAtDate
- func NewMarketChameleonStockPriceVolatility(ctx context.Context, url string) *marketChameleonStockPriceVolatility
- func NewStockDividendMarketChameleon(ctx context.Context, urlBuilder UrlBuilder, htmlParser HtmlParser) *stockDividendMarketChameleon
- func NewStockPriceAtDate(ctx context.Context) *yahooStockPriceAtDate
- func NewStockSummaryMarketChameleon(ctx context.Context, url string) *stockSummaryMarketChameleon
- func NewStockSummaryYahoo(ctx context.Context, url string) *stockSummaryYahoo
- func NewYahooScrapeStockPrice(ctx context.Context, url string) *yahooScraperStockPrice
- type Account
- func (s *Account) BuyStocksWallet(w *wallet.Wallet, stksSymbol map[string]int, ...) error
- func (s *Account) FindWalletByName(name string) (*wallet.Wallet, error)
- func (s *Account) LoadActiveWalletItems(w *wallet.Wallet) error
- func (s *Account) LoadWalletItem(w *wallet.Wallet, stkSymbol string) error
- func (s *Account) SaveAllOperations(w *wallet.Wallet) error
- func (s *Account) SaveAllWallets(ws []*wallet.Wallet) error
- func (s *Account) SellStocksWallet(w *wallet.Wallet, stksSymbol map[string]int, ...) error
- func (s *Account) UpdateWalletsAccountingByTransfers(ts []*transfer.Transfer) error
- func (s *Account) UpdateWalletsCapitalByStock(stk *stock.Stock) error
- func (s *Account) UpdateWalletsCapitalByStocks(stks []*stock.Stock) error
- type AppCommissions
- type Banking
- type HtmlParser
- type Purchase
- func (s *Purchase) FindExchangeBySymbol(symbol string) (*exchange.Exchange, error)
- func (s *Purchase) FindMarketByName(name string) (*market.Market, error)
- func (s *Purchase) FindStockByName(name string) (*stock.Stock, error)
- func (s *Purchase) FindStockBySymbol(symbol string) (*stock.Stock, error)
- func (s *Purchase) FindStockInfoByValue(symbol string) (*stock.Info, error)
- func (s *Purchase) SaveAllStocks(stks []*stock.Stock) error
- func (s *Purchase) SaveStockInfo(stkInfo *stock.Info) error
- func (s *Purchase) Stocks() ([]*stock.Stock, error)
- func (s *Purchase) StocksByDividendAnnounceProjectYearAndMonth(year, month string) ([]*stock.Stock, error)
- func (s *Purchase) StocksByExchanges(exchanges []string) ([]*stock.Stock, error)
- func (s *Purchase) Update52WeekHighLowPriceStock(stk *stock.Stock) error
- func (s *Purchase) Update52WeekHighLowPriceStocks(stks []*stock.Stock) []error
- func (s *Purchase) UpdateLastClosedPriceStock(stk *stock.Stock) error
- func (s *Purchase) UpdateLastClosedPriceStocks(stks []*stock.Stock) []error
- func (s *Purchase) UpdateStockDividends(stk *stock.Stock) error
- type StockDividend
- type StockPrice
- type StockPriceAtDate
- type StockPriceVolatility
- type StockSummary
- type UrlBuilder
Constants ¶
const ( Future dividendType = "future_divs" Historical = "historical_divs" )
const UpdatePriceConcurrency = 10
Variables ¶
This section is empty.
Functions ¶
func NewStockDividendMarketChameleon ¶
func NewStockDividendMarketChameleon(ctx context.Context, urlBuilder UrlBuilder, htmlParser HtmlParser) *stockDividendMarketChameleon
---------------------------------------------------------------------------------------------------------------------- stockDividendMarketChameleon Service ----------------------------------------------------------------------------------------------------------------------
func NewStockPriceAtDate ¶
func NewStockSummaryYahoo ¶
Types ¶
type Account ¶
type Account struct {
// contains filtered or unexported fields
}
func NewAccountService ¶
func (*Account) BuyStocksWallet ¶
func (*Account) FindWalletByName ¶
func (*Account) LoadActiveWalletItems ¶
func (*Account) LoadWalletItem ¶
func (*Account) SellStocksWallet ¶
func (*Account) UpdateWalletsAccountingByTransfers ¶
func (*Account) UpdateWalletsCapitalByStock ¶
type AppCommissions ¶
type Banking ¶
type Banking struct {
// contains filtered or unexported fields
}
func NewBankingService ¶
func (*Banking) FindBankAccountByAlias ¶
type HtmlParser ¶
---------------------------------------------------------------------------------------------------------------------- HtmlParser ----------------------------------------------------------------------------------------------------------------------
func NewStockDividendMarketChameleonChromedpParser ¶
func NewStockDividendMarketChameleonChromedpParser(ctx context.Context, cdp *chromedp.CDP) HtmlParser
func NewStockDividendMarketChameleonFileHtmlParser ¶
func NewStockDividendMarketChameleonFileHtmlParser(ctx context.Context) HtmlParser
func NewStockDividendMarketChameleonWWWHtmlParser ¶
func NewStockDividendMarketChameleonWWWHtmlParser(ctx context.Context) HtmlParser
---------------------------------------------------------------------------------------------------------------------- HtmlParser ----------------------------------------------------------------------------------------------------------------------
type Purchase ¶
type Purchase struct {
// contains filtered or unexported fields
}
func NewPurchaseService ¶
func NewPurchaseService( ctx context.Context, stockPersister stock.Persister, stockFinder stock.Finder, stockDividendPersister dividend.Persister, stockDividendFinder dividend.Finder, marketFinder market.Finder, exchangeFinder exchange.Finder, accountService *Account, iexClient *iex.Client, stockInfoFinder stock.InfoFinder, stockInfoPersister stock.InfoPersister, ) *Purchase
func (*Purchase) FindExchangeBySymbol ¶
func (*Purchase) FindMarketByName ¶
func (*Purchase) FindStockByName ¶
func (*Purchase) FindStockBySymbol ¶
func (*Purchase) FindStockInfoByValue ¶
func (*Purchase) StocksByDividendAnnounceProjectYearAndMonth ¶
func (*Purchase) StocksByExchanges ¶
func (*Purchase) Update52WeekHighLowPriceStock ¶
func (*Purchase) Update52WeekHighLowPriceStocks ¶
Update52WeekClosedPriceStocks update the stocks 52 week with the high - low price
func (*Purchase) UpdateLastClosedPriceStock ¶
func (*Purchase) UpdateLastClosedPriceStocks ¶
UpdateLastClosedPriceStocks update the stocks with the last close date price
type StockDividend ¶
type StockPriceAtDate ¶
type StockPriceVolatility ¶
type StockPriceVolatility interface {
PriceVolatility(stk *stock.Stock) (stock.PriceVolatility, error)
}
type StockSummary ¶
type UrlBuilder ¶
---------------------------------------------------------------------------------------------------------------------- UrlBuilder ----------------------------------------------------------------------------------------------------------------------
func NewStockScrapeMarketChameleonFileUrlBuilder ¶
func NewStockScrapeMarketChameleonFileUrlBuilder(ctx context.Context, url string) UrlBuilder
---------------------------------------------------------------------------------------------------------------------- File ----------------------------------------------------------------------------------------------------------------------
func NewStockScrapeMarketChameleonWWWUrlBuilder ¶
func NewStockScrapeMarketChameleonWWWUrlBuilder(ctx context.Context, url string) UrlBuilder
---------------------------------------------------------------------------------------------------------------------- UrlBuilder ---------------------------------------------------------------------------------------------------------------------- ---------------------------------------------------------------------------------------------------------------------- WWW ----------------------------------------------------------------------------------------------------------------------