api

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Oct 3, 2019 License: MIT Imports: 34 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrBadRequest

func ErrBadRequest(err error) *errResponse

func ErrInternal

func ErrInternal(err error) *errResponse

func ErrNotFound

func ErrNotFound(err error) *errResponse

Types

type Gateway

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

func New

func New() *Gateway

func (*Gateway) Shutdown

func (g *Gateway) Shutdown()

func (*Gateway) StartHTTP

func (g *Gateway) StartHTTP(
	port int, c *skademlia.Client, l *wavelet.Ledger, k *skademlia.Keypair, kv store.KV,
)

func (*Gateway) StartHTTPS added in v0.2.0

func (g *Gateway) StartHTTPS(
	httpPort int, c *skademlia.Client, l *wavelet.Ledger, k *skademlia.Keypair,
	kv store.KV,
	allowedHost, certCacheDir string,
)

Only support tls-alpn-01.

func (*Gateway) Write

func (g *Gateway) Write(buf []byte) (n int, err error)

Jump to

Keyboard shortcuts

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