service

package
v0.0.0-...-8bbfd3c Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type RateFetcher

type RateFetcher interface {
	FetchRate(ctx context.Context, ccFrom, ccTo string) (rate.Rate, error)
}

type RateRepo

type RateRepo interface {
	Create(rate *models.Rate) error
}

type RateService

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

func NewRateService

func NewRateService(repo RateRepo, fetcher RateFetcher) *RateService

func (*RateService) FetchRate

func (s *RateService) FetchRate(ctx context.Context, from, to string) (*models.Rate, error)

Jump to

Keyboard shortcuts

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