api

package
v0.0.0-...-60c1ff8 Latest Latest
Warning

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

Go to latest
Published: Mar 4, 2019 License: MPL-2.0 Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APICfg

type APICfg struct {
	Bind string
}

func GetConf

func GetConf() *APICfg

type Config

type Config struct {
	API *APICfg
}

type JoinReq

type JoinReq struct {
	Peers []string
}

type Payload

type Payload struct {
	Status string
	Error  string      `json:",omitempty"`
	Data   interface{} `json:",omitempty"`
}

type PublicData

type PublicData struct {
	Data interface{}
	Type string
}

type WebAPI

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

func (*WebAPI) AddObject

func (a *WebAPI) AddObject(w http.ResponseWriter, r *http.Request)

func (*WebAPI) ClusterJoin

func (a *WebAPI) ClusterJoin(w http.ResponseWriter, r *http.Request)

func (*WebAPI) ClusterLeave

func (a *WebAPI) ClusterLeave(w http.ResponseWriter, r *http.Request)

func (*WebAPI) LoadObject

func (a *WebAPI) LoadObject(w http.ResponseWriter, r *http.Request)

func (*WebAPI) RemObject

func (a *WebAPI) RemObject(w http.ResponseWriter, r *http.Request)

func (*WebAPI) Start

func (a *WebAPI) Start(srv *server.Server, cfg *APICfg)

Jump to

Keyboard shortcuts

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