restful

package
v0.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 25, 2018 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Overview

Package restful defines the http server.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateConfigFile

func CreateConfigFile(service app.Service) func(*gin.Context)

func CreateConfigGroup

func CreateConfigGroup(service app.Service) func(*gin.Context)

func ListConfigFile

func ListConfigFile(service app.Service) func(*gin.Context)

func ListConfigGroup

func ListConfigGroup(service app.Service) func(*gin.Context)

func PublishConfigGroup

func PublishConfigGroup(service app.Service) func(*gin.Context)

func QueryAppWatcher

func QueryAppWatcher(service app.Service) func(*gin.Context)

func UpdateConfigFile

func UpdateConfigFile(service app.Service) func(*gin.Context)

func UpdateConfigGroup

func UpdateConfigGroup(service app.Service) func(*gin.Context)

func ViewConfigFile

func ViewConfigFile(service app.Service) func(*gin.Context)

func ViewConfigGroup

func ViewConfigGroup(service app.Service) func(*gin.Context)

Types

type ResponseRet

type ResponseRet struct {
	Msg  string      `json:"msg,omitempty"`
	Data interface{} `json:"data,omitempty"`
}

type Server

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

func NewServer

func NewServer(listenAddr string, service app.Service) *Server

NewServer creates a server.

func (*Server) Start

func (server *Server) Start()

Start server.

func (*Server) Stop

func (server *Server) Stop() <-chan struct{}

Stop server.

Jump to

Keyboard shortcuts

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