controller

package
v0.0.0-...-fd23dd1 Latest Latest
Warning

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

Go to latest
Published: Jan 21, 2019 License: OSL-3.0 Imports: 5 Imported by: 2

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DataController

type DataController struct {
	responder.JSONAware
	// contains filtered or unexported fields
}

DataController registers a route to allow external tools/ajax to retrieve data Handler

func (*DataController) Get

Get Handler registered at /_flamingo/json/{Handler} and return's the call to Get()

func (*DataController) Inject

func (gc *DataController) Inject(aware responder.JSONAware, router *router.Router)

type Error

type Error struct {
	Responder responder.ErrorAware `inject:""`
}

Error controller

func (*Error) Error

func (controller *Error) Error(ctx context.Context, request *web.Request) web.Response

Error responder

func (*Error) NotFound

func (controller *Error) NotFound(ctx context.Context, request *web.Request) web.Response

NotFound responder

type FlashMessage

type FlashMessage struct {
	Type    string
	Message interface{}
}

FlashMessage contains a type and a printable message

type Redirect

type Redirect struct {
	Responder responder.RedirectAware `inject:""`
}

Redirect Default controller

func (*Redirect) Redirect

func (redirect *Redirect) Redirect(ctx context.Context, request *web.Request) web.Response

Redirect `to` a controller, all other params are passed on

func (*Redirect) RedirectPermanent

func (redirect *Redirect) RedirectPermanent(ctx context.Context, request *web.Request) web.Response

RedirectPermanent is the same as Redirect but with a HTTP permanent redirect

func (*Redirect) RedirectPermanentURL

func (redirect *Redirect) RedirectPermanentURL(ctx context.Context, request *web.Request) web.Response

RedirectPermanentURL is the same as RedirectURL but with a HTTP permanent redirect

func (*Redirect) RedirectURL

func (redirect *Redirect) RedirectURL(ctx context.Context, request *web.Request) web.Response

RedirectURL redirects to a url

type Render

type Render struct {
	Responder responder.RenderAware `inject:""`
}

Render controller

func (*Render) Render

func (controller *Render) Render(ctx context.Context, request *web.Request) web.Response

Render responder

type SessionFlashController

type SessionFlashController struct{}

SessionFlashController takes care of supported flash messages

func (*SessionFlashController) Data

func (sfc *SessionFlashController) Data(c context.Context, r *web.Request) interface{}

Data Controller for sessionflashcontroller

Jump to

Keyboard shortcuts

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