handler

package
v0.6.48 Latest Latest
Warning

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

Go to latest
Published: Jan 10, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	SymbolParam     = "symbol"
	ResolutionParam = "res"
	FromParam       = "from"
	ToParam         = "to"
)
View Source
const (
	QuoteRoute             = "/quote/"
	QuoteRouteWithParams   = QuoteRoute + ":" + SymbolParam
	CandlesRoute           = "/candles/"
	CandlesRouteWithParams = CandlesRoute + ":" +
		SymbolParam + "/:" +
		ResolutionParam + "/:" +
		FromParam + "/:" +
		ToParam
	RecommendationTrendsRoute           = "/recommendation/trends/"
	RecommendationTrendsRouteWithParams = RecommendationTrendsRoute + ":" + SymbolParam
	PeersRoute                          = "/peers/"
	PeersRouteWithParams                = PeersRoute + ":" + SymbolParam
)
View Source
const (
	Minute = "1"
	Hour   = "60"
	Day    = "D"
	Month  = "M"
)
View Source
const (
	ComponentsRoute = "/components"
	APIRoute        = "/api"
)

Variables

Functions

func NewHandler

func NewHandler(store *store.Store) *echo.Echo

func NewTestHandler

func NewTestHandler(t *testing.T) (*httptest.Server, *httpexpect.Expect)

Types

type Handler

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

func (*Handler) Candles

func (h *Handler) Candles(ctx echo.Context) error

func (*Handler) Peers

func (h *Handler) Peers(ctx echo.Context) error

func (*Handler) Quote

func (h *Handler) Quote(ctx echo.Context) error

func (*Handler) RecommendationTrends

func (h *Handler) RecommendationTrends(ctx echo.Context) error

Jump to

Keyboard shortcuts

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