feeder

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Sep 15, 2023 License: MIT Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Service

type Service struct {
	// contains filtered or unexported fields
}

func NewService

func NewService(
	feederSvc ports.PriceFeeder, repoManager ports.RepoManager,
) (*Service, error)

func (*Service) AddPriceFeed

func (s *Service) AddPriceFeed(
	ctx context.Context, market ports.Market, source, ticker string,
) (string, error)

func (*Service) Close

func (s *Service) Close()

func (*Service) GetPriceFeed

func (s *Service) GetPriceFeed(
	ctx context.Context, id string,
) (ports.PriceFeedInfo, error)

func (*Service) ListPriceFeeds

func (s *Service) ListPriceFeeds(
	ctx context.Context,
) ([]ports.PriceFeedInfo, error)

func (*Service) ListSources

func (s *Service) ListSources(ctx context.Context) []string

func (*Service) RemovePriceFeed

func (s *Service) RemovePriceFeed(ctx context.Context, id string) error

func (*Service) StartPriceFeed

func (s *Service) StartPriceFeed(ctx context.Context, id string) error

func (*Service) StopPriceFeed

func (s *Service) StopPriceFeed(ctx context.Context, id string) error

func (*Service) UpdatePriceFeed

func (s *Service) UpdatePriceFeed(
	ctx context.Context, id, source, ticker string,
) error

Jump to

Keyboard shortcuts

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