Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type GetLocationByCEPRequest ¶
type GetLocationByCEPRequest struct {
CEP string `json:"cep"`
}
GetLocationByCEPRequest - estrutura de entrada para busca de clima pelo CEP
type GetWeatherByLocalRequest ¶
type GetWeatherByLocalRequest struct { Latitude string `json:"latitude"` Longitude string `json:"longitude"` }
GetWeatherByLocalRequest - estrutura de entrada para busca de clima pelo local
type Handler ¶
type Handler struct { GetLatLonByCEP usecase.GetLatLonByCEP GetWeatherByLocation usecase.GetWeatherUseCase }
func NewHandler ¶
func NewHandler(GetLatLonByCEP usecase.GetLatLonByCEP, GetWeatherByLocation usecase.GetWeatherUseCase) *Handler
NewHandler - cria um novo handler com os usecases
func (*Handler) GetLocationByCEP ¶
func (wh *Handler) GetLocationByCEP(w http.ResponseWriter, r *http.Request)
GetLocationByCEP - busca de clima pelo CEP
func (*Handler) GetWeatherByLocal ¶
func (wh *Handler) GetWeatherByLocal(w http.ResponseWriter, r *http.Request)
GetWeatherByLocal - busca de clima pelo local
Click to show internal directories.
Click to hide internal directories.