Documentation ¶
Index ¶
Constants ¶
View Source
const ( ErrLoad = "can't pull currency prices from site: %v" ErrXML = "can't extract xml data" )
View Source
const (
ErrID = "must be id in query"
)
Variables ¶
This section is empty.
Functions ¶
func XMLExtract ¶
func XMLExtract(rc io.ReadCloser) ([]*entity.Currency, error)
Types ¶
type HTTPClient ¶
type HTTPClient struct {
// contains filtered or unexported fields
}
func NewHTTPClient ¶
func NewHTTPClient(url string, timeout time.Duration) *HTTPClient
type HTTPServer ¶
type HTTPServer struct {
// contains filtered or unexported fields
}
func NewHttpServer ¶
func NewHttpServer(addr string, logger usecase.Logger, currencier usecase.Currencier) *HTTPServer
func (*HTTPServer) Serve ¶
func (s *HTTPServer) Serve() error
func (*HTTPServer) StopServe ¶
func (s *HTTPServer) StopServe()
Click to show internal directories.
Click to hide internal directories.