app

package
v0.0.0-...-6c9f6a5 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2020 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Application

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

func NewApp

func NewApp(fc forecaster.Forecaster) *Application

func (*Application) GetCurrent

func (a *Application) GetCurrent(ctx *fasthttp.RequestCtx)

func (*Application) GetForecast

func (a *Application) GetForecast(ctx *fasthttp.RequestCtx)

func (*Application) Run

func (a *Application) Run(port string) error

type WeatherAPIModel

type WeatherAPIModel struct {
	City        string `json:"city"`
	Unit        string `json:"unit"`
	Temperature int32  `json:"temperature"`
}

func (WeatherAPIModel) MarshalEasyJSON

func (v WeatherAPIModel) MarshalEasyJSON(w *jwriter.Writer)

MarshalEasyJSON supports easyjson.Marshaler interface

func (WeatherAPIModel) MarshalJSON

func (v WeatherAPIModel) MarshalJSON() ([]byte, error)

MarshalJSON supports json.Marshaler interface

func (*WeatherAPIModel) UnmarshalEasyJSON

func (v *WeatherAPIModel) UnmarshalEasyJSON(l *jlexer.Lexer)

UnmarshalEasyJSON supports easyjson.Unmarshaler interface

func (*WeatherAPIModel) UnmarshalJSON

func (v *WeatherAPIModel) UnmarshalJSON(data []byte) error

UnmarshalJSON supports json.Unmarshaler interface

Jump to

Keyboard shortcuts

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