yoda

package module
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Jul 14, 2021 License: MIT Imports: 3 Imported by: 2

README

yoda

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Bind

func Bind(i interface{}, ctx *atreugo.RequestCtx) error

func BindFromContext

func BindFromContext(key string, ctx *atreugo.RequestCtx) interface{}

func Created

func Created(obj interface{}, ctx *atreugo.RequestCtx) error

func JSON

func JSON(status int, obj interface{}, ctx *atreugo.RequestCtx) error

func New

func New(name string) *yoda

func NewResponse

func NewResponse(status int, message string, ctx *atreugo.RequestCtx) error

func OK

func OK(obj interface{}, ctx *atreugo.RequestCtx) error

Types

type Response

type Response struct {
	Message string      `json:"message,omitempty"`
	Data    interface{} `json:"data,omitempty"`
	Error   string      `json:"error,omitempty"`
}

type Yoda

type Yoda interface {
	Run()
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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