controllers

package
v0.5.0 Latest Latest
Warning

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

Go to latest
Published: Aug 28, 2018 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bar

type Bar struct {
	Greeting string
}

type BarController

type BarController struct {
	jwt.Controller
}

func (*BarController) Get

func (c *BarController) Get(ctx *web.Context)

type FooController

type FooController struct {
	web.Controller
	// contains filtered or unexported fields
}

func (*FooController) After

func (c *FooController) After(ctx *web.Context)

func (*FooController) Before

func (c *FooController) Before(ctx *web.Context)

func (*FooController) Get

func (c *FooController) Get(ctx *web.Context)

func (*FooController) Init added in v0.5.0

func (c *FooController) Init(jwtToken jwt.Token)

func (*FooController) Post

func (c *FooController) Post(ctx *web.Context)

func (*FooController) PostLogin

func (c *FooController) PostLogin(ctx *web.Context)

Post login The first word of method is the http method POST, the rest is the context mapping

type FooRequest

type FooRequest struct {
	Name string `json:"name" validate:"required"`
	Age  int    `json:"age"`
}

type FooResponse

type FooResponse struct {
	Greeting string `json:"greeting"`
	Age      int    `json:"age"`
}

type UserRequest

type UserRequest struct {
	Username string `json:"username" validate:"required"`
	Password string `json:"password" validate:"required"`
}

Jump to

Keyboard shortcuts

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