api

package
v0.0.4 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2021 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ContentTypeJson

func ContentTypeJson(next httprouter.Handle) httprouter.Handle

func NewHTTPRouter

func NewHTTPRouter(prefix string, isProduction bool, options GoCraftOptions) http.Handler

func RegisterRoutes added in v0.0.2

func RegisterRoutes(router *httprouter.Router, prefix string, isProduction bool, options GoCraftOptions)

func RegisterRoutesOnGin added in v0.0.2

func RegisterRoutesOnGin(router gin.IRoutes, prefix string, isProduction bool, options GoCraftOptions)

Types

type Context

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

func NewGoCraftApi

func NewGoCraftApi(options GoCraftOptions) *Context

NewServer creates and returns a new server. The 'namespace' param is the redis namespace to use. The hostPort param is the address to bind on to expose the API.

type GoCraftOptions

type GoCraftOptions struct {
	Namespace string
	Pool      *redis.Pool
}

type MicroScopeViewModel

type MicroScopeViewModel struct {
	CssFilePath string
	JsFilePath  string
	AppName     string
	Data        map[string]interface{}
}

Jump to

Keyboard shortcuts

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